Skip to main content

Module layout_intents

Module layout_intents 

Source
Expand description

Apply a layout intent and store its result: the write path of every layout edit a window makes (layout.applyIntent), and of srv’s own placements (place_block). SPEC_STRONG_REDUCER_AUTHORITY_LAYOUT_2026_06_30.md §4.

Structs§

IntentOutcome 🔒
What became of an intent.

Enums§

Placement 🔒
Where place_block puts a block.

Functions§

apply_layout_intent 🔒
Dispatch LayoutApplyIntent and write its events to the layout row in one hold of the reducer lock, so rows are written in the order intents are applied. A failed write puts the tab back as the row has it. Publishes on success.
block_is_minimized 🔒
Whether block_id’s pane in tab_id is minimized (a chip). False when it is in no pane.
layout_row_version 🔒
The version of tab_id’s layout row (0 when it has none).
minimize_block_in_layout 🔒
Show block_id’s pane in tab_id as a chip, in srv’s tree and the window’s mirror (the minimize action). Not applied, and Ok(false), when it is the only pane there showing content: a tab always shows one. SPEC_DRAG_MINIMIZED_PANES_2026_10_20.md §3 C.
move_block_to_edge 🔒
Move block_id’s pane in tab_id to be a band down or across the layout’s edge, in srv’s tree and the window’s mirror (the movetoedge action; the edge rides in the action’s position). Not applied, and Ok(false), when the block is in no pane there or the layout refuses (the root, a chip strip, no middle).
place_block 🔒
Place block_id in its tab’s layout: srv applies the placement to its own tree, then queues the matching action for the window showing the tab, under the same action id and with the leaf’s node id, so the window’s mirror builds the tree srv stored.
remove_block_from_layout 🔒
Take block_id out of its tab’s layout in srv (one member of a stack, or its pane): LayoutDeleteNodeByBlock, stored and published. A block in no pane is a no-op.
roll_back 🔒
Put the tab back as old_row stores it, and forget the action id so a resend applies.