Skip to main content

Percentage

Struct Percentage 

Source
pub struct Percentage(/* private fields */);
Expand description

A percentage such as 50%, or a Token that holds one.

Trait Implementations§

Source§

impl Clone for Percentage

Source§

fn clone(&self) -> Percentage

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Percentage

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Display for Percentage

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl From<Percentage> for BackgroundPosition

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BackgroundPositionX

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BackgroundPositionY

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BackgroundSize

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BaselineShift

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BlockSize

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderBottomLeftRadius

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderBottomRightRadius

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderEndEndRadius

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderEndStartRadius

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderImageWidth

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderRadius

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderStartEndRadius

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderStartStartRadius

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderTopLeftRadius

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for BorderTopRightRadius

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Bottom

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ColumnGap

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Cx

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Cy

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for FillOpacity

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Flex

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for FlexBasis

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for FloodOpacity

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for FontSize

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Gap

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for GridAutoColumns

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for GridAutoRows

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for GridTemplateColumns

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for GridTemplateRows

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Height

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for InlineSize

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Inset

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for InsetBlock

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for InsetBlockEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for InsetBlockStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for InsetInline

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for InsetInlineEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for InsetInlineStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Left

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for LineHeight

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Margin

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginBlock

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginBlockEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginBlockStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginBottom

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginInline

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginInlineEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginInlineStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginLeft

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginRight

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MarginTop

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Mask

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MaskBorder

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MaskBorderSlice

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MaskBorderWidth

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MaskPosition

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MaskSize

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MaxBlockSize

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MaxHeight

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MaxInlineSize

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MaxWidth

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MinBlockSize

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MinHeight

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MinInlineSize

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for MinWidth

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ObjectPosition

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Offset

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for OffsetAnchor

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for OffsetDistance

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for OffsetPosition

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Opacity

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Padding

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingBlock

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingBlockEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingBlockStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingBottom

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingInline

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingInlineEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingInlineStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingLeft

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingRight

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PaddingTop

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for PerspectiveOrigin

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for R

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Right

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for RowGap

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Rx

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Ry

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Scale

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPadding

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingBlock

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingBlockEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingBlockStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingBottom

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingInline

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingInlineEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingInlineStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingLeft

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingRight

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ScrollPaddingTop

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ShapeImageThreshold

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for ShapeMargin

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for StopOpacity

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for StrokeDasharray

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for StrokeDashoffset

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for StrokeOpacity

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for StrokeWidth

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TextDecoration

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TextDecorationInset

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TextDecorationThickness

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TextUnderlineOffset

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TimelineTriggerActivationRange

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TimelineTriggerActivationRangeEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TimelineTriggerActivationRangeStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TimelineTriggerActiveRange

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TimelineTriggerActiveRangeEnd

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TimelineTriggerActiveRangeStart

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Top

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for TransformOrigin

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Translate

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for VerticalAlign

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Width

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for X

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Y

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl From<Percentage> for Zoom

Source§

fn from(v: Percentage) -> Self

Converts to this type from the input type.
Source§

impl PartialEq for Percentage

Source§

fn eq(&self, other: &Percentage) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for Percentage

Source§

impl TokenValue for Percentage

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.