• DR-IT Software
  • Products
  • Documentation
  • Product page
  • Examples
  • API reference
  • Support
Show / Hide Table of Contents

Class TtfGlyfTable

Parsed OpenType "glyf" table. Provides lazy on-demand parsing of individual glyph outlines using the "loca" table to locate each glyph's data within the raw byte array. Ref: OpenType spec §5.3.3.

Inheritance
object
TtfTableBase
TtfGlyfTable
Inherited Members
TtfTableBase.Tag
TtfTableBase.RawBytes
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: DRIT.Drawing.Font.Ttf.Tables
Assembly: DRIT.Drawing.dll
Syntax
public sealed class TtfGlyfTable : TtfTableBase

Fields

TableTag

The table tag for the glyf table.

Declaration
public const string TableTag = "glyf"
Field Value
Type Description
string

Methods

Create(byte[], TtfLocaTable)

Wraps the raw "glyf" table bytes together with the parsed "loca" table. No parsing is performed at construction time; glyphs are parsed on demand.

Declaration
public static TtfGlyfTable Create(byte[] rawBytes, TtfLocaTable loca)
Parameters
Type Name Description
byte[] rawBytes
TtfLocaTable loca
Returns
Type Description
TtfGlyfTable

GetGlyphOutline(int)

Parses and returns the outline data for the glyph at glyphIndex. Returns Empty for glyphs with no outlines (e.g. the space character) and null for out-of-range indices or corrupt data.

Declaration
public GlyphOutlineData? GetGlyphOutline(int glyphIndex)
Parameters
Type Name Description
int glyphIndex
Returns
Type Description
GlyphOutlineData
Back to top

DR-IT Software documentation

DR-IT Software · Products · Documentation index · Product page · Downloads · Support · Licensing

Generated by DocFX