Fixed Point Kerning Table (FK, Version 1.0)

The FK table is a simple and efficient solution that makes it possible to store kerning information with a high accuracy in OpenType fonts.

Names

The table name for horizontal kerning is "FK" and the table name for vertical kerning is "FKV". The name should be padded up to four bytes with space in the TTF and OTF lists of tables (just like the CFF table). Name: FK space space

Table

uint16 version_upper = 1;
uint16 version_lower = 0;
uint32 num_kerning_pair_entries;
KerningEntry[]

KerningEntry
uint32 first_glyph_index
uint32 second_glyph_index
fixed16_16 kerning

Padding up to four bytes will not be needed because the table already is aligned.

The type fixed16_16 is a fixed point value (16.16) that uses 32 bits, similar to the 255 type in the CFF table.

All kerning entries needs to be sorted on the first and second glyph ID (GID).

Example data

Type Hex Decimal Description
USHORT 0x0001 1 Major verison
USHORT 0x0000 0 Minor version
ULONG 0x00000002 2 Number of kerning pairs
ULONG 0x00000007 7 First GID of the pair (left in LTR languages)
ULONG 0x00000008 8 Second GID of the pair (right in LTR languages)
Fixed 0xffffcccc -0.2 Kerning for this pair
ULONG 0x0000000A 10 First GID of the second pair (left in LTR languages)
ULONG 0x0000000F 15 Second GID of second the pair (right in LTR languages)
Fixed 0xffffe666 -0.1 Kerning for this pair