Skip to main content

NodeLayout

Struct NodeLayout 

Source
pub struct NodeLayout {
Show 34 fields pub display: Display, pub flex_direction: FlexDirection, pub flex_wrap: FlexWrap, pub grid_template_columns: Option<TrackList>, pub grid_template_rows: Option<TrackList>, pub grid_auto_columns: Option<TrackList>, pub grid_auto_rows: Option<TrackList>, pub grid_auto_flow: GridAutoFlow, pub row_gap: f32, pub column_gap: f32, pub justify_content: JustifyContent, pub align_items: AlignItems, pub align_content: AlignContent, pub justify_items: AlignItems, pub padding: Sides, pub border_width: f32, pub overflow: Overflow, pub width: Option<LayoutLength>, pub height: Option<LayoutLength>, pub min_width: Option<LayoutLength>, pub min_height: Option<LayoutLength>, pub max_width: Option<LayoutLength>, pub max_height: Option<LayoutLength>, pub aspect_ratio: Option<f32>, pub margin: Sides, pub flex_grow: f32, pub flex_shrink: f32, pub flex_basis: Option<LayoutLength>, pub align_self: Option<AlignItems>, pub justify_self: Option<AlignItems>, pub grid_column: GridPlacement, pub grid_row: GridPlacement, pub position: Position, pub inset: [Option<LayoutLength>; 4],
}
Expand description

A box’s sampled box-model, flex and grid values. Lengths are fractions or percents, never pixels.

Fields§

§display: Display§flex_direction: FlexDirection§flex_wrap: FlexWrap§grid_template_columns: Option<TrackList>§grid_template_rows: Option<TrackList>§grid_auto_columns: Option<TrackList>§grid_auto_rows: Option<TrackList>§grid_auto_flow: GridAutoFlow§row_gap: f32

The gap between rows: row_gap, else gap.

§column_gap: f32

The gap between columns: column_gap, else gap.

§justify_content: JustifyContent§align_items: AlignItems§align_content: AlignContent§justify_items: AlignItems§padding: Sides§border_width: f32

The border’s width; zero without one.

§overflow: Overflow§width: Option<LayoutLength>§height: Option<LayoutLength>§min_width: Option<LayoutLength>§min_height: Option<LayoutLength>§max_width: Option<LayoutLength>§max_height: Option<LayoutLength>§aspect_ratio: Option<f32>§margin: Sides§flex_grow: f32§flex_shrink: f32§flex_basis: Option<LayoutLength>§align_self: Option<AlignItems>§justify_self: Option<AlignItems>§grid_column: GridPlacement§grid_row: GridPlacement§position: Position§inset: [Option<LayoutLength>; 4]

Left, top, right, bottom; None is auto.

Trait Implementations§

Source§

impl Clone for NodeLayout

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for NodeLayout

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl PartialEq for NodeLayout

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for NodeLayout

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.