pub struct SpatialLayout { /* private fields */ }Expand description
A spatial layout made of anchored panels.
Implementations§
Source§impl SpatialLayout
impl SpatialLayout
Sourcepub fn single_panel() -> Self
pub fn single_panel() -> Self
Builds the default single-panel layout.
Sourcepub fn default_arc() -> Self
pub fn default_arc() -> Self
Builds the default Viture workspace arc.
Sourcepub fn from_expr(expr: &Expr) -> Result<Self>
pub fn from_expr(expr: &Expr) -> Result<Self>
Parses a layout expression.
A layout is a map with an optional panels list. Each panel may carry
id, anchor, and transform fields. Missing fields use stable
defaults so a value can be encoded spatially without layout metadata.
Sourcepub fn panels(&self) -> &[PanelLayout]
pub fn panels(&self) -> &[PanelLayout]
Returns the panel layouts in order.
Trait Implementations§
Source§impl Clone for SpatialLayout
impl Clone for SpatialLayout
Source§fn clone(&self) -> SpatialLayout
fn clone(&self) -> SpatialLayout
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 SpatialLayout
impl Debug for SpatialLayout
Source§impl PartialEq for SpatialLayout
impl PartialEq for SpatialLayout
impl StructuralPartialEq for SpatialLayout
Auto Trait Implementations§
impl Freeze for SpatialLayout
impl RefUnwindSafe for SpatialLayout
impl Send for SpatialLayout
impl Sync for SpatialLayout
impl Unpin for SpatialLayout
impl UnsafeUnpin for SpatialLayout
impl UnwindSafe for SpatialLayout
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