class
Prostore::TUI::RecordDetail
- Prostore::TUI::RecordDetail
- TUI::Widget
- Reference
- Object
Defined in:
prostore/tui/widgets/record_detail.crConstant Summary
-
TEXT_EDIT_MAX_ROWS =
8 -
Ceiling on how many display rows an open text editor may claim — ScrollableField owns its own internal Scroller/scrollbar, so a value longer than this just scrolls inside a fixed-height window instead of growing the field indefinitely (unlike the old bespoke editor, which sized itself to the full wrapped line count).
Constructors
- .for_new_record(x : Int32, y : Int32, width : Int32, height : Int32, browser : Browser, table : String) : RecordDetail
- .new(x : Int32, y : Int32, width : Int32, height : Int32, browser : Browser, table : String, pk_col : String | Nil, pk_val : String)
Instance Method Summary
-
#dirty : Set(String)
Column names mutated since the last load/reload — also useful to an embedding app deciding whether to prompt before discarding an in-progress edit, not just for spec assertions.
-
#field_errors : Hash(String, String)
Per-column inline validation error messages, keyed by column name.
-
#handle_key(ev : ::TUI::KeyEvent) : Bool
Returns true if the key was consumed.
- #on_close : Proc(Nil) | Nil
- #on_close=(on_close : Proc(Nil) | Nil)
- #on_follow_fk : Proc(String, String, Nil) | Nil
- #on_follow_fk=(on_follow_fk : Proc(String, String, Nil) | Nil)
- #on_pick_fk : Proc(String, String, Nil) | Nil
- #on_pick_fk=(on_pick_fk : Proc(String, String, Nil) | Nil)
- #reload : Nil
-
#render : Nil
Draw into @buffer using LOCAL coordinates (0, 0 = this widget's own top-left).
-
#row : Hash(String, RowVal)
The current in-memory row (raw stringified values, pre-save).
- #set_new_mode : Nil
- #set_row_value(col_name : String, value : String) : Nil
-
#status_hint : String
Context-aware hint surfaced in the App's global status bar.
Constructor Detail
Instance Method Detail
Column names mutated since the last load/reload — also useful to an embedding app deciding whether to prompt before discarding an in-progress edit, not just for spec assertions.
Per-column inline validation error messages, keyed by column name.
Returns true if the key was consumed.
Draw into @buffer using LOCAL coordinates (0, 0 = this widget's own
top-left). Widgets never need to know their own x/y offset to draw
themselves — that arithmetic is handled entirely by composite.
The current in-memory row (raw stringified values, pre-save).
Context-aware hint surfaced in the App's global status bar. All key bindings reachable from the current state are listed here so the user doesn't have to look in two places.