pub enum FitMode {
Contain,
Cover,
Stretch,
None,
}Expand description
How a raster image asset scales to fill its declared box.
Contain— scale to fit entirely inside the box (letterboxed).Cover— scale to cover the whole box (cropped, clipped to the box).Stretch— scale each axis independently to exactly fill the box.None— draw at native pixel size, anchored by object-position.
Variants§
Trait Implementations§
impl Copy for FitMode
impl StructuralPartialEq for FitMode
Auto Trait Implementations§
impl Freeze for FitMode
impl RefUnwindSafe for FitMode
impl Send for FitMode
impl Sync for FitMode
impl Unpin for FitMode
impl UnsafeUnpin for FitMode
impl UnwindSafe for FitMode
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