Documentation
¶
Overview ¶
Package forminput provides value-only text editing and ordered form navigation. Callers own key bindings, draft persistence, terminal I/O, and submission.
Index ¶
- func Cycle[T comparable](order []T, current T, backwards bool) (T, bool)
- type Editor
- func (e *Editor) Backspace()
- func (e *Editor) Clear()
- func (e *Editor) Delete()
- func (e *Editor) DeleteBefore()
- func (e *Editor) DeleteWordBefore()
- func (e *Editor) Insert(value string)
- func (e *Editor) LineEnd()
- func (e *Editor) LineStart()
- func (e *Editor) Move(delta int)
- func (e *Editor) MoveRow(down bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Cycle ¶
func Cycle[T comparable](order []T, current T, backwards bool) (T, bool)
Cycle wraps through visible focus IDs. Missing focus and empty orders preserve current and return false, letting each caller choose its recovery policy.
Types ¶
type Editor ¶
Editor edits runes, not bytes. Cursor must be between zero and len(Text). The caller owns Text; operations may reuse its backing array.
func (*Editor) DeleteBefore ¶
func (e *Editor) DeleteBefore()
func (*Editor) DeleteWordBefore ¶
func (e *Editor) DeleteWordBefore()
Click to show internal directories.
Click to hide internal directories.