LayoutContext
struct · ferroui-designer-tools · v0.5.0
struct LayoutContext<'a>
Bounds and resolved slots use one common coordinate space. Grid boundaries use panel-local units.
Members
documentboundsnewwith_grid_lineswith_resolved_layoutwith_resolved_propertiespropertychildrencontent_containerresolved_layoutis_visiblegrid_boundariesbounds
document
document: &'a ferroui_designer_core::Document
bounds
bounds: &'a std::collections::BTreeMap<ferroui_designer_core::NodeId, crate::Rect>
new
fn new(document: &'a Document, bounds: &'a BTreeMap<NodeId, Rect>) -> Self
with_grid_lines
fn with_grid_lines(self: Self, lines: &'a BTreeMap<NodeId, GridLines>) -> Self
with_resolved_layout
fn with_resolved_layout(self: Self, layout: &'a BTreeMap<NodeId, ResolvedLayout>) -> Self
with_resolved_properties
fn with_resolved_properties(self: Self, values: &'a BTreeMap<NodeId, BTreeMap<String, String>>) -> Self
Effective runtime values used to interpret panel layout, including styles and bindings. These values never replace authored expressions when an operation writes a property.
property
fn property(self: &Self, node: NodeId, name: &str) -> Option<&str>
children
fn children(self: &Self, panel: NodeId) -> Result<Vec<NodeId>>
The authored children, preserving their source order and explicit content slot.
content_container
fn content_container(self: &Self, panel: NodeId) -> Result<NodeId>
The AST owner of the panel's content, including explicit Children/Content/Child elements.
resolved_layout
fn resolved_layout(self: &Self, node: NodeId) -> Result<ResolvedLayout>
Resolved allocation before margin/alignment/render transforms, if supplied by the host.
is_visible
fn is_visible(self: &Self, node: NodeId) -> Result<bool>
grid_boundaries
fn grid_boundaries(self: &Self, panel: NodeId) -> Result<GridLines>
Actual Grid track boundaries. A portable fallback resolves unconstrained pixel/star tracks.
bounds
fn bounds(self: &Self, node: NodeId) -> Result<Rect>
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>Any
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.