pub struct Subtable3<'a> {
data: FontData<'a>,
}Expand description
The type 3 ‘kern’ subtable.
Fields§
§data: FontData<'a>Implementations§
Source§impl<'a> Subtable3<'a>
impl<'a> Subtable3<'a>
pub const MIN_SIZE: usize
Sourcepub fn resolve_offset<O: Offset, R: FontRead<'a>>(
&self,
offset: O,
) -> Result<R, ReadError>
pub fn resolve_offset<O: Offset, R: FontRead<'a>>( &self, offset: O, ) -> Result<R, ReadError>
Resolve the provided offset from the start of this table.
Sourcepub fn offset_data(&self) -> FontData<'a>
pub fn offset_data(&self) -> FontData<'a>
Return a reference to this table’s raw data.
We use this in the compile crate to resolve offsets.
Sourcepub fn shape(&self) -> &Self
👎Deprecated: just use the base type directly
pub fn shape(&self) -> &Self
Return a reference to the table’s ‘Shape’ struct.
This is a low level implementation detail, but it can be useful in some cases where you want to know things about a table’s layout, such as the byte offsets of specific fields.
Sourcepub fn glyph_count(&self) -> u16
pub fn glyph_count(&self) -> u16
The number of glyphs in this font.
Sourcepub fn kern_value_count(&self) -> u8
pub fn kern_value_count(&self) -> u8
The number of kerning values.
Sourcepub fn left_class_count(&self) -> u8
pub fn left_class_count(&self) -> u8
The number of left-hand classes.
Sourcepub fn right_class_count(&self) -> u8
pub fn right_class_count(&self) -> u8
The number of right-hand classes.
Sourcepub fn kern_value(&self) -> &'a [BigEndian<i16>]
pub fn kern_value(&self) -> &'a [BigEndian<i16>]
The kerning values.
Sourcepub fn left_class(&self) -> &'a [u8] ⓘ
pub fn left_class(&self) -> &'a [u8] ⓘ
The left-hand classes.
Sourcepub fn right_class(&self) -> &'a [u8] ⓘ
pub fn right_class(&self) -> &'a [u8] ⓘ
The right-hand classes.
Sourcepub fn kern_index(&self) -> &'a [u8] ⓘ
pub fn kern_index(&self) -> &'a [u8] ⓘ
The indices into the kernValue array.
pub fn glyph_count_byte_range(&self) -> Range<usize> ⓘ
pub fn kern_value_count_byte_range(&self) -> Range<usize> ⓘ
pub fn left_class_count_byte_range(&self) -> Range<usize> ⓘ
pub fn right_class_count_byte_range(&self) -> Range<usize> ⓘ
pub fn flags_byte_range(&self) -> Range<usize> ⓘ
pub fn kern_value_byte_range(&self) -> Range<usize> ⓘ
pub fn left_class_byte_range(&self) -> Range<usize> ⓘ
pub fn right_class_byte_range(&self) -> Range<usize> ⓘ
pub fn kern_index_byte_range(&self) -> Range<usize> ⓘ
Trait Implementations§
Source§impl<'a> MinByteRange<'a> for Subtable3<'a>
impl<'a> MinByteRange<'a> for Subtable3<'a>
Auto Trait Implementations§
impl<'a> Freeze for Subtable3<'a>
impl<'a> RefUnwindSafe for Subtable3<'a>
impl<'a> Send for Subtable3<'a>
impl<'a> Sync for Subtable3<'a>
impl<'a> Unpin for Subtable3<'a>
impl<'a> UnsafeUnpin for Subtable3<'a>
impl<'a> UnwindSafe for Subtable3<'a>
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