pub struct LayoutPane {Show 13 fields
pub id: String,
pub title: String,
pub title_icon: Option<&'static str>,
pub position: Pos2,
pub size: Vec2,
pub pre_maximize_size: Option<Vec2>,
pub pre_maximize_position: Option<Pos2>,
pub closable: bool,
pub collapsed: bool,
pub maximized: bool,
pub resizable: bool,
pub min_size: Vec2,
pub lock_level: LockLevel,
}Expand description
A pane in the node layout
Fields§
§id: StringUnique identifier
title: StringDisplay title
title_icon: Option<&'static str>Optional title icon (Phosphor icon codepoint)
position: Pos2Position in graph space
size: Vec2Desired size (width, height)
pre_maximize_size: Option<Vec2>Size before maximize (for restore)
pre_maximize_position: Option<Pos2>Position before maximize (for restore)
closable: boolWhether the pane can be closed
collapsed: boolWhether the pane is currently collapsed (title bar only)
maximized: boolWhether the pane is maximized (fills canvas)
resizable: boolWhether the pane can be resized
min_size: Vec2Minimum size constraint
lock_level: LockLevelLock level (None, Light, Full)
Implementations§
Source§impl LayoutPane
impl LayoutPane
Sourcepub fn with_position(self, x: f32, y: f32) -> Self
pub fn with_position(self, x: f32, y: f32) -> Self
Set initial position
Sourcepub fn lock_level(self, level: LockLevel) -> Self
pub fn lock_level(self, level: LockLevel) -> Self
Set lock level
Trait Implementations§
Source§impl Clone for LayoutPane
impl Clone for LayoutPane
Source§fn clone(&self) -> LayoutPane
fn clone(&self) -> LayoutPane
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for LayoutPane
impl RefUnwindSafe for LayoutPane
impl Send for LayoutPane
impl Sync for LayoutPane
impl Unpin for LayoutPane
impl UnsafeUnpin for LayoutPane
impl UnwindSafe for LayoutPane
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.