setasign\SetaPDF2\Core\Font\TrueType
File Parser class for TTF/OTF files
File: /SetaPDF v2/Core/Font/TrueType/File.php
Old class name (alias):
\SetaPDF_Core_Font_TrueType_File
Based on the OpenType specification: http://www.microsoft.com/typography/otspec/
Class hierarchy
Summary
Properties
$_entrySelector
$_numTables
$_rangeShift
$_reader
The reader instance
$_searchRange
$_sfntVersion
Methods
__construct()
The constructor.
Parameters
- $reader : string|\SetaPDF_Core_Reader_Binary
Exceptions
_seekTable()
Set the file pointer to the start byte offset position of table.
Parameters
- $tag : string
Exceptions
areCharsCovered()
Checks if characters are covered by this font.
Parameters
- $chars : array
The chars in UTF-16BE encoding
Exceptions
getWidth()
Get the width of a single character/glyph.
Parameters
- $char : string
Exceptions
Throws \setasign\SetaPDF2\Core\Font\Exception,\setasign\SetaPDF2\NotImplementedException
getWidths()
Get character/glyph width values.
Parameters
- $chars : array
The chars in UTF-16BE encoding
Exceptions
Throws \setasign\SetaPDF2\Core\Font\Exception,\setasign\SetaPDF2\NotImplementedException
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