Type Alias Cmap2

Source
pub type Cmap2<'a> = TableRef<'a, Cmap2Marker>;
Expand description

cmap Format 2: High-byte mapping through table

Aliased Type§

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

Fields§

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

Implementations§

Source§

impl<'a> Cmap2<'a>

Source

pub fn format(&self) -> u16

Format number is set to 2.

Source

pub fn length(&self) -> u16

This is the length in bytes of the subtable.

Source

pub fn language(&self) -> u16

For requirements on use of the language field, see “Use of the language field in ‘cmap’ subtables” in this document.

Source

pub fn sub_header_keys(&self) -> &'a [BigEndian<u16>]

Array that maps high bytes to subHeaders: value is subHeader index × 8.

Trait Implementations§

Source§

impl<'a> Debug for Cmap2<'a>

Source§

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

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

impl<'a> FontRead<'a> for Cmap2<'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 Cmap2<'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.