classes-Com-Tecnick-Pdf-Font-Import-TrueType

It appears that you are using AdBlocking software. The cost of running this website is covered by advertisements. If you like it please feel free to a small amount of money to secure the future of this website.

Com\Tecnick\Pdf\Font\Import\TrueType

Tags
since
2011-05-23
category

Library

author

Nicola Asuni info@tecnick.com

copyright

2011-2016 Nicola Asuni - Tecnick.com LTD

license

http://www.gnu.org/copyleft/lesser.html GNU-LGPL v3 (see LICENSE.TXT)

link
https://github.com/tecnickcom/tc-lib-pdf-font

Table of Contents

$fbyte  : Byte
Object used to read font bytes
$fdt  : array<string|int, mixed>
Extracted font metrics
$font  : string
Content of the input font file
$offset  : int
Pointer position on the original font data
$subchars  : array<string|int, mixed>
Array containing subset chars
$subglyphs  : array<string|int, mixed>
Array containing subset glyphs indexes of chars from cmap table
__construct()  : mixed
Process TrueType font
getFontMetrics()  : string
Get all the extracted font metrics
getSubGlyphs()  : array<string|int, mixed>
Get glyphs in the subset
addCtgItem()  : mixed
Add CTG entry
checkMagickNumber()  : mixed
Check if the font is a valid type
getBbox()  : mixed
Get BBox, units and flags
getCIDToGIDMap()  : mixed
Get CIDToGIDMap
getEncodingTables()  : mixed
Get encoding tables
getFontName()  : mixed
Get font name
getHeights()  : mixed
Get font heights
getHheaData()  : mixed
Get hhea data
getIndexToLoc()  : mixed
Get index to loc map
getMaxpData()  : mixed
Get maxp data
getOS2Metrics()  : mixed
Get encoding tables
getPostData()  : mixed
Get post data
getTables()  : mixed
Get the font tables
getWidths()  : mixed
Get font widths
isValidType()  : mixed
Check if the font is a valid type
process()  : mixed
Process TrueType font
processFormat0()  : mixed
Process Format 0: Byte encoding table
processFormat10()  : mixed
Process Format 10: Trimmed array
processFormat12()  : mixed
Process Format 12: Segmented coverage
processFormat13()  : mixed
Process Format 13: Many-to-one range mappings
processFormat14()  : mixed
Process Format 14: Unicode Variation Sequences
processFormat2()  : mixed
Process Format 2: High-byte mapping through table
processFormat4()  : mixed
Process Format 4: Segment mapping to delta values
processFormat6()  : mixed
Process Format 6: Trimmed table mapping
processFormat8()  : mixed
Process Format 8: Mixed 16-bit and 32-bit coverage
setFontFile()  : mixed
Copy or link the original font file

Properties

$fbyte

Object used to read font bytes

protected Byte $fbyte

$fdt

Extracted font metrics

protected array<string|int, mixed> $fdt = array()

$font

Content of the input font file

protected string $font = ''

$offset

Pointer position on the original font data

protected int $offset = 0

$subchars

Array containing subset chars

protected array<string|int, mixed> $subchars = array()

$subglyphs

Array containing subset glyphs indexes of chars from cmap table

protected array<string|int, mixed> $subglyphs = array()

Methods

__construct()

Process TrueType font

public __construct(string $font, array<string|int, mixed> $fdt, Byte $fbyte[, array<string|int, mixed> $subchars = array() ]) : mixed
Parameters
$font : string

Content of the input font file

$fdt : array<string|int, mixed>

Extracted font metrics

$fbyte : Byte

Object used to read font bytes

$subchars : array<string|int, mixed> = array()

Array containing subset chars

Tags
throws
Exception

in case of error

Return values
mixed

getFontMetrics()

Get all the extracted font metrics

public getFontMetrics() : string
Return values
string

getSubGlyphs()

Get glyphs in the subset

public getSubGlyphs() : array<string|int, mixed>
Return values
array<string|int, mixed>

addCtgItem()

Add CTG entry

protected addCtgItem(int $cid, int $gid) : mixed
Parameters
$cid : int
$gid : int
Return values
mixed

checkMagickNumber()

Check if the font is a valid type

protected checkMagickNumber() : mixed
Tags
throws
Exception

if the font is invalid

Return values
mixed

getBbox()

Get BBox, units and flags

protected getBbox() : mixed
Return values
mixed

getCIDToGIDMap()

Get CIDToGIDMap

protected getCIDToGIDMap() : mixed
Return values
mixed

getEncodingTables()

Get encoding tables

protected getEncodingTables() : mixed
Return values
mixed

getFontName()

Get font name

protected getFontName() : mixed
Return values
mixed

getHeights()

Get font heights

protected getHeights() : mixed
Return values
mixed

getHheaData()

Get hhea data

protected getHheaData() : mixed
Return values
mixed

getIndexToLoc()

Get index to loc map

protected getIndexToLoc() : mixed
Return values
mixed

getMaxpData()

Get maxp data

protected getMaxpData() : mixed
Return values
mixed

getOS2Metrics()

Get encoding tables

protected getOS2Metrics() : mixed
Return values
mixed

getPostData()

Get post data

protected getPostData() : mixed
Return values
mixed

getTables()

Get the font tables

protected getTables() : mixed
Return values
mixed

getWidths()

Get font widths

protected getWidths() : mixed
Return values
mixed

isValidType()

Check if the font is a valid type

protected isValidType() : mixed
Tags
throws
Exception

if the font is invalid

Return values
mixed

process()

Process TrueType font

protected process() : mixed
Return values
mixed

processFormat0()

Process Format 0: Byte encoding table

protected processFormat0() : mixed
Return values
mixed

processFormat10()

Process Format 10: Trimmed array

protected processFormat10() : mixed
Return values
mixed

processFormat12()

Process Format 12: Segmented coverage

protected processFormat12() : mixed
Return values
mixed

processFormat13()

Process Format 13: Many-to-one range mappings

protected processFormat13() : mixed
Tags
TODO:

TO BE IMPLEMENTED

Return values
mixed

processFormat14()

Process Format 14: Unicode Variation Sequences

protected processFormat14() : mixed
Tags
TODO:

TO BE IMPLEMENTED

Return values
mixed

processFormat2()

Process Format 2: High-byte mapping through table

protected processFormat2() : mixed
Return values
mixed

processFormat4()

Process Format 4: Segment mapping to delta values

protected processFormat4() : mixed
Return values
mixed

processFormat6()

Process Format 6: Trimmed table mapping

protected processFormat6() : mixed
Return values
mixed

processFormat8()

Process Format 8: Mixed 16-bit and 32-bit coverage

protected processFormat8() : mixed
Return values
mixed

setFontFile()

Copy or link the original font file

protected setFontFile() : mixed
Return values
mixed
 

© 2004-2023 – Nicola Asuni - Tecnick.com - All rights reserved.
about - disclaimer - privacy