Creation and Use of Bitmap Font
We use freeware Bitmap Font Generator for generating bitmap fonts, and explain how to use bitmap fonts in QICI Engine.
The following are some other tools that also generate output in the same format and are widely used in the industry today:
- Littera - free web application
- Glyph Designer paid app for Mac
- ShoeBox free tool written with Adobe Air
- Hiero open source tool written in Java
Generating Bitmap Fonts
Open Bitmap Font Generator software, select menu Options/Font Setting:
Choose font family, change font size. If using imported images, do not need this step.
Select menu Options/Export options：
Set width and height for exported image, and change File format to XML.
If using imported images, select menu Edit/Open Image Manger to import images for chars：
Select menu Options/Save bitmap font as... to export bitmap fonts. After exporting, we get two files, one with .fnt suffix and another one with .png suffix.
Importing Bitmap Fonts
- Rename file with .fnt suffix to .xml suffix, and keep fnt and xml files have the same name:
- file.fnt -> custom.xml
- file.png -> custom.png
- Drag the two files into Project panel, for example in Assets/bitmapfont/custom.bin
Setting Bitmap Fonts for UIText
- Set UIText's Font Family property as Bitmap
- Set UIText's Font property as the Assets/bitmapfont/custom.bin