1

我就是imageTab跑不动。我得到一个Segmentation fault: 11. 这是我的代码。有人知道该怎么做吗?

import Graphics.UI.WX 
import Graphics.UI.WXCore

main :: IO ()
main = start gui

gui :: IO ()
gui = do
    f  <- frame []
    fp <- panel f []

    nb <- notebook fp []
    page <- panel nb []
    b <- button page [ text := "-"]


    let bm = bitmap "favicon.ico"
    -- check that bitmap is there
    sx <- bitmapGetHeight bm
    print sx

    set f [ layout := container fp $ tabs nb [imageTab "Foo" bm (container page $ fill $ widget b)]]

    -- This works
    --set f [ layout := container fp $ tabs nb [tab "Foo" (container page $ fill $ widget b)]]
4

1 回答 1

1

这看起来像一个错误;您最好在http://sourceforge.net/p/wxhaskell/bugs/上报告它

于 2015-11-17T22:37:29.710 回答