added empty GTK-Hello-World-Project
This commit is contained in:
15
src/Main.hs
Normal file
15
src/Main.hs
Normal file
@ -0,0 +1,15 @@
|
||||
|
||||
import Graphics.UI.Gtk
|
||||
|
||||
main :: IO ()
|
||||
main = do
|
||||
initGUI
|
||||
window <- windowNew
|
||||
button <- buttonNew
|
||||
set window [ containerBorderWidth := 10,
|
||||
containerChild := button ]
|
||||
set button [ buttonLabel := "Hello World" ]
|
||||
onClicked button (putStrLn "Hello World")
|
||||
onDestroy window mainQuit
|
||||
widgetShowAll window
|
||||
mainGUI
|
Reference in New Issue
Block a user