pub struct ExtensionPosFormat1<'a, T = ()> {
data: FontData<'a>,
offset_type: PhantomData<*const T>,
}Expand description
Fields§
§data: FontData<'a>§offset_type: PhantomData<*const T>Implementations§
Source§impl<'a> ExtensionPosFormat1<'a, ()>
impl<'a> ExtensionPosFormat1<'a, ()>
pub(crate) fn into_concrete<T>(self) -> ExtensionPosFormat1<'a, T>
Source§impl<'a, T> ExtensionPosFormat1<'a, T>
impl<'a, T> ExtensionPosFormat1<'a, T>
Sourcepub(crate) fn of_unit_type(&self) -> ExtensionPosFormat1<'a, ()>
pub(crate) fn of_unit_type(&self) -> ExtensionPosFormat1<'a, ()>
Replace the specific generic type on this implementation with ()
Source§impl<'a, T> ExtensionPosFormat1<'a, T>
impl<'a, T> ExtensionPosFormat1<'a, T>
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 pos_format(&self) -> u16
pub fn pos_format(&self) -> u16
Format identifier: format = 1
Sourcepub fn extension_lookup_type(&self) -> u16
pub fn extension_lookup_type(&self) -> u16
Lookup type of subtable referenced by extensionOffset (i.e. the extension subtable).
Sourcepub fn extension_offset(&self) -> Offset32
pub fn extension_offset(&self) -> Offset32
Offset to the extension subtable, of lookup type extensionLookupType, relative to the start of the ExtensionPosFormat1 subtable.
Sourcepub fn extension(&self) -> Result<T, ReadError>where
T: FontRead<'a>,
pub fn extension(&self) -> Result<T, ReadError>where
T: FontRead<'a>,
Attempt to resolve extension_offset.
pub fn pos_format_byte_range(&self) -> Range<usize> ⓘ
pub fn extension_lookup_type_byte_range(&self) -> Range<usize> ⓘ
pub fn extension_offset_byte_range(&self) -> Range<usize> ⓘ
Trait Implementations§
Source§impl<'a, T: Clone> Clone for ExtensionPosFormat1<'a, T>
impl<'a, T: Clone> Clone for ExtensionPosFormat1<'a, T>
Source§fn clone(&self) -> ExtensionPosFormat1<'a, T>
fn clone(&self) -> ExtensionPosFormat1<'a, T>
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<'a, T: FontRead<'a>> ExtensionLookup<'a, T> for ExtensionPosFormat1<'a, T>
impl<'a, T: FontRead<'a>> ExtensionLookup<'a, T> for ExtensionPosFormat1<'a, T>
Source§impl<'a, T> FontRead<'a> for ExtensionPosFormat1<'a, T>
impl<'a, T> FontRead<'a> for ExtensionPosFormat1<'a, T>
Source§impl Format<u16> for ExtensionPosFormat1<'_>
impl Format<u16> for ExtensionPosFormat1<'_>
Source§impl<'a, T> MinByteRange<'a> for ExtensionPosFormat1<'a, T>
impl<'a, T> MinByteRange<'a> for ExtensionPosFormat1<'a, T>
Auto Trait Implementations§
impl<'a, T> Freeze for ExtensionPosFormat1<'a, T>
impl<'a, T> RefUnwindSafe for ExtensionPosFormat1<'a, T>where
T: RefUnwindSafe,
impl<'a, T = ()> !Send for ExtensionPosFormat1<'a, T>
impl<'a, T = ()> !Sync for ExtensionPosFormat1<'a, T>
impl<'a, T> Unpin for ExtensionPosFormat1<'a, T>
impl<'a, T> UnsafeUnpin for ExtensionPosFormat1<'a, T>
impl<'a, T> UnwindSafe for ExtensionPosFormat1<'a, T>where
T: RefUnwindSafe,
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