BaseCoord Tables

Within the BASE table, a BaseCoord table defines baseline and min/max extent values. Each BaseCoord table defines one X or Y value:

If defined within the HorizAxis table, then the BaseCoord table contains a Y value.

If defined within the VertAxis table, then the BaseCoord table contains an X value.

All values are defined in design units, which typically are scaled and rounded to the nearest integer when scaling the glyphs. Values may be negative.

Three formats available for BaseCoord table data define single X or Y coordinate values in design units. Two of the formats also support fine adjustments to the X or Y values based on a contour point or a Device table.

BaseCoord Format 1

The first BaseCoord format (BaseCoordFormat1) consists of a format identifier, followed by a single design unit coordinate that specifies the BaseCoord value. This format has the benefits of small size and simplicity, but the BaseCoord value cannot be hinted for fine adjustments at different sizes or device resolutions.

Example 5 at the end of the chapter shows a sample of a BaseCoordFormat1 table.

BaseCoordFormat1 table: Design units only

Type

Name

Description

uint16

BaseCoordFormat

Format identifier

  

—format = 1

int16

Coordinate

X or Y value, in design units


BaseCoord Format 2

The second BaseCoord format (BaseCoordFormat2) specifies the BaseCoord value in design units, but also supplies a glyph index and a contour point for reference. During font hinting, the contour point on the glyph outline may move. The point's final position after hinting provides the final value for rendering a given font size.

Note: Glyph positioning operations defined in the GPOS table do not affect the point's final position.

Example 6 shows a sample of a BaseCoordFormat2 table.

BaseCoordFormat2 table: Design units plus contour point

Type

Name

Description

uint16

BaseCoordFormat

Format identifier

  

—format = 2

int16

Coordinate

X or Y value, in design units

GlyphID

ReferenceGlyph

GlyphID of control glyph

uint16

BaseCoordPoint

Index of contour point on the ReferenceGlyph


BaseCoord Format 3

The third BaseCoord format (BaseCoordFormat3) also specifies the BaseCoord value in design units, but it uses a Device table rather than a contour point to adjust the value. This format offers the advantage of fine-tuning the BaseCoord value for any font size and device resolution. (For more information about Device tables, see the chapter, Common Table Formats.)

Example 7 at the end of this chapter shows a sample of a BaseCoordFormat3 table.

BaseCoordFormat3 table: Design units plus Device table

Type

Name

Description

uint16

BaseCoordFormat

Format identifier

  

—format = 3

int16

Coordinate

X or Y value, in design units

Offset

DeviceTable

Offset to Device table for X or Y value