read_fonts::tables::os2

Type Alias Os2

source
pub type Os2<'a> = TableRef<'a, Os2Marker>;
Expand description

Aliased Type§

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

Implementations§

source§

impl<'a> Os2<'a>

source

pub fn version(&self) -> u16

source

pub fn x_avg_char_width(&self) -> i16

Average weighted escapement.

The Average Character Width parameter specifies the arithmetic average of the escapement (width) of all non-zero width glyphs in the font.

source

pub fn us_weight_class(&self) -> u16

Weight class.

Indicates the visual weight (degree of blackness or thickness of strokes) of the characters in the font. Values from 1 to 1000 are valid.

source

pub fn us_width_class(&self) -> u16

Width class.

Indicates a relative change from the normal aspect ratio (width to height ratio) as specified by a font designer for the glyphs in a font.

source

pub fn fs_type(&self) -> u16

Type flags.

Indicates font embedding licensing rights for the font.

source

pub fn y_subscript_x_size(&self) -> i16

The recommended horizontal size in font design units for subscripts for this font.

source

pub fn y_subscript_y_size(&self) -> i16

The recommended vertical size in font design units for subscripts for this font.

source

pub fn y_subscript_x_offset(&self) -> i16

The recommended horizontal offset in font design units for subscripts for this font.

source

pub fn y_subscript_y_offset(&self) -> i16

The recommended vertical offset in font design units for subscripts for this font.

source

pub fn y_superscript_x_size(&self) -> i16

The recommended horizontal size in font design units for superscripts for this font.

source

pub fn y_superscript_y_size(&self) -> i16

The recommended vertical size in font design units for superscripts for this font.

source

pub fn y_superscript_x_offset(&self) -> i16

The recommended horizontal offset in font design units for superscripts for this font.

source

pub fn y_superscript_y_offset(&self) -> i16

The recommended vertical offset in font design units for superscripts for this font.

source

pub fn y_strikeout_size(&self) -> i16

Thickness of the strikeout stroke in font design units.

source

pub fn y_strikeout_position(&self) -> i16

The position of the top of the strikeout stroke relative to the baseline in font design units.

source

pub fn s_family_class(&self) -> i16

Font-family class and subclass. This parameter is a classification of font-family design.

source

pub fn panose_10(&self) -> &'a [u8]

PANOSE classification number.

Additional specifications are required for PANOSE to classify non-Latin character sets.

source

pub fn ul_unicode_range_1(&self) -> u32

Unicode Character Range.

Unicode Character Range (bits 0-31).

source

pub fn ul_unicode_range_2(&self) -> u32

Unicode Character Range (bits 32-63).

source

pub fn ul_unicode_range_3(&self) -> u32

Unicode Character Range (bits 64-95).

source

pub fn ul_unicode_range_4(&self) -> u32

Unicode Character Range (bits 96-127).

source

pub fn ach_vend_id(&self) -> Tag

Font Vendor Identification.

The four-character identifier for the vendor of the given type face.

source

pub fn fs_selection(&self) -> SelectionFlags

Font selection flags.

Contains information concerning the nature of the font patterns.

source

pub fn us_first_char_index(&self) -> u16

The minimum Unicode index (character code) in this font.

source

pub fn us_last_char_index(&self) -> u16

The maximum Unicode index (character code) in this font.

source

pub fn s_typo_ascender(&self) -> i16

The typographic ascender for this font.

source

pub fn s_typo_descender(&self) -> i16

The typographic descender for this font.

source

pub fn s_typo_line_gap(&self) -> i16

The typographic line gap for this font.

source

pub fn us_win_ascent(&self) -> u16

The “Windows ascender” metric.

This should be used to specify the height above the baseline for a clipping region.

source

pub fn us_win_descent(&self) -> u16

The “Windows descender” metric.

This should be used to specify the vertical extent below the baseline for a clipping region.

source

pub fn ul_code_page_range_1(&self) -> Option<u32>

Code page character range bits 0-31.

source

pub fn ul_code_page_range_2(&self) -> Option<u32>

Code page character range bits 32-63.

source

pub fn sx_height(&self) -> Option<i16>

This metric specifies the distance between the baseline and the approximate height of non-ascending lowercase letters measured in FUnits.

source

pub fn s_cap_height(&self) -> Option<i16>

This metric specifies the distance between the baseline and the approximate height of uppercase letters measured in FUnits.

source

pub fn us_default_char(&self) -> Option<u16>

This is the Unicode code point, in UTF-16 encoding, of a character that can be used for a default glyph.

source

pub fn us_break_char(&self) -> Option<u16>

his is the Unicode code point, in UTF-16 encoding, of a character that can be used as a default break character.

source

pub fn us_max_context(&self) -> Option<u16>

This field is used for fonts with multiple optical styles.

source

pub fn us_lower_optical_point_size(&self) -> Option<u16>

This field is used for fonts with multiple optical styles.

source

pub fn us_upper_optical_point_size(&self) -> Option<u16>

This field is used for fonts with multiple optical styles.

Trait Implementations§

source§

impl<'a> Debug for Os2<'a>

source§

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

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

impl<'a> FontRead<'a> for Os2<'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 Os2<'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.
source§

impl TopLevelTable for Os2<'_>

source§

const TAG: Tag = _

OS/2