SetaPDF_Core_Font_Standard_TimesBoldItalic Class representing the PDF standard font Times-BoldItalic

File: /SetaPDF/Core/Font/Standard/TimesBoldItalic.php

Class hierarchy

Implements

Summary

Static Properties

$_fonts

static protected array SetaPDF_Core_Font_Standard_TimesBoldItalic::$_fonts = array()

An array caching font objects


Properties

$_ascent

The distance from baseline of highest ascender (Typographic ascent)

$_avgWidth

The average width of glyphs in the font.

$_capHeight

The vertical coordinate of the top of flat capital letters, measured from the baseline.

$_charCodeCache

A char code cache which is used in SetaPDF_Core_Font::getCharByCharCode().

$_descent

The distance from baseline of lowest descender (Typographic descent)

$_encodingTable

The encoding table

$_fontBBox

The font bounding box

$_fontFamily

The font family

$_fontName

The font name

$_glyphsWidthCache

A cache of width values

$_indirectObject

$_info

Array holding information about the font

$_isBold

Flag indicating if this font is bold.

$_isItalic

Flag indicating if this font is italic.

$_isMonospace

Flag indicating if this font is monospace.

$_italicAngle

The italic angle

$_kerningPairs

Kerning pairs

$_substituteCharacter

The UTF-16BE unicode value for a substitute character

$_toUnicodeTable

The map that maps character codes to uncidoe values

$_widths

Glyph widths

$_widthsByCharCode

Widths by char codes

$_xHeight

The vertical coordinate of the top of flat non-ascending lowercase letters (like the letter x), measured from the baseline


Static Methods

_createDifferenceArray()

static protected void SetaPDF_Core_Font_Standard::_createDifferenceArray ( SetaPDF_Core_Type_Dictionary $dictionary, string $baseEncoding, array $diffEncoding )

Creates a difference array.

Parameters
$dictionary : SetaPDF_Core_Type_Dictionary
 
$baseEncoding : string
 
$diffEncoding : array
 

create()

static public SetaPDF_Core_Font_Standard SetaPDF_Core_Font_Standard_TimesBoldItalic::create ( SetaPDF_Core_Document $document [, string $baseEncoding = \SetaPDF_Core_Encoding::WIN_ANSI [, array $diffEncoding = array ( ) ]] )

Creates a font object of this font.

Parameters
$document : SetaPDF_Core_Document
 
$baseEncoding : string
 
$diffEncoding : array
 

freeCache()

static public void SetaPDF_Core_Font::freeCache ( SetaPDF_Core_Document $document )

Release font instances by a document instance.

Parameters
$document : SetaPDF_Core_Document
 

freeFontCache()

static public void SetaPDF_Core_Font::freeFontCache ( SetaPDF_Core_Document $document )

Release font instances by a document instance.

Parameters
$document : SetaPDF_Core_Document
 
See

get()

Get a font object by an indirect reference.

The needed font object class is automatically resolve via the Subtype value of the font dictionary.

Parameters
$indirectObjectOrDictionary : SetaPDF_Core_Type_IndirectObjectInterface
 
Exceptions

Throws SetaPDF_Exception_NotImplemented, SetaPDF_Core_Font_Exception

getDefaultDictionary()

Gets a default dictionary for this font.

Parameters
$encoding : string
 

getStandardFontsToClasses()

Helper method to get all available standard font names and their class mapping.


Methods

_getCharCodesTable()

Get the map that maps character codes to unicode values.

_getEncodingTable()

Get the encoding table based on the Encoding dictionary and it's Differences entry (if available).

_getWidths()

protected void SetaPDF_Core_Font_Standard::_getWidths ( void )

Resolves the width values from the font descriptor and fills the $_width-array.

_sortByArray()

protected array SetaPDF_Core_Font_Simple::_sortByArray ( $array $array )

Sorts an array by shifting the array values to the top of the resulting array.

Parameters
$array : $array
 

getAscent()

public float SetaPDF_Core_Font_Standard::getAscent ( void )

Returns the distance from baseline of highest ascender (Typographic ascent).

getAvgWidth()

public integer|float SetaPDF_Core_Font_Simple::getAvgWidth ( [ boolean $calculateIfUndefined = false ] )

Get the average glyph width.

