TextShaperOptions
struct · ferroui-base · v0.5.0
struct TextShaperOptions
Options to customize text shaping.
Members
newwith_allglyph_typefacefont_rendering_em_sizebidi_levelcultureincremental_tab_widthletter_spacingfont_featuresproduce_concat_flagswith_concat_flags
new
fn new(typeface: Rc<GlyphTypeface>) -> Self
Creates options with the default em size, bidi level 0 and no culture, tab width, letter spacing or features.
with_all
fn with_all(typeface: Rc<GlyphTypeface>, font_rendering_em_size: f64, bidi_level: i8, culture: Option<Locale>, incremental_tab_width: f64, letter_spacing: f64, font_features: Option<Rc<Vec<FontFeature>>>) -> Self
Creates options with every value specified.
glyph_typeface
fn glyph_typeface(self: &Self) -> &Rc<GlyphTypeface>
Get the typeface.
font_rendering_em_size
fn font_rendering_em_size(self: &Self) -> f64
Get the font rendering em size.
bidi_level
fn bidi_level(self: &Self) -> i8
Get the bidi level of the text.
culture
fn culture(self: &Self) -> Option<&Locale>
Get the culture.
incremental_tab_width
fn incremental_tab_width(self: &Self) -> f64
Get the incremental tab width.
letter_spacing
fn letter_spacing(self: &Self) -> f64
Get the letter spacing.
font_features
fn font_features(self: &Self) -> Option<&Rc<Vec<FontFeature>>>
Get features.
produce_concat_flags
fn produce_concat_flags(self: &Self) -> bool
Whether the shaper records the concatenation flags of the glyphs it makes.
with_concat_flags
fn with_concat_flags(self: Self, produce: bool) -> Self
These options, with the shaper recording the concatenation flags of the glyphs it makes or not.
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeClassDefaultsBorrow<T>BorrowMut<T>CloneToUninitInto<U>From<T>TryInto<U>TryFrom<U>AnyToOwnedErasedDestructorIntoEitherClone
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.