Metrics

lumin.glyph. Metrics

Metrics provided by the font to position glyphs.
Quantities are in tile coordinates, typically [0, 1].

Constructor

new Metrics()

Classes

AdvancePen
BoundingBox

Members

advancePen :lumin.glyph.Metrics.AdvancePen

Pen advance in the AdvanceDirection to draw the next glyph.

Type:

horizBB :lumin.glyph.Metrics.BoundingBox

The bounding box of the glyph within its tile for horizontal layouts.

Type:

padding :vec2

Padding for the glyph's width and height, respectively, added
for image effects. The default indicates the glyph is not
padded; i.e., it fits snugly into its bounding box.

Type:
  • vec2

vertBB :lumin.glyph.Metrics.BoundingBox

The bounding box of the glyph within its tile for vertical layouts.

Type:

Methods

toString() → {string}

Returns:
Type
string

lumin.glyph. Metrics

new Metrics(ap, hbb, vbb)

Parameters:
Name Type Description
ap lumin.glyph.Metrics.AdvancePen
hbb lumin.glyph.Metrics.BoundingBox
vbb lumin.glyph.Metrics.BoundingBox

Classes

AdvancePen
BoundingBox

Members

advancePen :lumin.glyph.Metrics.AdvancePen

Pen advance in the AdvanceDirection to draw the next glyph.

Type:

horizBB :lumin.glyph.Metrics.BoundingBox

The bounding box of the glyph within its tile for horizontal layouts.

Type:

padding :vec2

Padding for the glyph's width and height, respectively, added
for image effects. The default indicates the glyph is not
padded; i.e., it fits snugly into its bounding box.

Type:
  • vec2

vertBB :lumin.glyph.Metrics.BoundingBox

The bounding box of the glyph within its tile for vertical layouts.

Type:

Methods

toString() → {string}

Returns:
Type
string