pub struct Node {Show 13 fields
pub width: Size,
pub height: Size,
pub minimum_width: Size,
pub minimum_height: Size,
pub maximum_width: Size,
pub maximum_height: Size,
pub display: DisplayMode,
pub padding: Gaps,
pub margin: Gaps,
pub offset_x: Length<f32, Measure>,
pub offset_y: Length<f32, Measure>,
pub direction: DirectionMode,
pub has_layout_references: bool,
}
Expand description
Node layout configuration
Fields§
§width: Size
Dimentions
height: Size
§minimum_width: Size
§minimum_height: Size
§maximum_width: Size
§maximum_height: Size
§display: DisplayMode
Inner layout mode
padding: Gaps
Inner padding
margin: Gaps
Inner margin
offset_x: Length<f32, Measure>
Inner position offsets
offset_y: Length<f32, Measure>
§direction: DirectionMode
Direction in which it’s inner Nodes will be stacked
has_layout_references: bool
A Node might depend on inner sizes but have a fixed position, like scroll views.
Implementations§
§impl Node
impl Node
pub fn from_size_and_direction(
width: Size,
height: Size,
direction: DirectionMode
) -> Node
pub fn from_size_and_direction( width: Size, height: Size, direction: DirectionMode ) -> Node
Construct a new Node given a size and a direction
pub fn from_size_and_scroll(
width: Size,
height: Size,
offset_x: Length<f32, Measure>,
offset_y: Length<f32, Measure>
) -> Node
pub fn from_size_and_scroll( width: Size, height: Size, offset_x: Length<f32, Measure>, offset_y: Length<f32, Measure> ) -> Node
Construct a new Node given a size and a scroll
pub fn from_size_and_padding(width: Size, height: Size, padding: Gaps) -> Node
pub fn from_size_and_padding(width: Size, height: Size, padding: Gaps) -> Node
Construct a new Node given a size and padding
pub fn from_size_and_display_and_direction(
width: Size,
height: Size,
display: DisplayMode,
direction: DirectionMode
) -> Node
pub fn from_size_and_display_and_direction( width: Size, height: Size, display: DisplayMode, direction: DirectionMode ) -> Node
Construct a new Node given a size and a display
pub fn from_size_and_margin(width: Size, height: Size, margin: Gaps) -> Node
pub fn from_size_and_margin(width: Size, height: Size, margin: Gaps) -> Node
Construct a new Node given a size and a direction
pub fn does_depend_on_inner(&self) -> bool
pub fn does_depend_on_inner(&self) -> bool
Has properties that depend on the inner Nodes?
Trait Implementations§
impl StructuralPartialEq for Node
Auto Trait Implementations§
impl RefUnwindSafe for Node
impl Send for Node
impl Sync for Node
impl Unpin for Node
impl UnwindSafe for Node
Blanket Implementations§
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere T: Default,
type NoneType = T
§fn null_value() -> T
fn null_value() -> T
The none-equivalent value.