Type Alias TimingFunction

Source
pub type TimingFunction = ComputedTimingFunction;
Expand description

An alias of the computed timing function.

Aliased Type§

#[repr(C, u8)]
pub enum TimingFunction { Keyword(TimingKeyword), CubicBezier { x1: f32, y1: f32, x2: f32, y2: f32, }, Steps(i32, StepPosition), LinearFunction(PiecewiseLinearFunction), }

Variants§

§

Keyword(TimingKeyword)

linear | ease | ease-in | ease-out | ease-in-out

§

CubicBezier

cubic-bezier(<number>, <number>, <number>, <number>)

Fields

§x1: f32
§y1: f32
§x2: f32
§y2: f32
§

Steps(i32, StepPosition)

step-start | step-end | steps(<integer>, [ <step-position> ]?) <step-position> = jump-start | jump-end | jump-none | jump-both | start | end

§

LinearFunction(PiecewiseLinearFunction)

linear([]#) = && ? = {1, 2}

Trait Implementations§

Source§

impl ToResolvedValue for TimingFunction

Source§

type ResolvedValue = TimingFunction<i32, f32, PiecewiseLinearFunction>

The resolved value type we’re going to be converted to.
Source§

fn to_resolved_value(self, _: &Context<'_>) -> Self

Convert a resolved value to a resolved value.
Source§

fn from_resolved_value(resolved: Self::ResolvedValue) -> Self

Convert a resolved value to resolved value form.