Options
All
  • Public
  • Public/Protected
  • All
Menu

Class FontParserSVG

Parses an SVG font file and contains various methods to extract glyph information

Hierarchy

  • FontParserSVG

Implements

Index

Constructors

constructor

Properties

ascent

ascent: number

descent

descent: number

horizAdvX

horizAdvX: number

rawData

rawData: string

The string data from an SVG file

unitsPerEm

unitsPerEm: number

Methods

getGlyph

  • getGlyph(glyph: string): Glyph | null

getKerning

  • getKerning(u1: number, u2: number): number
  • Finds the kerning for the 2 given characters based on the kerningMaps parsed from the font file.

    Parameters

    • u1: number

      The unicode for the first character

    • u2: number

      The unicode for the succeeding character

    Returns number

    The amount of kerning

Generated using TypeDoc