Installing a Font in the Emulator
Printer
To add a font to the available fonts you should modify the file named InstalledFont.username.
This file stores the following information:
The structure of the file is as follows:
Parameter |
Description |
DefaultFont.Size |
The size of the default font. It is specified in unit of measure “point”. It must be listed in the available sizes of the font. |
bitmappedFont |
Supports bitmapped fonts: 1 - yes 0 - no |
DefaultFont.Family |
The font family name of the default font. It must be in the list of installed font families. Note: it also must conform to the font types that the emulated printer supports, bitmapped or scalable. |
scalableFont |
Supports scalable fonts: 1 - yes 0 - no |
InstalledFontFamilies |
The list of installed font family names. The name must be a valid font family name installed in the Operating System where the Printer Emulator is running. |
DefaultFont.Style |
The style of the default font. It must be included in the available styles of the font. |
Font Details: (for a font named fontname)
Key |
Description |
fontname.Sizes |
A list of available sizes of the font family, with values separated by comma. The unit of measure for each size is “point”. |
fontname.Styles |
A list of available styles of the font family separated by comma. Possible values are: 0 : plain 1 : bold 2 : italic 3 : bold and italic |
fontname.Type |
Font type possible values are: 1: bitmapped font type 2: scalable font type |

Adding a font to this file is the equivalent of loading a font into the printer’s memory (in the physical printer). The client API will not be able to use the added font unless it is added to the available font configurations. (Refer to Installing a Font Configuration for more information.)

Read Property Files for Printer Peripheral Type.

The developer can also modify the default configuration by editing the file named InstalledFont.dft. For the changes to take effect in the developer’s emulator, delete the file named InstalledFont.username. The next time the Emulator opens, it will be configured based on the default file.

Changes made to the default file affect any user who launches the Emulator for the first time after these changes are done.
The new font is installed in the Emulator.
The following is an example of the file. The sequence of the lines has been adjusted and blank lines have been added for ease of reading.
#
#Wed Jun 23 11:29:33 EDT 2004
bitmappedFont=1
scalableFont=1
InstalledFontFamilies=SansSerif,Arial
SansSerif.Sizes=8.0,10.0,12.0,14.0,16.0,18.0,20.0,22.0,24.0
SansSerif.Styles=0,1,2,3
SansSerif.Type=2
Arial.Sizes=8.0,12.0,16.0
Arial.Styles=0,1
Arial.Type=1
DefaultFont.Family=Arial
DefaultFont.Style=0
DefaultFont.Size=8.0
Below is an example of the same file after a new font, Batang, was added. For visualization purposes the added font lines have been colored red.

Remember to verify that the font is installed in the Operating System.
#
#Wed Jun 23 11:29:33 EDT 2004
bitmappedFont=1
scalableFont=1
InstalledFontFamilies=SansSerif,Arial,Batang
SansSerif.Sizes=8.0,10.0,12.0,14.0,16.0,18.0,20.0,22.0,24.0
SansSerif.Styles=0,1,2,3
SansSerif.Type=2
Arial.Sizes=8.0,12.0,16.0
Arial.Styles=0,1
Arial.Type=1
Batang.Sizes=8.0,10.0,12.0,14.0,16.0,18.0,20.0,22.0,24.0
Batang.Styles=0,1,2,3
Batang.Type=2
DefaultFont.Family=Arial
DefaultFont.Style=0
DefaultFont.Size=8.0