Asian Solaris software provides support for editing bitmap fonts. The Font Editor is in /usr/openwin/bin/fontedit.
The Font Editor handles English or Asian characters in Bitmap Distribution Format (BDF), a portable format defined by the MIT X Consortium. BDF font files have the file extension .bdf.
However, the Asian Solaris operating environment uses Portable Compiled Format (PCF) for bitmap fonts, and Solaris software provides tools to convert between BDF and PCF.
The process of modifying a font involves the following steps.
Locate an Asian font file in BDF.
The encoding should start at 8481(0X2121), as shown in the following example of myfont16.bdf.
STARTFONT 2.1 COMMENT Sample Font FONT Myfont-Medium SIZE 16 75 75 ... STARTCHAR C101 ENCODING 8481 ...
Start fontedit to modify the BDF file and choose either single-byte encoding for ASCII/English characters or multibyte encoding for Korean or Chinese characters.
Edit your chosen font characters using the left mouse button to turn pixels on and the middle button to turn pixels off.
For information on using Font Editor, see the chapter on using Font Editor with your locale in the Asian Solaris user's guide appropriate to your localization.
Save the edited font.
Make the edited Asian BDF font(s) usable by the Asian Solaris operating environment by converting to PCF format, as in the following example:
system% bdftopcf Myfont16.bdf > Myfont-Medium16.pcf system% compress Myfont-Medium16.pcf |
This section describes how to add a new bitmap font to your environment. The steps assume the working directory is your font directory.
Solaris 2.6 includes the Font Admin tool, which you may prefer to use for configuring fonts. However, the tools is available only if you install the entire cluster. For information about the Font Admin tool, see System Administration Guide.
Move the .pcf file for the new font into your font directory.
Run the mkfontdir command:
system% mkfontdir |
If you have an XLFD name for the font, put the definition of this font into fonts.alias, as in the following example:
For a Korean font:
system% cat >> fonts.alias -new-myfont-medium-r-normal--18-160-75-75-c-160-ksc5601.1987-0 Myfont-Medium16 ^D |
For a Simplified Chinese font:
system% cat >> fonts.alias -new-myfont-medium-r-normal--18-160-75-75-c-160-gb2312.1980-0 Myfont-Medium16 ^D |
For a Traditional Chinese font:
system% cat >> fonts.alias -new-myfont-medium-r-normal--18-160-75-75-c-160-cns11643-16 Myfont-Medium16 ^D |
Set the user preference options of the display, as follows:
system% xset +fp `pwd` system% xset fp rehash [[[optional]]] |
You can view a font by typing:
system% xfd -fn Myfont-Medium16 |
With the Korean locale:
system% xfd -fn "-new-myfont-medium--r-normal--18-160-75-75-c- 160-ksc5601.1987-0" |
With the Simplified Chinese locale:
system% xfd -fn "-new-myfont-medium--r-normal--18-160-75-75-c- 160-gb2312.1980-0" |
With the Traditional Chinese locale:
system% xfd -fn "-new-myfont-medium--r-normal--18-160-75-75-c- 160-cns11643-16" |