#[non_exhaustive]#[repr(u32)]pub enum TextHorizontalAlignment {
Left = 0,
Center = 1,
Right = 2,
}Expand description
This enum describes the different types of alignment of text along the horizontal axis of a Text element.
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.
Left = 0
The text will be aligned with the left edge of the containing box.
Center = 1
The text will be horizontally centered within the containing box.
Right = 2
The text will be aligned to the right of the containing box.
Trait Implementations§
Source§impl Clone for TextHorizontalAlignment
impl Clone for TextHorizontalAlignment
Source§fn clone(&self) -> TextHorizontalAlignment
fn clone(&self) -> TextHorizontalAlignment
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 moreSource§impl Debug for TextHorizontalAlignment
impl Debug for TextHorizontalAlignment
Source§impl Default for TextHorizontalAlignment
impl Default for TextHorizontalAlignment
Source§impl Display for TextHorizontalAlignment
impl Display for TextHorizontalAlignment
Source§impl FromStr for TextHorizontalAlignment
impl FromStr for TextHorizontalAlignment
Source§impl Hash for TextHorizontalAlignment
impl Hash for TextHorizontalAlignment
Source§impl PartialEq for TextHorizontalAlignment
impl PartialEq for TextHorizontalAlignment
Source§impl TryFrom<&str> for TextHorizontalAlignment
impl TryFrom<&str> for TextHorizontalAlignment
impl Copy for TextHorizontalAlignment
impl Eq for TextHorizontalAlignment
impl StructuralPartialEq for TextHorizontalAlignment
Auto Trait Implementations§
impl Freeze for TextHorizontalAlignment
impl RefUnwindSafe for TextHorizontalAlignment
impl Send for TextHorizontalAlignment
impl Sync for TextHorizontalAlignment
impl Unpin for TextHorizontalAlignment
impl UnwindSafe for TextHorizontalAlignment
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Converts the given value to a
SharedString.