Type Alias style::values::specified::NonNegativeNumberOrPercentage

source ·
pub type NonNegativeNumberOrPercentage = NonNegative<NumberOrPercentage>;
Expand description

A non-negative | .

Aliased Type§

struct NonNegativeNumberOrPercentage(pub NumberOrPercentage);

Fields§

§0: NumberOrPercentage

Implementations§

source§

impl NonNegativeNumberOrPercentage

source

pub fn hundred_percent() -> Self

Returns the 100% value.

source

pub fn new_number(n: f32) -> Self

Return a particular number.

Trait Implementations§

source§

impl Parse for NonNegativeNumberOrPercentage

source§

fn parse<'i, 't>( context: &ParserContext<'_>, input: &mut Parser<'i, 't>, ) -> Result<Self, ParseError<'i>>

Parse a value of this type. Read more