How to Export a Bitmap Font in FontForge

Exporting a bitmap font in FontForge involves generating specific pixel sizes known as bitmap strikes and choosing a file format that supports raster data. While FontForge primarily functions as an outline vector editor, its built-in bitmap generation tools allow you to produce dedicated bitmap formats like BDF or embed raster strikes directly into TrueType (TTF) and OpenType (OTF) files. This guide details how to create bitmap strikes, configure your export options, and generate the final font file.

Step 1: Create Bitmap Strikes

Before exporting, you must generate the rasterized sizes you want to include:

  1. Open your project in FontForge.
  2. Navigate to Element in the top menu and select Bitmap Strikes Available...
  3. In the dialog box, ensure the Win or Point size radio button is selected depending on your target platform.
  4. Enter the pixel or point sizes you need, separated by commas or spaces (for example: 12, 16, 24).
  5. Click OK. FontForge will automatically rasterize your vector glyphs into the specified bitmap sizes.

Step 2: Review and Edit Pixels (Optional)

If your font relies on manual pixel placement or pixel-hinting:

  1. Go to View > Bdf Bitmaps.
  2. Select the size you wish to inspect.
  3. Double-click any glyph to open the Bitmap View window, where you can add or remove individual pixels using the pencil and eraser tools.

Step 3: Open the Font Generation Window

  1. Navigate to File and click Generate Fonts...
  2. Choose your destination directory and set the file name.

Step 4: Select the Output Format

In the Generate Fonts dialog, you will see two format dropdown menus:

  • For standalone bitmap files: In the primary dropdown menu below the file path, select a dedicated bitmap format such as BDF, Windows FON, or X11 BDF.
  • For embedded bitmaps in vector fonts: Select TrueType or OpenType (CFF) in the main dropdown. Then, locate the secondary dropdown menu (which typically controls bitmap options) and select In TTF/OTF or choose the specific pixel sizes you generated in Step 1.

Step 5: Export the File

  1. Click the Generate button.
  2. If FontForge displays an error or warning dialog (such as missing points or non-integral coordinates), review the issues. For purely bitmap exports, minor vector outline warnings can typically be bypassed by clicking Generate again.
  3. The exported bitmap font file will now be saved in your chosen folder.