About Walk

Walk is a "Windows Application Library Kit" for the Go Programming Language.

Its primarily useful for Desktop GUI development, but there is some more stuff.


Make sure you have a working Go installation.
See [Getting Started](

##### Note
Walk currently requires Go 1.11.x or later.

##### To Install
Now run `go get`

Using Walk

The preferred way to create GUIs with Walk is to use its declarative sub package,
as illustrated in this small example:

##### `test.go`

package main

import (
	. ""

func main() {
	var inTE, outTE *walk.TextEdit

		Title:   "SCREAMO",
		MinSize: Size{600, 400},
		Layout:  VBox{},
		Children: []Widget{
				Children: []Widget{
					TextEdit{AssignTo: &inTE},
					TextEdit{AssignTo: &outTE, ReadOnly: true},
				Text: "SCREAM",
				OnClicked: func() {

##### Create Manifest `test.manifest`

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
    <assemblyIdentity version="" processorArchitecture="*" name="SomeFunkyNameHere" type="win32"/>
            <assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" language="*"/>
    <application xmlns="urn:schemas-microsoft-com:asm.v3">
            <dpiAwareness xmlns="">PerMonitorV2, PerMonitor</dpiAwareness>
            <dpiAware xmlns="">True</dpiAware>

Then either compile the manifest using the [rsrc tool](, like this:

	go get
	rsrc -manifest test.manifest -o rsrc.syso

or rename the `test.manifest` file to `test.exe.manifest` and distribute it with the application instead.

##### Build app

In the directory containing `test.go` run

	go build
To get rid of the cmd window, instead run

	go build -ldflags="-H windowsgui"

##### Run app
##### Sample Output (Windows 7)

![alt tag](

##### More Examples
There are some [examples](examples) that should get you started.

Application Manifest Files
Walk requires Common Controls 6. This means that you must put an appropriate
application manifest file either next to your executable or embedded as a

You can copy one of the application manifest files that come with the examples.

To embed a manifest file as a resource, you can use the [rsrc tool](

IMPORTANT: If you don't embed a manifest as a resource, then you should not launch
your executable before the manifest file is in place.
If you do anyway, the program will not run properly. And worse, Windows will not
recognize a manifest file, you later drop next to the executable. To fix this,
rebuild your executable and only launch it with a manifest file in place.

CGo Optimizations

The usual default message loop includes calls to win32 API functions, which incurs a decent amount
of runtime overhead coming from Go. As an alternative to this, you may compile Walk using an
optional C implementation of the main message loop, by passing the `walk_use_cgo` build tag:

   go build -tags walk_use_cgo
Expand ▾ Collapse ▴




View Source
const (
	NoOrientation Orientation = 0
	Horizontal                = 1 << 0
	Vertical                  = 1 << 1
View Source
const (
	DlgCmdNone     = 0
	DlgCmdOK       = win.IDOK
	DlgCmdCancel   = win.IDCANCEL
	DlgCmdAbort    = win.IDABORT
	DlgCmdRetry    = win.IDRETRY
	DlgCmdIgnore   = win.IDIGNORE
	DlgCmdYes      = win.IDYES
	DlgCmdNo       = win.IDNO
	DlgCmdClose    = win.IDCLOSE
	DlgCmdHelp     = win.IDHELP
	DlgCmdTryAgain = win.IDTRYAGAIN
	DlgCmdContinue = win.IDCONTINUE
	DlgCmdTimeout  = win.IDTIMEOUT
View Source
const (
	EllipsisNone EllipsisMode = 0
	EllipsisEnd               = EllipsisMode(win.SS_ENDELLIPSIS)
	EllipsisPath              = EllipsisMode(win.SS_PATHELLIPSIS)


View Source
var (
	ErrPropertyReadOnly       = errors.New("read-only property")
	ErrPropertyNotValidatable = errors.New("property not validatable")
View Source
var (
	ErrInvalidType = errors.New("invalid type")


func AltDown

func AltDown() bool

func AppDataPath

func AppDataPath() (string, error)

func AppendToWalkInit

func AppendToWalkInit(fn func())

func CommonAppDataPath

func CommonAppDataPath() (string, error)

func ControlDown

func ControlDown() bool

func DriveNames

func DriveNames() ([]string, error)

func FormatFloat

func FormatFloat(f float64, prec int) string

func FormatFloatGrouped

func FormatFloatGrouped(f float64, prec int) string

func InitWidget

func InitWidget(widget Widget, parent Window, className string, style, exStyle uint32) error

    InitWidget initializes a Widget.

    func InitWindow

    func InitWindow(window, parent Window, className string, style, exStyle uint32) error

      InitWindow initializes a window.

      Widgets should be initialized using InitWidget instead.

      func InitWrapperWindow

      func InitWrapperWindow(window Window) error

        InitWrapperWindow initializes a window that wraps (embeds) another window.

        Calling this method is necessary, if you want to be able to override the WndProc method of the embedded window. The embedded window should only be used as inseparable part of the wrapper window to avoid undefined behavior.

        func IntFrom96DPI

        func IntFrom96DPI(value, dpi int) int

          IntFrom96DPI converts from 1/96" units to native pixels.

          func IntTo96DPI

          func IntTo96DPI(value, dpi int) int

            IntTo96DPI converts from native pixels to 1/96" units.

            func LocalAppDataPath

            func LocalAppDataPath() (string, error)

            func LogErrors

            func LogErrors() bool

            func MouseWheelEventDelta

            func MouseWheelEventDelta(button MouseButton) int

            func MouseWheelEventKeyState

            func MouseWheelEventKeyState(button MouseButton) int

            func MsgBox

            func MsgBox(owner Form, title, message string, style MsgBoxStyle) int

            func MustRegisterWindowClass

            func MustRegisterWindowClass(className string)

              MustRegisterWindowClass registers the specified window class.

              MustRegisterWindowClass must be called once for every window type that is not based on any system provided control, before calling InitChildWidget or InitWidget. Calling MustRegisterWindowClass twice with the same className results in a panic.

              func MustRegisterWindowClassWithStyle

              func MustRegisterWindowClassWithStyle(className string, style uint32)

              func MustRegisterWindowClassWithWndProcPtr

              func MustRegisterWindowClassWithWndProcPtr(className string, wndProcPtr uintptr)

              func MustRegisterWindowClassWithWndProcPtrAndStyle

              func MustRegisterWindowClassWithWndProcPtrAndStyle(className string, wndProcPtr uintptr, style uint32)

              func PanicOnError

              func PanicOnError() bool

              func ParseFloat

              func ParseFloat(s string) (float64, error)

              func PersonalPath

              func PersonalPath() (string, error)

              func RegistryKeyString

              func RegistryKeyString(rootKey *RegistryKey, subKeyPath, valueName string) (value string, err error)

              func RegistryKeyUint32

              func RegistryKeyUint32(rootKey *RegistryKey, subKeyPath, valueName string) (value uint32, err error)

              func SetLogErrors

              func SetLogErrors(v bool)

              func SetPanicOnError

              func SetPanicOnError(v bool)

              func SetTranslationFunc

              func SetTranslationFunc(f TranslationFunction)

              func SetWindowFont

              func SetWindowFont(hwnd win.HWND, font *Font)

              func ShiftDown

              func ShiftDown() bool

              func SystemPath

              func SystemPath() (string, error)


              type AccRole

              type AccRole int32

                AccRole enum defines the role of the window/control in UI.

                const (
                	AccRoleTitlebar           AccRole = win.ROLE_SYSTEM_TITLEBAR
                	AccRoleMenubar            AccRole = win.ROLE_SYSTEM_MENUBAR
                	AccRoleScrollbar          AccRole = win.ROLE_SYSTEM_SCROLLBAR
                	AccRoleGrip               AccRole = win.ROLE_SYSTEM_GRIP
                	AccRoleSound              AccRole = win.ROLE_SYSTEM_SOUND
                	AccRoleCursor             AccRole = win.ROLE_SYSTEM_CURSOR
                	AccRoleCaret              AccRole = win.ROLE_SYSTEM_CARET
                	AccRoleAlert              AccRole = win.ROLE_SYSTEM_ALERT
                	AccRoleWindow             AccRole = win.ROLE_SYSTEM_WINDOW
                	AccRoleClient             AccRole = win.ROLE_SYSTEM_CLIENT
                	AccRoleMenuPopup          AccRole = win.ROLE_SYSTEM_MENUPOPUP
                	AccRoleMenuItem           AccRole = win.ROLE_SYSTEM_MENUITEM
                	AccRoleTooltip            AccRole = win.ROLE_SYSTEM_TOOLTIP
                	AccRoleApplication        AccRole = win.ROLE_SYSTEM_APPLICATION
                	AccRoleDocument           AccRole = win.ROLE_SYSTEM_DOCUMENT
                	AccRolePane               AccRole = win.ROLE_SYSTEM_PANE
                	AccRoleChart              AccRole = win.ROLE_SYSTEM_CHART
                	AccRoleDialog             AccRole = win.ROLE_SYSTEM_DIALOG
                	AccRoleBorder             AccRole = win.ROLE_SYSTEM_BORDER
                	AccRoleGrouping           AccRole = win.ROLE_SYSTEM_GROUPING
                	AccRoleSeparator          AccRole = win.ROLE_SYSTEM_SEPARATOR
                	AccRoleToolbar            AccRole = win.ROLE_SYSTEM_TOOLBAR
                	AccRoleStatusbar          AccRole = win.ROLE_SYSTEM_STATUSBAR
                	AccRoleTable              AccRole = win.ROLE_SYSTEM_TABLE
                	AccRoleColumnHeader       AccRole = win.ROLE_SYSTEM_COLUMNHEADER
                	AccRoleRowHeader          AccRole = win.ROLE_SYSTEM_ROWHEADER
                	AccRoleColumn             AccRole = win.ROLE_SYSTEM_COLUMN
                	AccRoleRow                AccRole = win.ROLE_SYSTEM_ROW
                	AccRoleCell               AccRole = win.ROLE_SYSTEM_CELL
                	AccRoleLink               AccRole = win.ROLE_SYSTEM_LINK
                	AccRoleHelpBalloon        AccRole = win.ROLE_SYSTEM_HELPBALLOON
                	AccRoleCharacter          AccRole = win.ROLE_SYSTEM_CHARACTER
                	AccRoleList               AccRole = win.ROLE_SYSTEM_LIST
                	AccRoleListItem           AccRole = win.ROLE_SYSTEM_LISTITEM
                	AccRoleOutline            AccRole = win.ROLE_SYSTEM_OUTLINE
                	AccRoleOutlineItem        AccRole = win.ROLE_SYSTEM_OUTLINEITEM
                	AccRolePagetab            AccRole = win.ROLE_SYSTEM_PAGETAB
                	AccRolePropertyPage       AccRole = win.ROLE_SYSTEM_PROPERTYPAGE
                	AccRoleIndicator          AccRole = win.ROLE_SYSTEM_INDICATOR
                	AccRoleGraphic            AccRole = win.ROLE_SYSTEM_GRAPHIC
                	AccRoleStatictext         AccRole = win.ROLE_SYSTEM_STATICTEXT
                	AccRoleText               AccRole = win.ROLE_SYSTEM_TEXT
                	AccRolePushbutton         AccRole = win.ROLE_SYSTEM_PUSHBUTTON
                	AccRoleCheckbutton        AccRole = win.ROLE_SYSTEM_CHECKBUTTON
                	AccRoleRadiobutton        AccRole = win.ROLE_SYSTEM_RADIOBUTTON
                	AccRoleCombobox           AccRole = win.ROLE_SYSTEM_COMBOBOX
                	AccRoleDroplist           AccRole = win.ROLE_SYSTEM_DROPLIST
                	AccRoleProgressbar        AccRole = win.ROLE_SYSTEM_PROGRESSBAR
                	AccRoleDial               AccRole = win.ROLE_SYSTEM_DIAL
                	AccRoleHotkeyfield        AccRole = win.ROLE_SYSTEM_HOTKEYFIELD
                	AccRoleSlider             AccRole = win.ROLE_SYSTEM_SLIDER
                	AccRoleSpinbutton         AccRole = win.ROLE_SYSTEM_SPINBUTTON
                	AccRoleDiagram            AccRole = win.ROLE_SYSTEM_DIAGRAM
                	AccRoleAnimation          AccRole = win.ROLE_SYSTEM_ANIMATION
                	AccRoleEquation           AccRole = win.ROLE_SYSTEM_EQUATION
                	AccRoleButtonDropdown     AccRole = win.ROLE_SYSTEM_BUTTONDROPDOWN
                	AccRoleButtonMenu         AccRole = win.ROLE_SYSTEM_BUTTONMENU
                	AccRoleButtonDropdownGrid AccRole = win.ROLE_SYSTEM_BUTTONDROPDOWNGRID
                	AccRoleWhitespace         AccRole = win.ROLE_SYSTEM_WHITESPACE
                	AccRolePageTabList        AccRole = win.ROLE_SYSTEM_PAGETABLIST
                	AccRoleClock              AccRole = win.ROLE_SYSTEM_CLOCK
                	AccRoleSplitButton        AccRole = win.ROLE_SYSTEM_SPLITBUTTON
                	AccRoleIPAddress          AccRole = win.ROLE_SYSTEM_IPADDRESS
                	AccRoleOutlineButton      AccRole = win.ROLE_SYSTEM_OUTLINEBUTTON

                  Window/control system roles

                  type AccState

                  type AccState int32

                    AccState enum defines the state of the window/control

                    const (
                    	AccStateNormal          AccState = win.STATE_SYSTEM_NORMAL
                    	AccStateUnavailable     AccState = win.STATE_SYSTEM_UNAVAILABLE
                    	AccStateSelected        AccState = win.STATE_SYSTEM_SELECTED
                    	AccStateFocused         AccState = win.STATE_SYSTEM_FOCUSED
                    	AccStatePressed         AccState = win.STATE_SYSTEM_PRESSED
                    	AccStateChecked         AccState = win.STATE_SYSTEM_CHECKED
                    	AccStateMixed           AccState = win.STATE_SYSTEM_MIXED
                    	AccStateIndeterminate   AccState = win.STATE_SYSTEM_INDETERMINATE
                    	AccStateReadonly        AccState = win.STATE_SYSTEM_READONLY
                    	AccStateHotTracked      AccState = win.STATE_SYSTEM_HOTTRACKED
                    	AccStateDefault         AccState = win.STATE_SYSTEM_DEFAULT
                    	AccStateExpanded        AccState = win.STATE_SYSTEM_EXPANDED
                    	AccStateCollapsed       AccState = win.STATE_SYSTEM_COLLAPSED
                    	AccStateBusy            AccState = win.STATE_SYSTEM_BUSY
                    	AccStateFloating        AccState = win.STATE_SYSTEM_FLOATING
                    	AccStateMarqueed        AccState = win.STATE_SYSTEM_MARQUEED
                    	AccStateAnimated        AccState = win.STATE_SYSTEM_ANIMATED
                    	AccStateInvisible       AccState = win.STATE_SYSTEM_INVISIBLE
                    	AccStateOffscreen       AccState = win.STATE_SYSTEM_OFFSCREEN
                    	AccStateSizeable        AccState = win.STATE_SYSTEM_SIZEABLE
                    	AccStateMoveable        AccState = win.STATE_SYSTEM_MOVEABLE
                    	AccStateSelfVoicing     AccState = win.STATE_SYSTEM_SELFVOICING
                    	AccStateFocusable       AccState = win.STATE_SYSTEM_FOCUSABLE
                    	AccStateSelectable      AccState = win.STATE_SYSTEM_SELECTABLE
                    	AccStateLinked          AccState = win.STATE_SYSTEM_LINKED
                    	AccStateTraversed       AccState = win.STATE_SYSTEM_TRAVERSED
                    	AccStateMultiselectable AccState = win.STATE_SYSTEM_MULTISELECTABLE
                    	AccStateExtselectable   AccState = win.STATE_SYSTEM_EXTSELECTABLE
                    	AccStateAlertLow        AccState = win.STATE_SYSTEM_ALERT_LOW
                    	AccStateAlertMedium     AccState = win.STATE_SYSTEM_ALERT_MEDIUM
                    	AccStateAlertHigh       AccState = win.STATE_SYSTEM_ALERT_HIGH
                    	AccStateProtected       AccState = win.STATE_SYSTEM_PROTECTED
                    	AccStateHasPopup        AccState = win.STATE_SYSTEM_HASPOPUP
                    	AccStateValid           AccState = win.STATE_SYSTEM_VALID

                      Window/control states

                      type Accessibility

                      type Accessibility struct {
                      	// contains filtered or unexported fields

                        Accessibility provides basic Dynamic Annotation of windows and controls.

                        func (*Accessibility) SetAccelerator

                        func (a *Accessibility) SetAccelerator(acc string) error

                          SetAccelerator sets window accelerator name using Dynamic Annotation.

                          func (*Accessibility) SetDefaultAction

                          func (a *Accessibility) SetDefaultAction(defAction string) error

                            SetDefaultAction sets window default action using Dynamic Annotation.

                            func (*Accessibility) SetDescription

                            func (a *Accessibility) SetDescription(acc string) error

                              SetDescription sets window description using Dynamic Annotation.

                              func (*Accessibility) SetHelp

                              func (a *Accessibility) SetHelp(help string) error

                                SetHelp sets window help using Dynamic Annotation.

                                func (*Accessibility) SetName

                                func (a *Accessibility) SetName(name string) error

                                  SetName sets window name using Dynamic Annotation.

                                  func (*Accessibility) SetRole

                                  func (a *Accessibility) SetRole(role AccRole) error

                                    SetRole sets window role using Dynamic Annotation. The role must be set when the window is created and is not to be modified later.

                                    func (*Accessibility) SetRoleMap

                                    func (a *Accessibility) SetRoleMap(roleMap string) error

                                      SetRoleMap sets window role map using Dynamic Annotation. The role map must be set when the window is created and is not to be modified later.

                                      func (*Accessibility) SetState

                                      func (a *Accessibility) SetState(state AccState) error

                                        SetState sets window state using Dynamic Annotation.

                                        func (*Accessibility) SetStateMap

                                        func (a *Accessibility) SetStateMap(stateMap string) error

                                          SetStateMap sets window state map using Dynamic Annotation. The state map must be set when the window is created and is not to be modified later.

                                          func (*Accessibility) SetValueMap

                                          func (a *Accessibility) SetValueMap(valueMap string) error

                                            SetValueMap sets window value map using Dynamic Annotation. The value map must be set when the window is created and is not to be modified later.

                                            type Action

                                            type Action struct {
                                            	// contains filtered or unexported fields

                                            func NewAction

                                            func NewAction() *Action

                                            func NewMenuAction

                                            func NewMenuAction(menu *Menu) *Action

                                            func NewSeparatorAction

                                            func NewSeparatorAction() *Action

                                            func (*Action) Checkable

                                            func (a *Action) Checkable() bool

                                            func (*Action) Checked

                                            func (a *Action) Checked() bool

                                            func (*Action) CheckedCondition

                                            func (a *Action) CheckedCondition() Condition

                                            func (*Action) Default

                                            func (a *Action) Default() bool

                                            func (*Action) DefaultCondition

                                            func (a *Action) DefaultCondition() Condition

                                            func (*Action) Enabled

                                            func (a *Action) Enabled() bool

                                            func (*Action) EnabledCondition

                                            func (a *Action) EnabledCondition() Condition

                                            func (*Action) Exclusive

                                            func (a *Action) Exclusive() bool

                                            func (*Action) Image

                                            func (a *Action) Image() Image

                                            func (*Action) IsSeparator

                                            func (a *Action) IsSeparator() bool

                                            func (*Action) Menu

                                            func (a *Action) Menu() *Menu

                                            func (*Action) SetCheckable

                                            func (a *Action) SetCheckable(value bool) (err error)

                                            func (*Action) SetChecked

                                            func (a *Action) SetChecked(value bool) (err error)

                                            func (*Action) SetCheckedCondition

                                            func (a *Action) SetCheckedCondition(c Condition)

                                            func (*Action) SetDefault

                                            func (a *Action) SetDefault(value bool) (err error)

                                            func (*Action) SetDefaultCondition

                                            func (a *Action) SetDefaultCondition(c Condition)

                                            func (*Action) SetEnabled

                                            func (a *Action) SetEnabled(value bool) (err error)

                                            func (*Action) SetEnabledCondition

                                            func (a *Action) SetEnabledCondition(c Condition)

                                            func (*Action) SetExclusive

                                            func (a *Action) SetExclusive(value bool) (err error)

                                            func (*Action) SetImage

                                            func (a *Action) SetImage(value Image) (err error)

                                            func (*Action) SetShortcut

                                            func (a *Action) SetShortcut(shortcut Shortcut) (err error)

                                            func (*Action) SetText

                                            func (a *Action) SetText(value string) (err error)

                                            func (*Action) SetToolTip

                                            func (a *Action) SetToolTip(value string) (err error)

                                            func (*Action) SetVisible

                                            func (a *Action) SetVisible(value bool) (err error)

                                            func (*Action) SetVisibleCondition

                                            func (a *Action) SetVisibleCondition(c Condition)

                                            func (*Action) Shortcut

                                            func (a *Action) Shortcut() Shortcut

                                            func (*Action) Text

                                            func (a *Action) Text() string

                                            func (*Action) ToolTip

                                            func (a *Action) ToolTip() string

                                            func (*Action) Triggered

                                            func (a *Action) Triggered() *Event

                                            func (*Action) Visible

                                            func (a *Action) Visible() bool

                                            func (*Action) VisibleCondition

                                            func (a *Action) VisibleCondition() Condition

                                            type ActionList

                                            type ActionList struct {
                                            	// contains filtered or unexported fields

                                            func (*ActionList) Add

                                            func (l *ActionList) Add(action *Action) error

                                            func (*ActionList) AddMenu

                                            func (l *ActionList) AddMenu(menu *Menu) (*Action, error)

                                            func (*ActionList) At

                                            func (l *ActionList) At(index int) *Action

                                            func (*ActionList) Clear

                                            func (l *ActionList) Clear() error

                                            func (*ActionList) Contains

                                            func (l *ActionList) Contains(action *Action) bool

                                            func (*ActionList) Index

                                            func (l *ActionList) Index(action *Action) int

                                            func (*ActionList) Insert

                                            func (l *ActionList) Insert(index int, action *Action) error

                                            func (*ActionList) InsertMenu

                                            func (l *ActionList) InsertMenu(index int, menu *Menu) (*Action, error)

                                            func (*ActionList) Len

                                            func (l *ActionList) Len() int

                                            func (*ActionList) Remove

                                            func (l *ActionList) Remove(action *Action) error

                                            func (*ActionList) RemoveAt

                                            func (l *ActionList) RemoveAt(index int) error

                                            type Alignment1D

                                            type Alignment1D uint
                                            const (
                                            	AlignDefault Alignment1D = iota

                                            type Alignment2D

                                            type Alignment2D uint
                                            const (
                                            	AlignHVDefault Alignment2D = iota

                                            type Application

                                            type Application struct {
                                            	// contains filtered or unexported fields

                                            func App

                                            func App() *Application

                                            func (*Application) ActiveForm

                                            func (app *Application) ActiveForm() Form

                                              ActiveForm returns the currently active form for the caller's thread. It returns nil if no form is active or the caller's thread does not have any windows associated with it. It should be called from within synchronized functions.

                                              func (*Application) Exit

                                              func (app *Application) Exit(exitCode int)

                                              func (*Application) ExitCode

                                              func (app *Application) ExitCode() int

                                              func (*Application) OrganizationName

                                              func (app *Application) OrganizationName() string

                                              func (*Application) Panicking

                                              func (app *Application) Panicking() *ErrorEvent

                                              func (*Application) ProductName

                                              func (app *Application) ProductName() string

                                              func (*Application) SetOrganizationName

                                              func (app *Application) SetOrganizationName(value string)

                                              func (*Application) SetProductName

                                              func (app *Application) SetProductName(value string)

                                              func (*Application) SetSettings

                                              func (app *Application) SetSettings(value Settings)

                                              func (*Application) Settings

                                              func (app *Application) Settings() Settings

                                              type ApplyDPIer

                                              type ApplyDPIer interface {
                                              	ApplyDPI(dpi int)

                                              type ApplyFonter

                                              type ApplyFonter interface {
                                              	ApplyFont(font *Font)

                                              type ApplySysColorser

                                              type ApplySysColorser interface {

                                              type BindingValueProvider

                                              type BindingValueProvider interface {
                                              	BindingValue(index int) interface{}

                                                BindingValueProvider is the interface that a model must implement to support data binding with widgets like ComboBox.

                                                type Bitmap

                                                type Bitmap struct {
                                                	// contains filtered or unexported fields

                                                func BitmapFrom

                                                func BitmapFrom(src interface{}, dpi int) (*Bitmap, error)

                                                func NewBitmap

                                                func NewBitmap(size Size) (*Bitmap, error)

                                                  NewBitmap creates an opaque bitmap with given size in 1/96" units at screen DPI.

                                                  Deprecated: Newer applications should use NewBitmapForDPI.

                                                  func NewBitmapForDPI

                                                  func NewBitmapForDPI(size Size, dpi int) (*Bitmap, error)

                                                    NewBitmapForDPI creates an opaque bitmap with given size in native pixels and DPI.

                                                    func NewBitmapFromFile

                                                    func NewBitmapFromFile(filePath string) (*Bitmap, error)

                                                      NewBitmapFromFile creates new bitmap from a bitmap file at 96dpi.

                                                      Deprecated: Newer applications should use NewBitmapFromFileForDPI.

                                                      func NewBitmapFromFileForDPI

                                                      func NewBitmapFromFileForDPI(filePath string, dpi int) (*Bitmap, error)

                                                        NewBitmapFromFileForDPI creates new bitmap from a bitmap file at given DPI.

                                                        func NewBitmapFromIcon

                                                        func NewBitmapFromIcon(icon *Icon, size Size) (*Bitmap, error)

                                                          NewBitmapFromIcon creates a new bitmap with given size in native pixels and 96dpi and paints the icon on it.

                                                          Deprecated: Newer applications should use NewBitmapFromIconForDPI.

                                                          func NewBitmapFromIconForDPI

                                                          func NewBitmapFromIconForDPI(icon *Icon, size Size, dpi int) (*Bitmap, error)

                                                            NewBitmapFromIconForDPI creates a new bitmap with given size in native pixels and DPI and paints the icon on it.

                                                            func NewBitmapFromImage

                                                            func NewBitmapFromImage(im image.Image) (*Bitmap, error)

                                                              NewBitmapFromImage creates a Bitmap from image.Image at 96dpi.

                                                              Deprecated: Newer applications should use NewBitmapFromImageForDPI.

                                                              func NewBitmapFromImageForDPI

                                                              func NewBitmapFromImageForDPI(im image.Image, dpi int) (*Bitmap, error)

                                                                NewBitmapFromImageForDPI creates a Bitmap from image.Image at given DPI.

                                                                func NewBitmapFromImageWithSize

                                                                func NewBitmapFromImageWithSize(image Image, size Size) (*Bitmap, error)

                                                                  NewBitmapFromImageWithSize creates a bitmap with given size in native units and paints the image on it streched.

                                                                  func NewBitmapFromResource

                                                                  func NewBitmapFromResource(name string) (*Bitmap, error)

                                                                    NewBitmapFromResource creates a Bitmap at 96dpi from resource by name.

                                                                    Deprecated: Newer applications should use NewBitmapFromResourceForDPI.

                                                                    func NewBitmapFromResourceForDPI

                                                                    func NewBitmapFromResourceForDPI(name string, dpi int) (*Bitmap, error)

                                                                      NewBitmapFromResourceForDPI creates a Bitmap at given DPI from resource by name.

                                                                      func NewBitmapFromResourceId

                                                                      func NewBitmapFromResourceId(id int) (*Bitmap, error)

                                                                        NewBitmapFromResourceId creates a Bitmap at 96dpi from resource by ID.

                                                                        Deprecated: Newer applications should use NewBitmapFromResourceIdForDPI.

                                                                        func NewBitmapFromResourceIdForDPI

                                                                        func NewBitmapFromResourceIdForDPI(id int, dpi int) (*Bitmap, error)

                                                                          NewBitmapFromResourceIdForDPI creates a Bitmap at given DPI from resource by ID.

                                                                          func NewBitmapFromWindow

                                                                          func NewBitmapFromWindow(window Window) (*Bitmap, error)

                                                                          func NewBitmapWithTransparentPixels

                                                                          func NewBitmapWithTransparentPixels(size Size) (*Bitmap, error)

                                                                            NewBitmapWithTransparentPixels creates a transparent bitmap with given size in 1/96" units at screen DPI.

                                                                            Deprecated: Newer applications should use NewBitmapWithTransparentPixelsForDPI.

                                                                            func NewBitmapWithTransparentPixelsForDPI

                                                                            func NewBitmapWithTransparentPixelsForDPI(size Size, dpi int) (*Bitmap, error)

                                                                              NewBitmapWithTransparentPixelsForDPI creates a transparent bitmap with given size in native pixels and DPI.

                                                                              func (*Bitmap) Dispose

                                                                              func (bmp *Bitmap) Dispose()

                                                                              func (*Bitmap) Size

                                                                              func (bmp *Bitmap) Size() Size

                                                                                Size returns bitmap size in 1/96" units.

                                                                                func (*Bitmap) ToImage

                                                                                func (bmp *Bitmap) ToImage() (*image.RGBA, error)

                                                                                type BitmapBrush

                                                                                type BitmapBrush struct {
                                                                                	// contains filtered or unexported fields

                                                                                func NewBitmapBrush

                                                                                func NewBitmapBrush(bitmap *Bitmap) (*BitmapBrush, error)

                                                                                func (*BitmapBrush) Bitmap

                                                                                func (b *BitmapBrush) Bitmap() *Bitmap

                                                                                func (*BitmapBrush) Dispose

                                                                                func (bb *BitmapBrush) Dispose()

                                                                                type BorderGlowEffect

                                                                                type BorderGlowEffect struct {
                                                                                	// contains filtered or unexported fields

                                                                                func NewBorderGlowEffect

                                                                                func NewBorderGlowEffect(color Color) (*BorderGlowEffect, error)

                                                                                func (*BorderGlowEffect) Dispose

                                                                                func (wgeb *BorderGlowEffect) Dispose()

                                                                                func (*BorderGlowEffect) Draw

                                                                                func (bge *BorderGlowEffect) Draw(widget Widget, canvas *Canvas) error

                                                                                type BoxLayout

                                                                                type BoxLayout struct {
                                                                                	// contains filtered or unexported fields

                                                                                func NewHBoxLayout

                                                                                func NewHBoxLayout() *BoxLayout

                                                                                func NewVBoxLayout

                                                                                func NewVBoxLayout() *BoxLayout

                                                                                func (*BoxLayout) CreateLayoutItem

                                                                                func (l *BoxLayout) CreateLayoutItem(ctx *LayoutContext) ContainerLayoutItem

                                                                                func (*BoxLayout) Orientation

                                                                                func (l *BoxLayout) Orientation() Orientation

                                                                                func (*BoxLayout) SetOrientation

                                                                                func (l *BoxLayout) SetOrientation(value Orientation) error

                                                                                func (*BoxLayout) SetStretchFactor

                                                                                func (l *BoxLayout) SetStretchFactor(widget Widget, factor int) error

                                                                                func (*BoxLayout) StretchFactor

                                                                                func (l *BoxLayout) StretchFactor(widget Widget) int

                                                                                type Brush

                                                                                type Brush interface {
                                                                                	// contains filtered or unexported methods

                                                                                func NullBrush

                                                                                func NullBrush() Brush

                                                                                type Button

                                                                                type Button struct {
                                                                                	// contains filtered or unexported fields

                                                                                func (*Button) ApplyDPI

                                                                                func (b *Button) ApplyDPI(dpi int)

                                                                                func (*Button) Checked

                                                                                func (b *Button) Checked() bool

                                                                                func (*Button) CheckedChanged

                                                                                func (b *Button) CheckedChanged() *Event

                                                                                func (*Button) Clicked

                                                                                func (b *Button) Clicked() *Event

                                                                                func (*Button) CreateLayoutItem

                                                                                func (b *Button) CreateLayoutItem(ctx *LayoutContext) LayoutItem

                                                                                func (*Button) Image

                                                                                func (b *Button) Image() Image

                                                                                func (*Button) ImageChanged

                                                                                func (b *Button) ImageChanged() *Event

                                                                                func (*Button) Persistent

                                                                                func (b *Button) Persistent() bool

                                                                                func (*Button) RestoreState

                                                                                func (b *Button) RestoreState() error

                                                                                func (*Button) SaveState

                                                                                func (b *Button) SaveState() error

                                                                                func (*Button) SetChecked

                                                                                func (b *Button) SetChecked(checked bool)

                                                                                func (*Button) SetImage

                                                                                func (b *Button) SetImage(image Image) error

                                                                                func (*Button) SetPersistent

                                                                                func (b *Button) SetPersistent(value bool)

                                                                                func (*Button) SetText

                                                                                func (b *Button) SetText(value string) error

                                                                                func (*Button) Text

                                                                                func (b *Button) Text() string

                                                                                func (*Button) WndProc

                                                                                func (b *Button) WndProc(hwnd win.HWND, msg uint32, wParam, lParam uintptr) uintptr

                                                                                type CancelEvent

                                                                                type CancelEvent struct {
                                                                                	// contains filtered or unexported fields

                                                                                func (*CancelEvent) Attach

                                                                                func (e *CancelEvent) Attach(handler CancelEventHandler) int

                                                                                func (*CancelEvent) Detach

                                                                                func (e *CancelEvent) Detach(handle int)

                                                                                func (*CancelEvent) Once

                                                                                func (e *CancelEvent) Once(handler CancelEventHandler)

                                                                                type CancelEventHandler

                                                                                type CancelEventHandler func(canceled *bool)

                                                                                type CancelEventPublisher

                                                                                type CancelEventPublisher struct {
                                                                                	// contains filtered or unexported fields

                                                                                func (*CancelEventPublisher) Event

                                                                                func (p *CancelEventPublisher) Event() *CancelEvent

                                                                                func (*CancelEventPublisher) Publish

                                                                                func (p *CancelEventPublisher) Publish(canceled *bool)

                                                                                type Canvas

                                                                                type Canvas struct {
                                                                                	// contains filtered or unexported fields

                                                                                func NewCanvasFromImage

                                                                                func NewCanvasFromImage(image Image) (*Canvas, error)

                                                                                func (*Canvas) Bounds

                                                                                func (c *Canvas) Bounds() Rectangle

                                                                                func (*Canvas) BoundsPixels

                                                                                func (c *Canvas) BoundsPixels() Rectangle

                                                                                func (*Canvas) DPI

                                                                                func (c *Canvas) DPI() int

                                                                                func (*Canvas) Dispose

                                                                                func (c *Canvas) Dispose()

                                                                                func (*Canvas) DrawBitmapPart

                                                                                func (c *Canvas) DrawBitmapPart(bmp *Bitmap, dst, src