pub struct AlignItems {
pub keyword: AlignItemsKeyword,
pub safety: AlignmentSafety,
}Expand description
Used to control how child nodes are aligned. For Flexbox it controls alignment in the cross axis. For Grid it controls alignment in the block axis.
Fields§
§keyword: AlignItemsKeywordPosition keyword.
safety: AlignmentSafetyOverflow-position modifier (safe / unsafe).
Implementations§
Source§impl AlignItems
impl AlignItems
Sourcepub const FLEX_START: Self
pub const FLEX_START: Self
Items are packed towards the flex-relative start of the axis.
Sourcepub const SAFE_START: Self
pub const SAFE_START: Self
Like AlignItems::START, but falls back to AlignItems::START when the
alignment subject overflows the alignment container, to avoid data loss.
Sourcepub const SAFE_END: Self
pub const SAFE_END: Self
Like AlignItems::END, but falls back to AlignItems::START when the
alignment subject overflows the alignment container, to avoid data loss.
Sourcepub const SAFE_FLEX_START: Self
pub const SAFE_FLEX_START: Self
Like AlignItems::FLEX_START, but falls back to AlignItems::START when the
alignment subject overflows the alignment container, to avoid data loss.
Sourcepub const SAFE_FLEX_END: Self
pub const SAFE_FLEX_END: Self
Like AlignItems::FLEX_END, but falls back to AlignItems::START when the
alignment subject overflows the alignment container, to avoid data loss.
Sourcepub const SAFE_CENTER: Self
pub const SAFE_CENTER: Self
Like AlignItems::CENTER, but falls back to AlignItems::START when the
alignment subject overflows the alignment container, to avoid data loss.
Sourcepub const fn is_safe(self) -> bool
pub const fn is_safe(self) -> bool
Returns true iff this carries the safe overflow-position modifier.
Sourcepub const fn keyword(self) -> AlignItemsKeyword
pub const fn keyword(self) -> AlignItemsKeyword
Returns the underlying position keyword, discarding the safety modifier.
Trait Implementations§
Source§impl Clone for AlignItems
impl Clone for AlignItems
Source§fn clone(&self) -> AlignItems
fn clone(&self) -> AlignItems
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more