read_fonts::tables::hvar

Type Alias Hvar

Source
pub type Hvar<'a> = TableRef<'a, HvarMarker>;
Expand description

Aliased Type§

struct Hvar<'a> { /* private fields */ }

Implementations§

Source§

impl<'a> Hvar<'a>

Source

pub fn version(&self) -> MajorMinor

Major version number of the horizontal metrics variations table — set to 1. Minor version number of the horizontal metrics variations table — set to 0.

Source

pub fn item_variation_store_offset(&self) -> Offset32

Offset in bytes from the start of this table to the item variation store table.

Source

pub fn item_variation_store(&self) -> Result<ItemVariationStore<'a>, ReadError>

Attempt to resolve item_variation_store_offset.

Source

pub fn advance_width_mapping_offset(&self) -> Nullable<Offset32>

Offset in bytes from the start of this table to the delta-set index mapping for advance widths (may be NULL).

Source

pub fn advance_width_mapping( &self, ) -> Option<Result<DeltaSetIndexMap<'a>, ReadError>>

Attempt to resolve advance_width_mapping_offset.

Source

pub fn lsb_mapping_offset(&self) -> Nullable<Offset32>

Offset in bytes from the start of this table to the delta-set index mapping for left side bearings (may be NULL).

Source

pub fn lsb_mapping(&self) -> Option<Result<DeltaSetIndexMap<'a>, ReadError>>

Attempt to resolve lsb_mapping_offset.

Source

pub fn rsb_mapping_offset(&self) -> Nullable<Offset32>

Offset in bytes from the start of this table to the delta-set index mapping for right side bearings (may be NULL).

Source

pub fn rsb_mapping(&self) -> Option<Result<DeltaSetIndexMap<'a>, ReadError>>

Attempt to resolve rsb_mapping_offset.

Source§

impl<'a> Hvar<'a>

Source

pub fn advance_width_delta( &self, glyph_id: GlyphId, coords: &[F2Dot14], ) -> Result<Fixed, ReadError>

Returns the advance width delta for the specified glyph identifier and normalized variation coordinates.

Source

pub fn lsb_delta( &self, glyph_id: GlyphId, coords: &[F2Dot14], ) -> Result<Fixed, ReadError>

Returns the left side bearing delta for the specified glyph identifier and normalized variation coordinates.

Source

pub fn rsb_delta( &self, glyph_id: GlyphId, coords: &[F2Dot14], ) -> Result<Fixed, ReadError>

Returns the left side bearing delta for the specified glyph identifier and normalized variation coordinates.

Trait Implementations§

Source§

impl<'a> FontRead<'a> for Hvar<'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 TopLevelTable for Hvar<'_>

Source§

const TAG: Tag = _

HVAR