SetaPDF_Core_Font_TrueType_Subset_File_ByteEncoding Font subsetting class used for single byte encoding.
File: /SetaPDF v2/Core/Font/TrueType/Subset/File/ByteEncoding.php
Class hierarchy
Summary
Properties
$_cmapOriginSubTable
The origin cmap subtable.
$_cmapTargetSubTable
The resulting cmap subtable.
$_glyf
The glyf table.
$_tables
The table instances.
Static Methods
calculateChecksumAdjustment()
Calculates the checksum adjustment.
Parameters
- $offsetData : string
- $checksums : string[]
calculateTableChecksum()
Calculates a table checksum.
Parameters
- $data : string
Methods
__construct()
The constructor.
Parameters
- $font : SetaPDF_Core_Font_TrueType_File
Exceptions
Throws SetaPDF_Core_Font_Exception
_prepareSubset()
_resolveGlyphs()
Resolves all the glyphs recursively and updates the data array accordingly.
Parameters
- $glyphs : array
- $data : array
- $depth : int
Exceptions
Throws SetaPDF_Core_Font_Exception
_writeOffsetTable()
Writes the offset table.
Parameters
- $writer : SetaPDF_Core_Writer_WriterInterface
_writeTable()
Writes a single table and returns information about it.
Parameters
- $writer : SetaPDF_Core_Writer_WriterInterface
- $tag : string
_writeTables()
Writes the tables.
Parameters
- $writer : SetaPDF_Core_Writer_WriterInterface
addChar()
Adds a character to the subset and returns the value to which it is registered.
Parameters
- $char : string
The char in UTF16-BE encoding
Exceptions
addCharCode()
Adds a char code to the subset.
Parameters
- $charCode : int
The unicode point to add.
Return Values
The new point in the individual encoding.
Exceptions
getTable()
Gets a table.
Parameters
- $tag : string
Exceptions
Throws SetaPDF_Core_Font_Exception
subset()
Subsets the font.
Parameters
- $writer : SetaPDF_Core_Writer_WriterInterface
Exceptions
Throws SetaPDF_Core_Font_Exception