WxGeneric-0.6.0: examples/TupleExample.hs
module TupleExample where
import Graphics.UI.WxGeneric
import Graphics.UI.WX
main :: IO ()
main = start $
do f <- frame [ text := "Tuple Example" ]
p <- panel f []
en <- genericWidgetEx (\x -> x { joinLayout = twoColumnLayout -- Force two column layout
, labelTransform = idLabel -- No label shortcuts
})
id p (3 :: Int, "Hans", 5.5 :: Double)
b <- button p [ text := "&Print tuple"
, on command := get en widgetValue >>= print ]
set f [ layout := container p $ row 10 [ widget en, widget b ] ]