BitFontReader documentation

This is a minimal documentation for BitFontReader (HTML5, Flash).

Making fonts

Creating fonts for BitFontReader is easy - all you need is a pixel art editor of sorts, and a bit of patience.

A pixel font is a horizontal strip with symbols, such as this:

The details that you should be aware of are as following:

Colors

Pixel fonts naturally only contain two colors - foreground and background. BitFontReader will assume background color to be the one in top-left corner of your image, and any other color to be foreground.
This means that you can draw fonts with whatever palette you find appropriate, as long as there is a consistent background color:

Baseline

The left-most column of pixels in the image determines the baseline. If a foreground pixel is placed in it, font's baseline will be set to the "level" right below it, meaning that the row containing that pixel will be "sitting" on the baseline:

Sizes

By default, each pixel in source image will produce a single pixel in resulting font. However, if your font is small enough (6px or less), this may not be the desired effect, as BitFontMaker appears to be setting line height/spacing to 12 pixels.

This means that a 5px font will have enough line spacing to fit another line of text between any given two.

Scaling the font 2X, however, will get you line spacing of 2px, which looks about right.

Options work more or less just like one could expect them to, generally:

The bottom row

The bottom row of pixels in the image is used for hinting spacing before symbols and belonging of groups of pixels to a particular symbol.

This means that you should not have your fonts overlapping that row:

Use of hinting is covered in later sections of this document.

Symbols

Symbols in source image are found automatically, while you specify what each recognized symbol actually is.

The way this works is that the program searches for non-empty (containing at least one foreground pixel) columns of pixels, and considers adjacent non-empty columns to belong to the same symbol.

For a better example, consider the following:

Spacing

By default, BitFontReader will detect spacing automatically,

Spacing between characters is set to the interval between first two non-space characters in the image.

Space (" " symbol) width is set to with of first space in the image, but, unfortunately, BitFontMaker currently does not have support for custom space width, having it set to 5 + spacing on export, meaning that adjustments have to be made to exported fonts separately.

If you need to add extra space before a particular character (for example, to have a 4px wide monospace font), you can do so by adding a line to the bottom row of pixels:

FAQ

Haven't found an answer to your question? Ask me, maybe?