Documentation ¶
Index ¶
- type EnumField
- func (n *EnumField) Blur()
- func (n *EnumField) Draw(screen tcell.Screen)
- func (n *EnumField) Focus(delegate func(p tview.Primitive))
- func (n *EnumField) GetFieldWidth() int
- func (n *EnumField) GetLabel() string
- func (n *EnumField) GetLabelWidth() int
- func (n *EnumField) GetText() string
- func (n *EnumField) InputHandler() func(event *tcell.EventKey, setFocus func(p tview.Primitive))
- func (n *EnumField) SetBackgroundColorActivated(color tcell.Color) *EnumField
- func (n *EnumField) SetFieldBackgroundColor(color tcell.Color) *EnumField
- func (n *EnumField) SetFinishedFunc(handler func(key tcell.Key)) tview.FormItem
- func (n *EnumField) SetFormAttributes(labelWidth int, labelColor, bgColor, fieldTextColor, fieldBgColor tcell.Color) tview.FormItem
- func (n *EnumField) SetLabel(x string) *EnumField
- func (n *EnumField) SetLabelColor(color tcell.Color) *EnumField
- func (n *EnumField) SetLabelColorActivated(color tcell.Color) *EnumField
- func (n *EnumField) SetLabelWidth(width int) *EnumField
- func (n *EnumField) SetOnBlurFunc(handler func()) *EnumField
- func (n *EnumField) SetOnFocusFunc(handler func()) *EnumField
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EnumField ¶
func NewEnumField ¶
NewEnumField returns a new navigation bar.
func (*EnumField) GetFieldWidth ¶
GetFieldWidth obtains a screen width of the input area. A value of 0 means extend as much as possible.
func (*EnumField) GetLabelWidth ¶
GetLabelWidth returns width of the label field.
func (*EnumField) InputHandler ¶
InputHandler returns the handler for this primitive.
func (*EnumField) SetBackgroundColorActivated ¶
SetBackgroundColorActivated sets the background color of the button text when the button is selected.
func (*EnumField) SetFieldBackgroundColor ¶
SetNavBackgroundColor sets the background color.
func (*EnumField) SetFinishedFunc ¶
SetFinishedFunc sets a callback invoked when the user leaves this form item.
func (*EnumField) SetFormAttributes ¶
func (n *EnumField) SetFormAttributes(labelWidth int, labelColor, bgColor, fieldTextColor, fieldBgColor tcell.Color) tview.FormItem
SetFormAttributes sets attributes shared by all form items. Only bgColor is considered for bg colors.
func (*EnumField) SetLabelColor ¶
SetLabelColor sets the color of button text.
func (*EnumField) SetLabelColorActivated ¶
SetLabelColorActivated sets the color of button text when the button is selected.
func (*EnumField) SetLabelWidth ¶
SetLabelWidth sets the screen width of the label. A value of 0 will cause the primitive to use the width of the label string.
func (*EnumField) SetOnBlurFunc ¶
SetOnBlurFunc sets a callback invoked when this primitive loses focus.
func (*EnumField) SetOnFocusFunc ¶
SetOnFocusFunc sets a callback invoked when this primitive receives focus.