Golang GUI library for windows, UI created by ResEdit or Visual Studio Resource Editor
Lightweight, high performance and small executable file size Windows GUI library.
ResEdit
Visual Studio Resource Editor
Other dialog box editor
MinGW http://www.mingw.org
or
TDM-GCC http://tdm-gcc.tdragon.net/
This tool in TDM-GCC-64/bin/windres.exe
,don't know where in MinGW.
You can also use rc.exe and link.exe to generate syso file.
Generate x.syso
file from rc or res file use windres.exe
tool.
generate syso
file:
windres -i emptyProject/Debug/resource.res -O coff -o vsui.syso
or
windres -i ui/ui.rc -O coff -o ui.syso
main.go
package main
import "github.com/whtiehack/wingui"
func main() {
dlg, _ := wingui.NewDialog(101, 0, nil)
dlg.SetIcon(105)
btnok, _ := wingui.BindNewButton(1002, dlg)
btncancel, _ := wingui.BindNewButton(1003, dlg)
btnok.OnClicked = func() {
dlg.Close()
}
btncancel.OnClicked = btnok.OnClicked
dlg.Show()
// This invoke is optional.
wingui.SetCurrentDialog(dlg.Handle())
wingui.MessageLoop()
}
run:
go run .
Don't use go run main.go
, because golang can't load x.syso files.
see https://github.com/whtiehack/wingui/tree/master/examples
Welcome PRs.
https://github.com/lxn/walk
https://github.com/sumorf/gowi
https://docs.microsoft.com/zh-cn/windows/win32/
https://docs.microsoft.com/zh-cn/windows/win32/uxguide/controls
https://docs.microsoft.com/zh-cn/windows/win32/controls/window-controls
click to show
-
Edit
-
Static Text
-
Image
-
ComboBoxx
-
ListBox
- PushButton
- CheckBox
- Radio Button
-
Slider Control
-
Progress Bar
-
Tab Control
-
ListView Control
-
Spin Control
-
Rich Edit
-
DateTimePicker
-
Month Calendar
-
TreeView Control
-
Hot Key
-
Accelerator
-
Menu
If you need to do complex GUI programs, you can use govcl or walk.