pub struct FallbackFontQuery {
pub post_script_name: Option<String>,
pub font_name: Option<String>,
pub font_family: Option<String>,
pub font_stretch: FontStretch,
pub font_weight: u32,
pub is_fixed_pitch: bool,
pub is_serif: bool,
pub is_italic: bool,
pub is_bold: bool,
pub is_small_cap: bool,
}Expand description
A query for a font with specific properties.
Fields§
§post_script_name: Option<String>The postscript name of the font.
font_name: Option<String>The name of the font.
font_family: Option<String>The family of the font.
font_stretch: FontStretchThe stretch of the font.
font_weight: u32The weight of the font.
is_fixed_pitch: boolWhether the font is monospaced.
is_serif: boolWhether the font is serif.
is_italic: boolWhether the font is italic.
is_bold: boolWhether the font is bold.
is_small_cap: boolWhether the font is small cap.
Implementations§
Source§impl FallbackFontQuery
impl FallbackFontQuery
Sourcepub fn pick_standard_font(&self) -> StandardFont
pub fn pick_standard_font(&self) -> StandardFont
Do a best-effort fallback to the 14 standard fonts based on the query.
Trait Implementations§
Source§impl Clone for FallbackFontQuery
impl Clone for FallbackFontQuery
Source§fn clone(&self) -> FallbackFontQuery
fn clone(&self) -> FallbackFontQuery
Returns a duplicate 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 FallbackFontQuery
impl Debug for FallbackFontQuery
Auto Trait Implementations§
impl Freeze for FallbackFontQuery
impl RefUnwindSafe for FallbackFontQuery
impl Send for FallbackFontQuery
impl Sync for FallbackFontQuery
impl Unpin for FallbackFontQuery
impl UnwindSafe for FallbackFontQuery
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