The MinMax Table and FeatMinMaxRecord

The MinMax table specifies extents for scripts and language systems. It also contains an array of FeatMinMaxRecords used to define feature-specific extents.

Both the MinMax table and the FeatMinMaxRecord define offsets to two BaseCoord tables: one that defines the mimimum extent value (MinCoord), and one that defines the maximum extent value (MaxCoord). Each extent value is a single X or Y value, depending upon the text direction, and is specified in design units. Coordinate values may be negative.

Different tables define the min/max extent values for scripts, language systems, and features:

Min/max extent values for a script are defined in the DefaultMinMax table, referenced in a BaseScript table.

Within the DefaultMinMax table, FeatMinMaxRecords can specify extent values for features that apply to the entire script.

Min/max extent values for a language system are defined in the MinMax table, referenced in a BaseLangSysRecord.

FeatMinMaxRecords can be defined within the MinMax table to specify extent values for features applied within a language system.

In a FeatMinMaxRecord, the MinCoord and MaxCoord tables specify the minimum and maximum coordinate values for the feature, and a FeatureTableTag defines a 4-byte feature identification tag. The FeatureTableTag must match the tag used to identify the feature in the FeatureList of the GSUB or GPOS table.

Each feature that exceeds the default min/max values requires a FeatMinMaxRecord. All FeatMinMaxRecords are listed alphabetically by FeatureTableTag in an array (FeatMinMaxRecord) within the MinMax table. FeatMinMaxCount defines the total number of FeatMinMaxRecords.

Text-processing clients should use the following procedure to access the script, language system, and feature-specific extent data:

Determine script extents in relation to the text content.

Select language-specific extent values with respect to the language system in use.

Have the application or user choose feature-specific extent values.

If no extent values are defined for a language system or for language-specific features, use the default min/max extent values for the script.

Example 4 at the end of this chapter has two parts. One shows MinMax tables and a FeatMinMaxRecord for different script, language system, and feature extents. The second part shows how to define these tables when a language system needs feature-specific extent values for an obscure feature, but otherwise the language system and script extent values match.

MinMax table

Type

Name

Description

Offset

š MinCoord

Offset to BaseCoord table

—defines minimum extent value

—from the beginning of MinMax table

—may be NULL

Offset

š MaxCoord

Offset to BaseCoord table

—defines maximum extent value

—from the beginning of MinMax table

—may be NULL

uint16

FeatMinMaxCount

Number of FeatMinMaxRecords

—may be zero (0)

struct

FeatMinMaxRecord

Array of FeatMinMaxRecords

[FeatMinMaxCount]

—in alphabetical order, by FeatureTableTag


FeatMinMaxRecord

Type

Name

Description

Tag

FeatureTableTag

4-byte feature identification tag

—must match FeatureTag in FeatureList

Offset

š MinCoord

Offset to BaseCoord table

—defines minimum extent value

—from beginning of MinMax table

—may be NULL

Offset

š MaxCoord

Offset to BaseCoord table

—defines maximum extent value

—from beginning of MinMax table

—may be NULL