Versions in this module Expand all Collapse all v0 v0.2.0 Apr 3, 2022 v0.1.0 Apr 1, 2022 Changes in this version + const ComponentClicked + const ComponentHovered + const ComponentIdle + type Button struct + func NewButton(x, y, width, height int, text string, callback ClickedCallback) *Button + func (b *Button) Draw(con *console.Console, timeElapsed float64) + func (b *Button) FocusOnClick() bool + func (b *Button) SetBackground(bg, bgHover, bgClicked *consolecolor.Color) + func (b *Button) SetForeground(f, fHover, fClicked *consolecolor.Color) + func (b *Button) Update(con *console.Console, timeElapsed float64) bool + type ClickedCallback func() + type ComponentState int + func CalculateComponentState(con *console.Console, x, y, w, h int) ComponentState + type EnterCallback func() + type TextBox struct + func NewTextbox(x, y, width, height int) *TextBox + func (tb *TextBox) Draw(con *console.Console, timeElapsed float64) + func (tb *TextBox) FocusOnClick() bool + func (tb *TextBox) GetText() string + func (tb *TextBox) SetBackground(bg, bgHover, bgClicked *consolecolor.Color) + func (tb *TextBox) SetEnterCallback(callback EnterCallback) + func (tb *TextBox) SetForeground(f, fInactive *consolecolor.Color) + func (tb *TextBox) SetText(newText string) + func (tb *TextBox) SetTextChanged(callback TextChangeCallback) + func (tb *TextBox) Update(con *console.Console, timeElapsed float64) bool + type TextChangeCallback func(text string)