Stamp Module
Functions and values
| Function or value |
Description
|
|
|
|
|
|
A sized box painted by a list of box styles (`Flow.fill`, `Flow.border`, `Flow.noise`, ...). The size is stated once, here; styles and containers never need coordinates. For a context-sized box (grid areas, docked rectangles, expanded slots) use `Flow.canvas`.
|
Full Usage:
Stamp.create w h paint
Parameters:
int
h : int
paint : GridSection2D<'T> -> unit
Returns: Stamp<'T>
Type parameters: 'T |
Creates a leaf element with a fixed cell footprint.
|
|
|
|
Marks an element to share the leftover main-axis space of its container with weight 1. Expanded elements split the leftover space by weight. Only `Flow.row` and `Flow.column` act on `Expand`; other containers throw when a direct child carries it. Combinators (`beside`, `above`, `overlay`, `inset`, `offset`, `repeat`) throw when the wrapped element carries it; apply `expand` to the composite instead.
|
|
|
|
|
|
|
|
|
|
|
|
Draws both elements over the full area of the container, `second` on top. Both elements are full-bleed stack children (`canvas`, `docked`, `at`, `strip`, `stretch`), so a sized element throws at construction — it would silently paint the whole area. The footprint is zero: the composite is context-sized.
|
|
|
Full Usage:
Stamp.sized w h paint
Parameters:
int
h : int
paint : GridSection2D<'T> -> GridSection2D<'T>
Returns: Stamp<'T>
Type parameters: 'T |
Wraps an existing section-transforming stamp (any `Layout.*` pipeline) as a sized element. The wrapped stamp still paints with local coordinates.
|
|
Tags an element so `Flow.run` groups its resolved rectangle under each tag and marks the covered cells in the per-tag bit grids. Tags are opaque to the engine; the game defines what they mean. Multiple elements can share a tag, and one element can carry several.
|
Mibo