pub struct AlignmentTween {
pub begin: Option<Alignment>,
pub end: Option<Alignment>,
}Expand description
An interpolation between two alignments.
This class specializes the interpolation of Tween<Alignment> to be
appropriate for alignments.
See Tween for a discussion on how to use interpolation objects.
Like FractionalOffsetTween, this one is a value rather than an arena object (see
PORTING.md).
See also:
AlignmentGeometryTween, which interpolates between twoAlignmentGeometryobjects.
Fields§
§begin: Option<Alignment>The value this variable has at the beginning of the animation.
end: Option<Alignment>The value this variable has at the end of the animation.
Implementations§
Source§impl AlignmentTween
impl AlignmentTween
Trait Implementations§
Source§impl Animatable<Alignment> for AlignmentTween
impl Animatable<Alignment> for AlignmentTween
Source§fn transform(&self, _app: &App, t: f64) -> Alignment
fn transform(&self, _app: &App, t: f64) -> Alignment
Returns the value of the object at point
t. Read moreSource§fn evaluate(&self, app: &App, animation: AnyAnimation<f64>) -> Twhere
Self: Sized,
fn evaluate(&self, app: &App, animation: AnyAnimation<f64>) -> Twhere
Self: Sized,
The current value of this object for the given animation. Read more
Source§fn animate(self, app: &mut App, parent: AnyAnimation<f64>) -> AnyAnimation<T>
fn animate(self, app: &mut App, parent: AnyAnimation<f64>) -> AnyAnimation<T>
Returns a new
AnyAnimation that is driven by the given animation but
that takes on values determined by this object.Source§fn chain<P>(self, parent: P) -> ChainedEvaluation<P, Self>
fn chain<P>(self, parent: P) -> ChainedEvaluation<P, Self>
Returns a new
Animatable whose value is determined by first
evaluating the given parent and then evaluating this object at the
result.Source§impl Clone for AlignmentTween
impl Clone for AlignmentTween
Auto Trait Implementations§
impl Freeze for AlignmentTween
impl RefUnwindSafe for AlignmentTween
impl Send for AlignmentTween
impl Sync for AlignmentTween
impl Unpin for AlignmentTween
impl UnsafeUnpin for AlignmentTween
impl UnwindSafe for AlignmentTween
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