dev builds
themes manual
device status forums
mailing lists
IRC bugs
dev guide

Search | Go
Wiki > Main > CreateFonts > FontFormat (r1)

FNT Font File Format

FNT is a simple binary font format used by Rockbox. It is a fixed-size raster font format that supports unicode.

In this context a 'long' is intended to mean a 32 bit unit regardless of target architecture.


The FNT header is exactly 36 bytes long consisting of the following fields:

Field length (bytes) description
* UCHAR version[4] 4 magic number and version bytes (currently 'RB12')
* USHORT maxwidth 2 font max width in pixels
* USHORT height 2 font height in pixels
* USHORT ascent 2 font ascent (baseline) in pixels
* USHORT pad 2 unused, pad to 32-bit boundary
* ULONG firstchar 4 first character code in font
* ULONG defaultchar 4 default character code in font
* ULONG size 4 # characters in font
* ULONG nbits 4 # bytes imagebits data in file
* ULONG noffset 4 # longs offset data in file
* ULONG nwidth 4 # bytes width data in file


(to be written)
r1 - 03 Mar 2006 - 04:01:15 - BernardKethlayne

Parents: CreateFonts
Copyright by the contributing authors.