Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Action ¶ added in v0.7.3
type Action struct { ActionType ActionType WidgetType WidgetType WidgetId int ParentId int Text string // what is visable to the user Name string // a name useful for programming // This is how the values are passed back and forth // values from things like checkboxes & dropdown's B bool I int S string // This is used for things like a slider(0,100) X int Y int // This is for the grid size & widget position W int H int AtW int AtH int // Put space around elements to improve look & feel Margin bool // Make widgets fill up the space available Expand bool A any // switch to this or deprecate this? pros/cons? }
type ActionType ¶ added in v0.7.3
type ActionType int // Add, SetText, Click, Hide, Append, Delete, etc
const ( Add ActionType = iota Delete Get Set GetText SetText AddText Show Hide Enable Disable Margin Unmargin Pad Unpad Append Move Dump User // the user did something (mouse, keyboard, etc) InitToolkit // initializes the toolkit CloseToolkit // closes the toolkit UserQuit // the user closed the GUI EnableDebug // open the debugging window )
func (ActionType) String ¶ added in v0.7.3
func (s ActionType) String() string
type WidgetType ¶
type WidgetType int // Button, Menu, Checkbox, etc.
const ( Unknown WidgetType = iota Root // the master 'root' node of the binary tree Flag // used to send configuration values to plugins Window // in certain gui's (ncurses), these are tabs Tab // internally, this is a window Frame // deprecate? Grid // like drawers in a chest Group // like the 'Appetizers' section on a menu Box // a vertical or horizontal stack of widgets Button Checkbox // select 'on' or 'off' Dropdown Combobox // dropdown with edit=true Label Textbox // is this a Label with edit=true Slider // like a progress bar Spinner // like setting the oven temperature Image // TODO Area // TODO Form // TODO Font // TODO Color // TODO Dialog // TODO Stdout // can be used to capture and display log output )
func (WidgetType) String ¶
func (s WidgetType) String() string
Source Files
¶
- widget.go
Click to show internal directories.
Click to hide internal directories.