#[non_exhaustive]pub enum ContentGravity {
TopLeft,
Top,
TopRight,
Left,
Center,
Right,
BottomLeft,
Bottom,
BottomRight,
ResizeFill,
ResizeAspect,
}
Expand description
Controls the alignment of the Content
inside a Actor
.
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.
TopLeft
Align the content to the top left corner
Top
Align the content to the top edge
TopRight
Align the content to the top right corner
Left
Align the content to the left edge
Center
Align the content to the center
Right
Align the content to the right edge
BottomLeft
Align the content to the bottom left corner
Bottom
Align the content to the bottom edge
BottomRight
Align the content to the bottom right corner
ResizeFill
Resize the content to fill the allocation
ResizeAspect
Resize the content to remain within the allocation, while maintaining the aspect ratio
Trait Implementations§
Source§impl Clone for ContentGravity
impl Clone for ContentGravity
Source§fn clone(&self) -> ContentGravity
fn clone(&self) -> ContentGravity
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 ContentGravity
impl Debug for ContentGravity
Source§impl Display for ContentGravity
impl Display for ContentGravity
Source§impl<'a> FromValue<'a> for ContentGravity
impl<'a> FromValue<'a> for ContentGravity
Source§unsafe fn from_value(value: &Value) -> Self
unsafe fn from_value(value: &Value) -> Self
Safety Read more
Source§impl<'a> FromValueOptional<'a> for ContentGravity
impl<'a> FromValueOptional<'a> for ContentGravity
Source§impl Hash for ContentGravity
impl Hash for ContentGravity
Source§impl Ord for ContentGravity
impl Ord for ContentGravity
Source§fn cmp(&self, other: &ContentGravity) -> Ordering
fn cmp(&self, other: &ContentGravity) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for ContentGravity
impl PartialEq for ContentGravity
Source§impl PartialOrd for ContentGravity
impl PartialOrd for ContentGravity
Source§impl SetValue for ContentGravity
impl SetValue for ContentGravity
Source§impl StaticType for ContentGravity
impl StaticType for ContentGravity
Source§fn static_type() -> Type
fn static_type() -> Type
Returns the type identifier of
Self
.impl Copy for ContentGravity
impl Eq for ContentGravity
impl StructuralPartialEq for ContentGravity
Auto Trait Implementations§
impl Freeze for ContentGravity
impl RefUnwindSafe for ContentGravity
impl Send for ContentGravity
impl Sync for ContentGravity
impl Unpin for ContentGravity
impl UnwindSafe for ContentGravity
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<T> ToSendValue for T
impl<T> ToSendValue for T
Source§fn to_send_value(&self) -> SendValue
fn to_send_value(&self) -> SendValue
Returns a
SendValue
clone of self
.