Documentation ¶
Index ¶
- Variables
- type Tk
- func (tk *Tk) CreateBindCommand(el element.Element, name string, callback command.BindCallback)
- func (tk *Tk) CreateCommand(el element.Element, name string, callback command.Callback)
- func (tk *Tk) CreateFontDialogCommand(el element.Element, name string, callback command.FontDialogCallback)
- func (tk *Tk) Destroy()
- func (tk *Tk) DestroyCommand(name string)
- func (tk *Tk) DestroyVar(name string)
- func (tk *Tk) Eval(format string, a ...any)
- func (tk *Tk) GetBoolResult() bool
- func (tk *Tk) GetFloatResult() float64
- func (tk *Tk) GetIntResult() int
- func (tk *Tk) GetStrResult() string
- func (tk *Tk) GetStrSliceResult() []string
- func (tk *Tk) GetVarBoolValue(name string) bool
- func (tk *Tk) GetVarFloatValue(name string) float64
- func (tk *Tk) GetVarIntValue(name string) int
- func (tk *Tk) GetVarStrValue(name string) string
- func (tk *Tk) SetVarFloatValue(name string, val float64)
- func (tk *Tk) SetVarStrValue(name string, val string)
- func (tk *Tk) Start()
Constants ¶
This section is empty.
Variables ¶
var ( Binding = regexp.MustCompile(`^<.*?>$`) Event = regexp.MustCompile(`^<.*?>$`) VirtualEvent = regexp.MustCompile(`^<<.*?>>$`) )
Functions ¶
This section is empty.
Types ¶
type Tk ¶
type Tk struct {
// contains filtered or unexported fields
}
Tk is the main interpreter.
func (*Tk) CreateBindCommand ¶
CreateBindCommand creates a custom command in the interpreter.
func (*Tk) CreateCommand ¶
CreateCommand creates a custom command in the interpreter.
func (*Tk) CreateFontDialogCommand ¶
func (tk *Tk) CreateFontDialogCommand(el element.Element, name string, callback command.FontDialogCallback)
CreateFontDialogCommand creates a custom command in the interpreter.
func (*Tk) Destroy ¶
func (tk *Tk) Destroy()
Destroy deletes the interpreter and cleans up its resources.
func (*Tk) DestroyCommand ¶
DestroyCommand destroys a command and cleans up its resources.
func (*Tk) DestroyVar ¶
DestroyVar destroys a variable and cleans up its resources.
func (*Tk) Eval ¶
Eval passes the specified command to the interpreter for evaluation. This will end the program on any error.
func (*Tk) GetBoolResult ¶
GetBoolResult gets the interpreter result as a boolean.
func (*Tk) GetFloatResult ¶
GetFloatResult gets the interpreter result as a float.
func (*Tk) GetIntResult ¶
GetStrResult gets the interpreter result as a string.
func (*Tk) GetStrResult ¶
GetStrResult gets the interpreter result as a string.
func (*Tk) GetStrSliceResult ¶
func (*Tk) GetVarBoolValue ¶
GetVarBoolValue gets the named variable value as a boolean.
func (*Tk) GetVarFloatValue ¶
GetVarFloatValue gets the named variable value as a float.
func (*Tk) GetVarIntValue ¶
GetVarIntValue gets the named variable value as an integer.
func (*Tk) GetVarStrValue ¶
GetVarStrValue gets the named variable value as a string.
func (*Tk) SetVarFloatValue ¶
SetVarFloatValue sets the named variable value using a string.
func (*Tk) SetVarStrValue ¶
SetVarStrValue sets the named variable value using a string.