#[non_exhaustive]#[repr(u32)]pub enum CrossAxisAlignment {
Auto = 0,
Stretch = 1,
Start = 2,
End = 3,
Center = 4,
}Expand description
Controls the alignment of items along the cross axis of a layout.
Used as the cross-axis-alignment property of HorizontalLayout, VerticalLayout,
and FlexboxLayout, and as the cross-axis-self-alignment property of their
children, which overrides the container’s alignment for a single item.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Auto = 0
The default: for cross-axis-self-alignment, use the container’s
cross-axis-alignment value. For an unset cross-axis-alignment it is
equivalent to stretch; it is an error to set it explicitly there.
Stretch = 1
Items are stretched to fill the cross axis.
Start = 2
Items are placed at the start of the cross axis.
End = 3
Items are placed at the end of the cross axis.
Center = 4
Items are centered along the cross axis.
Trait Implementations§
Source§impl Clone for CrossAxisAlignment
impl Clone for CrossAxisAlignment
impl Copy for CrossAxisAlignment
Source§impl Debug for CrossAxisAlignment
impl Debug for CrossAxisAlignment
Source§impl Default for CrossAxisAlignment
impl Default for CrossAxisAlignment
Source§impl Display for CrossAxisAlignment
impl Display for CrossAxisAlignment
impl Eq for CrossAxisAlignment
Source§impl FromStr for CrossAxisAlignment
impl FromStr for CrossAxisAlignment
Source§impl Hash for CrossAxisAlignment
impl Hash for CrossAxisAlignment
Source§impl PartialEq for CrossAxisAlignment
impl PartialEq for CrossAxisAlignment
impl StructuralPartialEq for CrossAxisAlignment
Auto Trait Implementations§
impl Freeze for CrossAxisAlignment
impl RefUnwindSafe for CrossAxisAlignment
impl Send for CrossAxisAlignment
impl Sync for CrossAxisAlignment
impl Unpin for CrossAxisAlignment
impl UnsafeUnpin for CrossAxisAlignment
impl UnwindSafe for CrossAxisAlignment
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
impl<T> Brush for T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
impl<T> ErasedDestructor for Twhere
T: 'static,
Converts the given value to a
SharedString.