Expand description
The immediate-mode renderer for makeover_layout, written against egui.
egui’s Visuals.widgets.*.bg_stroke is one stroke with no per-side
control, so the two-tone lit edge is painted here by hand
(paint_bevel).
§What this crate draws
The parts of the description that carry no vocabulary member: depth
(frame, paint_bevel), the resolved colours (Palette), a table’s
per-frame facts and cell tones (table), the token and the waiting
marks (piece), and the egui visuals and metrics a host starts from
(host).
The vocabulary members (fields, columns, meters, controls, facts, figures
and charts) are drawn by quasi-immediate, which owns those types through
quasi-router and calls into this crate for everything above. The style
types it draws them with stay here: FieldStyle, Editing,
piece::PieceStyle and table::TableStyle.
§What this crate does and does not own
It owns the expression: two mitred polylines for a bevel and a Frame for
a filled region. It owns no colours and makes no substitutions: the caller
supplies Palette already resolved.
Every radius, margin, stroke width and floor arrives in a style type
(FrameStyle, FieldStyle, piece::PieceStyle,
table::TableStyle, host::Metrics). The focus ring and target floor
in host::Metrics default to what makeover-webview emits.
makeover itself is linked only by the theme feature, for
Palette::from_theme; it embeds every shipped theme file.
§Pressed state
There is no cascade to carry a pressed state, so each call site asks
makeover_layout::Depth::pressed for the depth a pressed region takes.
§Overlays
frame hands Palette::cast to the egui::Frame for any depth whose
fill is Fill::Overlay, keyed off the fill rather than the variant.
§Focus and chrome
egui decides what is reachable and what holds the keyboard, and paints the
one focus ring; this crate draws no ring of its own. The terms are defined
in makeover_layout’s crate header, “Reach, focus and the focus ring”.
App-level chrome is not drawn here. quasi-router names the affordances
that outlive one screen and quasi-immediate answers them; this crate
depends on makeover-layout and not on quasi-router.
Modules§
- host
- The design system, handed to egui as a
Style. - piece
- The described things that are not fields, tables or frames, and carry no vocabulary member: a token and a wait.
- table
- A table’s style, its per-frame facts, and the tone each part of a cell takes.
Structs§
- Field
Style - The geometry a field group is drawn with.
- Frame
Style - The geometry a framed region is drawn with.
- Missing
Token - A token
Palette::from_themeneeded and the theme did not resolve. - Palette
- The resolved colours this renderer needs, as flat values.
Enums§
- Editing
- What the field currently holds, borrowed from wherever the app keeps it.
Functions§
- frame
- Draw a region at a given
Depth: its fill and its edge, together. - paint_
bevel - Paint a two-tone edge just inside
rect.