pub struct FontStretch(pub NonNegativePercentage);
Expand description
A value for the font-stretch property per:
https://drafts.csswg.org/css-fonts-4/#propdef-font-stretch
Tuple Fields§
§0: NonNegativePercentage
Implementations§
Trait Implementations§
source§impl Clone for FontStretch
impl Clone for FontStretch
source§fn clone(&self) -> FontStretch
fn clone(&self) -> FontStretch
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl ComputeSquaredDistance for FontStretch
impl ComputeSquaredDistance for FontStretch
source§fn compute_squared_distance(&self, other: &Self) -> Result<SquaredDistance, ()>
fn compute_squared_distance(&self, other: &Self) -> Result<SquaredDistance, ()>
Computes the squared distance between two animatable values.
source§impl Debug for FontStretch
impl Debug for FontStretch
source§impl<'de> Deserialize<'de> for FontStretch
impl<'de> Deserialize<'de> for FontStretch
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Hash for FontStretch
impl Hash for FontStretch
source§impl MallocSizeOf for FontStretch
impl MallocSizeOf for FontStretch
source§fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
Measure the heap usage of all descendant heap-allocated structures, but
not the space taken up by the value itself.
source§impl PartialEq<FontStretch> for FontStretch
impl PartialEq<FontStretch> for FontStretch
source§fn eq(&self, other: &FontStretch) -> bool
fn eq(&self, other: &FontStretch) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for FontStretch
impl Serialize for FontStretch
source§impl ToAnimatedValue for FontStretch
impl ToAnimatedValue for FontStretch
§type AnimatedValue = Percentage
type AnimatedValue = Percentage
The type of the animated value.
source§fn to_animated_value(self) -> Self::AnimatedValue
fn to_animated_value(self) -> Self::AnimatedValue
Converts this value to an animated value.
source§fn from_animated_value(animated: Self::AnimatedValue) -> Self
fn from_animated_value(animated: Self::AnimatedValue) -> Self
Converts back an animated value into a computed value.
source§impl ToCss for FontStretch
impl ToCss for FontStretch
source§impl ToResolvedValue for FontStretchwhere
NonNegativePercentage: ToResolvedValue<ResolvedValue = NonNegativePercentage>,
impl ToResolvedValue for FontStretchwhere
NonNegativePercentage: ToResolvedValue<ResolvedValue = NonNegativePercentage>,
§type ResolvedValue = FontStretch
type ResolvedValue = FontStretch
The resolved value type we’re going to be converted to.
source§fn from_resolved_value(from: Self::ResolvedValue) -> Self
fn from_resolved_value(from: Self::ResolvedValue) -> Self
Convert a resolved value to resolved value form.
source§fn to_resolved_value(self, context: &Context<'_>) -> Self::ResolvedValue
fn to_resolved_value(self, context: &Context<'_>) -> Self::ResolvedValue
Convert a resolved value to a resolved value.
impl Copy for FontStretch
impl StructuralPartialEq for FontStretch
Auto Trait Implementations§
impl RefUnwindSafe for FontStretch
impl Send for FontStretch
impl Sync for FontStretch
impl Unpin for FontStretch
impl UnwindSafe for FontStretch
Blanket Implementations§
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> MaybeBoxed<Box<T, Global>> for T
impl<T> MaybeBoxed<Box<T, Global>> for T
source§fn maybe_boxed(self) -> Box<T, Global>
fn maybe_boxed(self) -> Box<T, Global>
Convert
source§impl<T> MaybeBoxed<T> for T
impl<T> MaybeBoxed<T> for T
source§fn maybe_boxed(self) -> T
fn maybe_boxed(self) -> T
Convert