pub struct Weight(/* private fields */);Expand description
Wrapper type of a font weight.
Use Weight::from() to create a weight from an i32. Use *weight to pull out the wrapped value of the Weight.
Implementations§
Source§impl Weight
impl Weight
pub const INVISIBLE: Weight
pub const THIN: Weight
pub const EXTRA_LIGHT: Weight
pub const LIGHT: Weight
pub const NORMAL: Weight
pub const MEDIUM: Weight
pub const SEMI_BOLD: Weight
pub const BOLD: Weight
pub const EXTRA_BOLD: Weight
pub const BLACK: Weight
pub const EXTRA_BLACK: Weight
Trait Implementations§
impl Copy for Weight
impl Eq for Weight
Source§impl Ord for Weight
impl Ord for Weight
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for Weight
impl PartialOrd for Weight
impl StructuralPartialEq for Weight
Auto Trait Implementations§
impl Freeze for Weight
impl RefUnwindSafe for Weight
impl Send for Weight
impl Sync for Weight
impl Unpin for Weight
impl UnsafeUnpin for Weight
impl UnwindSafe for Weight
Blanket Implementations§
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