Table of Contents

Class GlyphHelper

Namespace
PdfSharp.Fonts
Assembly
PdfSharp.dll

Helper function for code points and glyph indices.

public static class GlyphHelper
Inheritance
GlyphHelper
Inherited Members

Methods

GlyphIndexFromCodePoint(int, XFont)

Returns the glyph ID for the specified code point, or 0, if the specified font has no glyph for this code point.

public static ushort GlyphIndexFromCodePoint(int codePoint, XFont font)

Parameters

codePoint int

The code point the glyph ID is requested for.

font XFont

The font to be used.

Returns

ushort

GlyphIndicesFromString(string, XFont)

Maps the characters of a UTF-32 string to an array of glyph indexes. Never fails, invalid surrogate pairs are simply skipped.

public static CodePointGlyphIndexPair[] GlyphIndicesFromString(string s, XFont font)

Parameters

s string

The string to be mapped.

font XFont

The font to be used.

Returns

CodePointGlyphIndexPair[]