Enum css_style::transition::Transition [−][src]
pub enum Transition {
One(TransitionValue),
Multiple(IndexMap<Cow<'static, str>, TransitionValue>),
Initial,
Inherit,
None,
Unset,
}use css_style::{Style, unit::{sec, ms}}; Style::default() // transition for all properties .and_transition(|conf| conf.duration(sec(1.2)).ease()) // transitions for specific properties .and_transition(|conf| { conf.insert("opacity", |conf| conf.duration(ms(150.)).ease().delay(sec(0.5))) .insert("width", |conf| conf.duration(ms(450.)).ease_in()) });
Variants
One(TransitionValue)Multiple(IndexMap<Cow<'static, str>, TransitionValue>)Implementations
impl Transition[src]
pub fn new() -> Self[src]
pub fn duration(self, val: impl Into<Duration>) -> Self[src]
pub fn timing_function(self, val: impl Into<TimingFunction>) -> Self[src]
pub fn try_timing_function(self, val: Option<impl Into<TimingFunction>>) -> Self[src]
pub fn ease(self) -> Self[src]
pub fn linear(self) -> Self[src]
pub fn ease_in(self) -> Self[src]
pub fn ease_out(self) -> Self[src]
pub fn ease_in_out(self) -> Self[src]
pub fn step_start(self) -> Self[src]
pub fn step_end(self) -> Self[src]
pub fn steps(self, intervals: usize, pos: impl Into<StepsPos>) -> Self[src]
pub fn cubic_bezier(self, n1: f32, n2: f32, n3: f32, n4: f32) -> Self[src]
pub fn delay(self, val: impl Into<Delay>) -> Self[src]
pub fn try_delay(self, val: Option<impl Into<Delay>>) -> Self[src]
pub fn insert(
self,
property: impl Into<Cow<'static, str>>,
get_val: impl FnOnce(TransitionValue) -> TransitionValue
) -> Self[src]
self,
property: impl Into<Cow<'static, str>>,
get_val: impl FnOnce(TransitionValue) -> TransitionValue
) -> Self
pub fn foreach(
self,
properties: impl IntoIterator<Item = impl Into<Cow<'static, str>>>,
f: impl FnOnce(TransitionValue) -> TransitionValue + Clone
) -> Self[src]
self,
properties: impl IntoIterator<Item = impl Into<Cow<'static, str>>>,
f: impl FnOnce(TransitionValue) -> TransitionValue + Clone
) -> Self
Trait Implementations
impl Clone for Transition[src]
fn clone(&self) -> Transition[src]
pub fn clone_from(&mut self, source: &Self)1.0.0[src]
impl Debug for Transition[src]
impl Default for Transition[src]
impl Display for Transition[src]
impl From<IndexMap<Cow<'static, str>, TransitionValue, RandomState>> for Transition[src]
fn from(original: IndexMap<Cow<'static, str>, TransitionValue>) -> Transition[src]
impl From<TransitionValue> for Transition[src]
fn from(original: TransitionValue) -> Transition[src]
impl PartialEq<Transition> for Transition[src]
fn eq(&self, other: &Transition) -> bool[src]
fn ne(&self, other: &Transition) -> bool[src]
impl StructuralPartialEq for Transition[src]
impl StyleUpdater for Transition[src]
fn update_style(self, style: Style) -> Style[src]
Auto Trait Implementations
impl RefUnwindSafe for Transition
impl Send for Transition
impl Sync for Transition
impl Unpin for Transition
impl UnwindSafe for Transition
Blanket Implementations
impl<S, D, Swp, Dwp, T> AdaptInto<D, Swp, Dwp, T> for S where
T: Component + Float,
D: AdaptFrom<S, Swp, Dwp, T>,
Swp: WhitePoint,
Dwp: WhitePoint, [src]
T: Component + Float,
D: AdaptFrom<S, Swp, Dwp, T>,
Swp: WhitePoint,
Dwp: WhitePoint,
pub fn adapt_into_using<M>(self, method: M) -> D where
M: TransformMatrix<Swp, Dwp, T>, [src]
M: TransformMatrix<Swp, Dwp, T>,
pub fn adapt_into(self) -> D[src]
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T[src]
impl<T, U> ConvertInto<U> for T where
U: ConvertFrom<T>, [src]
U: ConvertFrom<T>,
pub fn convert_into(self) -> U[src]
pub fn convert_unclamped_into(self) -> U[src]
pub fn try_convert_into(self) -> Result<U, OutOfBounds<U>>[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T[src]
pub fn clone_into(&self, target: &mut T)[src]
impl<T> ToString for T where
T: Display + ?Sized, [src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,