Class: HexaPDF::Font::TrueType::Table::Cmap
- Inherits:
-
Table
- Object
- Table
- HexaPDF::Font::TrueType::Table::Cmap
- Defined in:
- lib/hexapdf/font/true_type/table/cmap.rb
Overview
The 'cmap' table contains subtables for mapping character codes to glyph indices.
See:
Instance Attribute Summary collapse
-
#tables ⇒ Object
The available cmap subtables.
-
#version ⇒ Object
The version of the cmap table.
Instance Method Summary collapse
-
#preferred_table ⇒ Object
Returns the preferred of the available cmap subtables.
Instance Attribute Details
#tables ⇒ Object
The available cmap subtables.
56 57 58 |
# File 'lib/hexapdf/font/true_type/table/cmap.rb', line 56 def tables @tables end |
#version ⇒ Object
The version of the cmap table.
53 54 55 |
# File 'lib/hexapdf/font/true_type/table/cmap.rb', line 53 def version @version end |
Instance Method Details
#preferred_table ⇒ Object
Returns the preferred of the available cmap subtables.
A preferred table is always a table mapping Unicode characters.
61 62 63 |
# File 'lib/hexapdf/font/true_type/table/cmap.rb', line 61 def preferred_table tables.select(&:unicode?).max_by(&:format) end |