1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
// A simple helloworld window package main import ( "log" "git.wit.org/wit/gui" ) // This creates a window func helloworld() { var w *gui.Node gui.Config.Title = "helloworld golang wit/gui window" gui.Config.Width = 400 gui.Config.Height = 100 w = gui.NewWindow() w.NewButton("hello", func () { log.Println("world") }) }