Type Alias TrackData

Source
pub type TrackData<'a> = TableRef<'a, TrackDataMarker>;
Expand description

The tracking data table.

Aliased Type§

pub struct TrackData<'a> {
    pub(crate) shape: TrackDataMarker,
    pub(crate) data: FontData<'a>,
}

Fields§

§shape: TrackDataMarker§data: FontData<'a>

Implementations§

Source§

impl<'a> TrackData<'a>

Source

pub fn n_tracks(&self) -> u16

Number of separate tracks included in this table.

Source

pub fn n_sizes(&self) -> u16

Number of point sizes included in this table.

Source

pub fn size_table_offset(&self) -> u32

Offset from the start of the tracking table to the start of the size subtable.

Source

pub fn track_table(&self) -> &'a [TrackTableEntry]

Array of TrackTableEntry records.

Source§

impl<'a> TrackData<'a>

Source

pub fn size_table( &self, offset_data: FontData<'a>, ) -> Result<&'a [BigEndian<Fixed>], ReadError>

Returns the size table for this set of tracking data.

The offset_data parameter comes from the Trak table.

Trait Implementations§

Source§

impl<'a> Debug for TrackData<'a>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a> FontRead<'a> for TrackData<'a>

Source§

fn read(data: FontData<'a>) -> Result<Self, ReadError>

Read an instance of Self from the provided data, performing validation. Read more
Source§

impl<'a> SomeTable<'a> for TrackData<'a>

Source§

fn type_name(&self) -> &str

The name of this table
Source§

fn get_field(&self, idx: usize) -> Option<Field<'a>>

Access this table’s fields, in declaration order.