mirror of
https://github.com/storytold/designcraft.git
synced 2026-10-24 10:16:59 -06:00
A Flex Layout container is a frame holding its objects as nested items (as Edit › Paste Into makes), with a `flex` record: direction, wrap, justification, cross-axis alignment, Fixed/Auto width and height, padding and horizontal/vertical spacing. designcraft_doc::flex lays the objects out (a Flexbox subset: lines, justification, alignment, Auto sizing), and the engine runs it after every edit, so the container keeps its objects in place whatever changes. Commands: flex.add (Add to Flex Layout; detects aligned objects: their direction, Auto size, Space Between at their own spacing, as InDesign does), flex.convert (a group or rectangle frame), flex.remove (objects stay, grouped), flex.set (every panel setting, plus the alignment grid cell), flex.reorder. Resizing a container by its handles or W/H changes its box and makes that side Fixed instead of scaling its objects; dragging an object inside one drops it in the nearest place. UI: Object › Flex Layout (Add to, Convert to, Remove, Show Flex Controls), a Flex Layout panel (Window › Panels) laid out as InDesign's (Create Flex Layout; alignment grid, W/H with Auto/Fixed; justification menu, four directions, wrap; padding with the link button; spacing, greyed as InDesign does when the justification works it out or nothing wraps), and the same section in Properties. Icons are new drawings. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>