pub struct FontSize {
pub size: NonNegativeLength,
pub keyword_info: KeywordInfo,
}
Expand description
The computed value of font-size
Fields§
§size: NonNegativeLength
The size.
keyword_info: KeywordInfo
If derived from a keyword, the keyword and additional transformations applied to it
Implementations§
Trait Implementations§
source§impl ComputeSquaredDistance for FontSize
impl ComputeSquaredDistance for FontSize
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<'de> Deserialize<'de> for FontSize
impl<'de> Deserialize<'de> for FontSize
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 MallocSizeOf for FontSize
impl MallocSizeOf for FontSize
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<FontSize> for FontSize
impl PartialEq<FontSize> for FontSize
source§impl ToAnimatedValue for FontSize
impl ToAnimatedValue for FontSize
§type AnimatedValue = CSSPixelLength
type AnimatedValue = CSSPixelLength
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 ToAnimatedZero for FontSize
impl ToAnimatedZero for FontSize
source§fn to_animated_zero(&self) -> Result<Self, ()>
fn to_animated_zero(&self) -> Result<Self, ()>
Returns a value that, when added with an underlying value, will produce the underlying
value. This is used for SMIL animation’s “by-animation” where SMIL first interpolates from
the zero value to the ‘by’ value, and then adds the result to the underlying value. Read more
source§impl ToResolvedValue for FontSizewhere
NonNegativeLength: ToResolvedValue<ResolvedValue = NonNegativeLength>,
KeywordInfo: ToResolvedValue<ResolvedValue = KeywordInfo>,
impl ToResolvedValue for FontSizewhere
NonNegativeLength: ToResolvedValue<ResolvedValue = NonNegativeLength>,
KeywordInfo: ToResolvedValue<ResolvedValue = KeywordInfo>,
§type ResolvedValue = FontSize
type ResolvedValue = FontSize
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 FontSize
impl StructuralPartialEq for FontSize
Auto Trait Implementations§
impl RefUnwindSafe for FontSize
impl Send for FontSize
impl Sync for FontSize
impl Unpin for FontSize
impl UnwindSafe for FontSize
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