Struct zng_ext_font::FontWeight
source · pub struct FontWeight(pub f32);
Expand description
The degree of stroke thickness of a font. This value ranges from 100.0 to 900.0, with 400.0 as normal.
Tuple Fields§
§0: f32
Implementations§
source§impl FontWeight
impl FontWeight
sourcepub const THIN: FontWeight = _
pub const THIN: FontWeight = _
Thin weight (100), the thinnest value.
sourcepub const EXTRA_LIGHT: FontWeight = _
pub const EXTRA_LIGHT: FontWeight = _
Extra light weight (200).
sourcepub const LIGHT: FontWeight = _
pub const LIGHT: FontWeight = _
Light weight (300).
sourcepub const NORMAL: FontWeight = _
pub const NORMAL: FontWeight = _
Normal (400).
sourcepub const MEDIUM: FontWeight = _
pub const MEDIUM: FontWeight = _
Medium weight (500, higher than normal).
sourcepub const SEMIBOLD: FontWeight = _
pub const SEMIBOLD: FontWeight = _
Semi-bold weight (600).
sourcepub const BOLD: FontWeight = _
pub const BOLD: FontWeight = _
Bold weight (700).
sourcepub const EXTRA_BOLD: FontWeight = _
pub const EXTRA_BOLD: FontWeight = _
Extra-bold weight (800).
sourcepub const BLACK: FontWeight = _
pub const BLACK: FontWeight = _
Black weight (900), the thickest value.
Trait Implementations§
source§impl Clone for FontWeight
impl Clone for FontWeight
source§fn clone(&self) -> FontWeight
fn clone(&self) -> FontWeight
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 Debug for FontWeight
impl Debug for FontWeight
source§impl Default for FontWeight
impl Default for FontWeight
source§fn default() -> FontWeight
fn default() -> FontWeight
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for FontWeight
impl<'de> Deserialize<'de> for FontWeight
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 From<FontWeight> for Weight
impl From<FontWeight> for Weight
source§fn from(value: FontWeight) -> Self
fn from(value: FontWeight) -> Self
Converts to this type from the input type.
source§impl From<FontWeight> for Weight
impl From<FontWeight> for Weight
source§fn from(value: FontWeight) -> Self
fn from(value: FontWeight) -> Self
Converts to this type from the input type.
source§impl From<Weight> for FontWeight
impl From<Weight> for FontWeight
source§impl From<f32> for FontWeight
impl From<f32> for FontWeight
source§impl From<u32> for FontWeight
impl From<u32> for FontWeight
source§impl Hash for FontWeight
impl Hash for FontWeight
source§impl IntoVar<FontWeight> for f32
impl IntoVar<FontWeight> for f32
source§impl IntoVar<FontWeight> for u32
impl IntoVar<FontWeight> for u32
source§impl PartialEq for FontWeight
impl PartialEq for FontWeight
source§impl PartialOrd for FontWeight
impl PartialOrd for FontWeight
source§impl Serialize for FontWeight
impl Serialize for FontWeight
source§impl Transitionable for FontWeight
impl Transitionable for FontWeight
source§fn lerp(self, to: &Self, step: EasingStep) -> Self
fn lerp(self, to: &Self, step: EasingStep) -> Self
Sample the linear interpolation from
self
-> to
by step
.impl Copy for FontWeight
impl IntoValue<FontWeight> for f32
impl IntoValue<FontWeight> for u32
Auto Trait Implementations§
impl Freeze for FontWeight
impl RefUnwindSafe for FontWeight
impl Send for FontWeight
impl Sync for FontWeight
impl Unpin for FontWeight
impl UnwindSafe for FontWeight
Blanket Implementations§
§impl<T> AnyEq for T
impl<T> AnyEq for T
source§impl<T> AnyVarValue for Twhere
T: VarValue,
impl<T> AnyVarValue for Twhere
T: VarValue,
source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Access to mut
dyn Any
methods.source§fn clone_boxed(&self) -> Box<dyn AnyVarValue>
fn clone_boxed(&self) -> Box<dyn AnyVarValue>
Clone the value.
source§fn clone_boxed_var(&self) -> Box<dyn AnyVar>
fn clone_boxed_var(&self) -> Box<dyn AnyVar>
Clone the value into a new boxed
LocalVar<Self>
.source§fn eq_any(&self, other: &(dyn AnyVarValue + 'static)) -> bool
fn eq_any(&self, other: &(dyn AnyVarValue + 'static)) -> bool
Gets if
self
equals other
.source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> FsChangeNote for T
impl<T> FsChangeNote for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more