A single-line text field over edit. Returns whether the text changed and whether Enter was
pressed.
- edit: the text being edited.
- options: placeholder, size and read-only mode. The font is always the sans one, with no line numbers and no growing.
- loc: the call site. It identifies the widget from one frame to the next, so leave the default.
text_field :: (
edit: *Text_Edit,
options: Editor_Options = .{},
loc := #caller_location
) -> (changed: bool, submitted: bool)
A single-line text field over edit. Returns whether the text changed and whether Enter was
pressed.
Parameters
- edit: *Text_Edit
- the text being edited.
- options: Editor_Options
- placeholder, size and read-only mode. The font is always the sans one, with no line numbers and no growing.
- loc := #caller_location
- the call site. It identifies the widget from one frame to the next, so leave the default.
Returns
- changed: bool
- submitted: bool