pub struct ShapePlan {Show 27 fields
pub(crate) direction: Direction,
pub(crate) script: Option<Script>,
pub(crate) language: Option<Language>,
pub(crate) shaper: &'static OtShaper,
pub(crate) ot_map: OtMap,
pub(crate) aat_map: AatMap,
pub(crate) data: Option<Box<dyn Any + Send + Sync>>,
pub(crate) frac_mask: u32,
pub(crate) numr_mask: u32,
pub(crate) dnom_mask: u32,
pub(crate) rtlm_mask: u32,
pub(crate) kern_mask: u32,
pub(crate) requested_kerning: bool,
pub(crate) has_frac: bool,
pub(crate) has_vert: bool,
pub(crate) has_gpos_mark: bool,
pub(crate) zero_marks: bool,
pub(crate) fallback_glyph_classes: bool,
pub(crate) fallback_mark_positioning: bool,
pub(crate) adjust_mark_positioning_when_zeroing: bool,
pub(crate) apply_gpos: bool,
pub(crate) apply_fallback_kern: bool,
pub(crate) apply_kern: bool,
pub(crate) apply_kerx: bool,
pub(crate) apply_morx: bool,
pub(crate) apply_trak: bool,
pub(crate) user_features: SmallVec<[Feature; 4]>,
}Expand description
A reusable plan for shaping with one set of segment properties.
A plan records the selected shaping features and lookups. Reuse it with a compatible font, direction, script, language, and feature set.
Fields§
§direction: Direction§script: Option<Script>§language: Option<Language>§shaper: &'static OtShaper§ot_map: OtMap§aat_map: AatMap§data: Option<Box<dyn Any + Send + Sync>>§frac_mask: u32§numr_mask: u32§dnom_mask: u32§rtlm_mask: u32§kern_mask: u32§requested_kerning: bool§has_frac: bool§has_vert: bool§has_gpos_mark: bool§zero_marks: bool§fallback_glyph_classes: bool§fallback_mark_positioning: bool§adjust_mark_positioning_when_zeroing: bool§apply_gpos: bool§apply_fallback_kern: bool§apply_kern: bool§apply_kerx: bool§apply_morx: bool§apply_trak: bool§user_features: SmallVec<[Feature; 4]>Implementations§
Source§impl ShapePlan
impl ShapePlan
Sourcepub fn new(
font: &Font,
direction: Direction,
script: Option<Script>,
language: Option<&Language>,
user_features: &[Feature],
) -> Self
pub fn new( font: &Font, direction: Direction, script: Option<Script>, language: Option<&Language>, user_features: &[Feature], ) -> Self
pub(crate) fn from_layout( layout: LayoutData<'_>, direction: Direction, script: Option<Script>, language: Option<&Language>, user_features: &[Feature], ) -> Self
pub(crate) fn data<T: 'static>(&self) -> &T
Auto Trait Implementations§
impl !RefUnwindSafe for ShapePlan
impl !UnwindSafe for ShapePlan
impl Freeze for ShapePlan
impl Send for ShapePlan
impl Sync for ShapePlan
impl Unpin for ShapePlan
impl UnsafeUnpin for ShapePlan
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