setasign\SetaPDF2\Core\Font\Glyph

GlyphList Class for accessing adobes glyph lists

File: /SetaPDF v2/Core/Font/Glyph/GlyphList.php
Old class name (alias): \SetaPDF_Core_Font_Glyph_List

Class hierarchy

Summary

Constants

LIST_AGL

public const string GlyphList::LIST_AGL = 'glyphlist'

Constant for the adobe glyph list

LIST_AGLFN

public const string GlyphList::LIST_AGLFN = 'aglfn'

Constant for the adobe glyph list for new fonts

LIST_CUSTOM

public const string GlyphList::LIST_CUSTOM = 'custom'

Constant for custom glyph names

LIST_ZDGL

public const string GlyphList::LIST_ZDGL = 'zapfdingbats'

Constant for the zapfdingbats glyph list


Static Properties

$lists

static public array GlyphList::$lists = array(...)

The glyph lists


Static Methods

_byName()

protected static GlyphList::_byName (
string $name,
string $primaryList = GlyphList::LIST_AGL
): string

Get the UTF-16BE value from a glyph list.

Parameters
$name : string
 
$primaryList : string
 

byCode()

public static GlyphList::byCode (
string $code,
string $encoding = 'UTF-16BE',
string $primaryList = GlyphList::LIST_AGL
): string

Get the glyph name by the value.

Parameters
$code : string

The value

$encoding : string

The encoding of the value

$primaryList : string

Use LIST_XXX constant

Return Values

The name will be returned as string.

Exceptions

Throws \InvalidArgumentException if the glyph list is unknown.

byName()

public static GlyphList::byName (
string $name,
string $primaryList = GlyphList::LIST_AGL
): string

Get the UTF-16BE values by a glyph name.

Parameters
$name : string

The glyph name

$primaryList : string

Use LIST_XXX constant

Return Values

The UTF-16BE values will be returned as string.

Exceptions

Throws \InvalidArgumentException if the glyph list is unknown.

byUtf16Be()

public static GlyphList::byUtf16Be (
string $code,
string $primaryList = GlyphList::LIST_AGL
): string

Get the glyph name by the UTF-16BE value.

Parameters
$code : string

The UTF-16BE value

$primaryList : string

Use LIST_XXX constant

Return Values

The glyph name will be returned as string.

Exceptions

Throws \InvalidArgumentException if the glyph list is unknown.

byUtf16BeString()

public static GlyphList::byUtf16BeString (
string $string,
string $primaryList = GlyphList::LIST_AGL
): array

Get a list of all glyphs used in the string.

Parameters
$string : string

The UTF-16BE value

$primaryList : string

Use LIST_XXX constant

Exceptions

Throws \InvalidArgumentException if the glyph list is unknown.