SetaPDF_Core_Font_TrueType_File Parser class for TTF/OTF files
File: /SetaPDF v2/Core/Font/TrueType/File.php
Based on the OpenType specification: http://www.microsoft.com/typography/otspec/
Class hierarchy
Summary
Properties
$_entrySelector
$_numTables
$_rangeShift
$_searchRange
$_sfntVersion
$_tableRecords
Data of tables in the TTF file
Methods
__construct()
The constructor.
Parameters
- $reader : string|SetaPDF_Core_Reader_Binary
Exceptions
Throws SetaPDF_Core_Exception
_seekTable()
Set the file pointer to the start byte offset position of table.
Parameters
- $tag : string
Exceptions
Throws SetaPDF_Core_Exception
areCharsCovered()
Checks if characters are covered by this font.
Parameters
- $chars : array
The chars in UTF-16BE encoding
Exceptions
getTable()
Get a tag specific table.
Parameters
- $tag : string
Exceptions
getWidth()
Get the width of a single character/glyph.
Parameters
- $char : string
Exceptions
Throws SetaPDF_Core_Font_Exception,SetaPDF_Exception_NotImplemented
getWidths()
Get character/glyph width values.
Parameters
- $chars : array
The chars in UTF-16BE encoding
Exceptions
Throws SetaPDF_Core_Font_Exception,SetaPDF_Exception_NotImplemented
isCharCovered()
Checks if a character is covered by this font.
Parameters
- $char : string
The character in the specified encoding
- $encoding : string
The encoding - default is UTF-16BE
Exceptions
isEmbeddable()
isSubsettable()
Checks if a font is subsettable and embeddable.