pub enum ImageFit {
FillVertical,
FillHorizontal,
Fill,
Fit,
Stretch,
}Expand description
Image fit/layout options
Variants§
FillVertical
Scale the image to perfectly fit within it’s bounds vertically
FillHorizontal
Scale the image to perfectly fit within it’s bounds horizontally
Fill
Scale the image to perfectly fit within it’s bounds, choosing vertical or horizontal based on which of them makes it fill the container, possibly clipping parts of the image
Fit
Scale the image to perfectly fit within it’s bounds, without clipping the image, possibly leaving some of the available container area embty.
Stretch
Stretch the image to fit the container
Trait Implementations§
source§impl CoercionRules for ImageFit
impl CoercionRules for ImageFit
source§impl<'de> Deserialize<'de> for ImageFit
impl<'de> Deserialize<'de> for ImageFit
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl HelperFunctions for ImageFit
impl HelperFunctions for ImageFit
source§impl Interpolatable for ImageFit
impl Interpolatable for ImageFit
fn interpolate(&self, _other: &Self, _t: f64) -> Self
source§impl ToPaxValue for ImageFit
impl ToPaxValue for ImageFit
fn to_pax_value(self) -> PaxValue
impl ImplToFromPaxAny for ImageFit
Auto Trait Implementations§
impl Freeze for ImageFit
impl RefUnwindSafe for ImageFit
impl Send for ImageFit
impl Sync for ImageFit
impl Unpin for ImageFit
impl UnwindSafe for ImageFit
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)source§impl<T, U> RoundInto<U> for Twhere
U: RoundFrom<T>,
impl<T, U> RoundInto<U> for Twhere
U: RoundFrom<T>,
source§fn round_into(self) -> U
fn round_into(self) -> U
Performs the conversion.