pub struct Transition {
pub duration: f32,
pub easing: Easing,
}
Expand description
A transition.
Fields§
§duration: f32
The duration of the transition.
easing: Easing
The easing curve.
Implementations§
Source§impl Transition
impl Transition
Sourcepub fn linear(duration: f32) -> Transition
pub fn linear(duration: f32) -> Transition
Create a linear transition with the given duration
.
Sourcepub fn ease(duration: f32) -> Transition
pub fn ease(duration: f32) -> Transition
Create an ease transition with the given duration
.
Trait Implementations§
Source§impl Clone for Transition
impl Clone for Transition
Source§fn clone(&self) -> Transition
fn clone(&self) -> Transition
Returns a copy 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 Transition
impl Debug for Transition
Source§impl Default for Transition
impl Default for Transition
Source§fn default() -> Transition
fn default() -> Transition
Returns the “default value” for a type. Read more
Source§impl PartialEq for Transition
impl PartialEq for Transition
impl Copy for Transition
impl StructuralPartialEq for Transition
Auto Trait Implementations§
impl Freeze for Transition
impl RefUnwindSafe for Transition
impl Send for Transition
impl Sync for Transition
impl Unpin for Transition
impl UnwindSafe for Transition
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