Parameters
$calculateIfUndefined : boolean
 

getBaseEncodingTable()

Get the base encoding table.

The base encoding of all Standard Fonts is StandardEncoding but Symbol and ZapfDingbats. They use their own encoding.

See

getCapHeight()

Get the vertical coordinate of the top of flat capital letters, measured from the baseline.

getCharByCharCode()

public string SetaPDF_Core_Font::getCharByCharCode ( string $charCode [, string $encoding = 'UTF-8' ] )

Converts a char code from the font specific encoding to another encoding.

Parameters
$charCode : string

The char code in the font specific encoding.

$encoding : string

The resulting encoding

getCharCode()

public string SetaPDF_Core_Font::getCharCode ( string $char [, string $encoding = 'UTF-16BE' ] )

Get the final character code of a single character.

Parameters
$char : string

The character

$encoding : string

The output encoding

getCharCodes()

public array SetaPDF_Core_Font::getCharCodes ( string $chars [, string $encoding = 'UTF-16BE' ] )

Get the final character codes of a character string.

Parameters
$chars : string

The character string

$encoding : string

The output encoding

getCharsByCharCodes()

public string|array SetaPDF_Core_Font::getCharsByCharCodes ( string $charCodes [, string $encoding = 'UTF-8' [, bool $asArray = true ]] )

Converts char codes from the font specific encoding to another encoding.

Parameters
$charCodes : string

The char codes in the font specific encoding.

$encoding : string

The resulting encoding

$asArray : bool
 

getDescent()

public float SetaPDF_Core_Font_Standard::getDescent ( void )

Returns the distance from baseline of lowest descender (Typographic descent).

getDictionary()

Get the font dictionary.

getFontBBox()

Returns the font bounding box.

getFontFamily()

Get the font family.

getFontName()

public string SetaPDF_Core_Font_Standard::getFontName ( void )

Get the font name.

getGlyphWidth()

public float|int SetaPDF_Core_Font::getGlyphWidth ( string $char [, string $encoding = 'UTF-16BE' ] )

Get the width of a glyph/character.

Parameters
$char : string

The character

$encoding : string

The input encoding

getGlyphWidthByCharCode()

public float|int SetaPDF_Core_Font_Standard::getGlyphWidthByCharCode ( string $charCode )

Get the width of a glpyh by its char code.

Parameters
$charCode : string
 

getGlyphsWidth()

public float|int SetaPDF_Core_Font::getGlyphsWidth ( string $chars [, string $encoding = 'UTF-16BE' ] )

Get the width of the glyphs/characters.

Parameters
$chars : string

The characters

$encoding : string

The input encoding

getGlyphsWidthByCharCodes()

public float|int SetaPDF_Core_Font::getGlyphsWidthByCharCodes ( string $charCodes )

Get the width of glyphs by their char codes.

Parameters
$charCodes : string
 

getIndirectObject()

getInfo()

public bool|string SetaPDF_Core_Font::getInfo ( string $name )

Get information about the font.

Parameters
$name : string

The name of the font

getItalicAngle()

Returns the italic angle.

getMaxWidth()

public integer|float SetaPDF_Core_Font::getMaxWidth ( void )

Get the max. glyph width.

getMissingWidth()

public integer|float SetaPDF_Core_Font::getMissingWidth ( void )

Get the missing glyph width.

getResourceType()

public string SetaPDF_Core_Font::getResourceType ( void )

Get the resource type.

See

getType()

public mixed SetaPDF_Core_Font::getType ( void )

Get the Subtype entry of the font dictionary.

getXHeight()

public float SetaPDF_Core_Font_Standard::getXHeight ( void )

Get the vertical coordinate of the top of flat non-ascending lowercase letters (like the letter x), measured from the baseline.

isBold()

public boolean SetaPDF_Core_Font_Standard::isBold ( void )

Checks if the font is bold.

isItalic()

public boolean SetaPDF_Core_Font_Standard::isItalic ( void )

Checks if the font is italic.

isMonospace()

public boolean SetaPDF_Core_Font_Standard::isMonospace ( void )

Checks if the font is monospace.

splitCharCodes()

public array SetaPDF_Core_Font::splitCharCodes ( string $charCodes )

Split a string of char codes into single char codes.

Parameters
$charCodes : string