#[non_exhaustive]pub struct NodeLayout {
pub id: String,
pub rect: Rect,
pub rank: usize,
}Expand description
Placement of one node: its card rectangle in cells plus its rank.
Engine-produced fact carrier (#[non_exhaustive] per ADR-0003 §1 —
cycle 2 will grow it, e.g. with port anchors). Read fields freely;
construct through NodeLayout::new (the 0430 editor synthesizes
layouts from user drags through the same door).
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: StringThe node id, echoed from the input.
rect: RectCard rectangle in cells; origin-normalized so the layout’s bounding box starts at (0, 0).
rank: usizeLayer index along the flow axis. layered computes it;
grid reports the grid row; force computes no hierarchy
and honestly reports 0 for every node.
Implementations§
Trait Implementations§
Source§impl Clone for NodeLayout
impl Clone for NodeLayout
Source§fn clone(&self) -> NodeLayout
fn clone(&self) -> NodeLayout
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for NodeLayout
impl Debug for NodeLayout
impl Eq for NodeLayout
Source§impl PartialEq for NodeLayout
impl PartialEq for NodeLayout
impl StructuralPartialEq for NodeLayout
Auto Trait Implementations§
impl Freeze for NodeLayout
impl RefUnwindSafe for NodeLayout
impl Send for NodeLayout
impl Sync for NodeLayout
impl Unpin for NodeLayout
impl UnsafeUnpin for NodeLayout
impl UnwindSafe for NodeLayout
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more