Traditional Chinese Solaris User's Guide

Customizing Your OpenWindows Workspace

Using Fonts

The localized language functions of Traditional Chinese Solaris applications use font sets, or groups of fonts, including both ASCII character fonts and non-ASCII Traditional Chinese character fonts. These font sets are required for Traditional Chinese display. They can be used, as font names are, in customizing your workspace as described in Traditional Chinese Solaris User's Guide.

Traditional Chinese (zh_TW) Font Lists

A Traditional Chinese (zh_TW) font list is composed of one English font, representing ASCII characters in CNS11643-0 or ISO8859-1, and a number of Traditional Chinese fonts representing characters such as CNS11643-1, CNS1643-1, CNS11643-2, and CNS11643-3.

Traditional Chinese Solaris provides some default font lists defined in application defaults files in /usr/dt/app-defaults/zh_TW/*. The following is an excerpt from one of these files, Dtwm:

Dtwm*icon*fontList: \ 	
-dt-interface system-medium-r-normal-s*-*-*-*-*-*-*-*-*:

This portion of the file refers to a font list that contains the following fonts, which are defined in /usr/openwin/lib/locale/zh_TW/X11/fonts/75dpi/fonts.alias:

"-dt-interface system-medium-r-normal-s serif-16-140-75-75-p-70-cns11643-0"
"-dt-interface system-medium-r-normal-s serif-16-140-75-75-p-140-cns11643-1"
"-dt-interface system-medium-r-normal-s serif-16-140-75-75-p-140-cns11643-2"
"-dt-interface system-medium-r-normal-s serif-16-140-75-75-p-140-cns11643-3"

The first is the English font for codeset 0 (ASCII) character font display. The rest are Traditional Chinese fonts for codeset 1 (CNS11643) plane 1 character font display, and codeset 2 (CNS11643) plane 2 and plane 3 character font display.

Traditional Chinese (zh_TW.BIG5) Font Lists

A Traditional Chinese zh_TW.BIG5 font list is composed of one English font, representing ASCII characters, and one Traditional Chinese font representing Chinese characters in Big 5.

Traditional Chinese Solaris provides some default font lists defined in an application defaults file in /usr/dt/app-defaults/zh_TW.BIG5/*. Below is a part of one of the files, Dtwm:

Dtwm*icon*fontList: \
-dt-interface system-medium-r-normal-s*-*-*-*-*-*-*-*-*

This font list contains the following fonts, defined in /usr/openwin/lib/locale/zh_TW.BIG5/X11/fonts/75dpi/fonts.alias:

"-dt-interface system-medium-r-normal-s serif-16-140-75-75-p-70-big5-0" 	
"-dt-interface system-medium-r-normal-s serif-16-140-75-75-p-140-big5-1"

The first is an English font for ASCII character font display. The second is a Traditional Chinese Big 5 font.

Starting Applications With a Specific Traditional Chinese Font List

When you start an Asian Solaris tool at the command line, you can also specify its fonts. Below is an example of a command line argument used to start a new Traditional Chinese Windows terminal with a specified font list:

system% dtterm -fn  "-dt-interface system-medium-r-normal-s \
serif-16-140-75-75-p-70-cns11643-0; \  	-dt-interface
system-medium-r-normal-s \  	serif-16-140-75-75-p-140-cns11643-1:"

Note the two delimiters used in the font list. The ; delimiter is used to separate the font names except for the last font name, which ends with the ; delimiter. (In the example above, ; follows the English font name, and the : delimiter follows the Traditional Chinese font name.) Since there are spaces in the long font names, the font list is enclosed in quotation marks.

Specifying a Font at the Command Line

You can specify which font a Traditional Chinese OpenWindows application will use on a command line. When the current locale is zh_TW or zh_TW.BIG5, the command uses one of the defined font-set aliases instead (explained in the following section), for example:

system% cmdtool -font fontset_name & 

However, when the current locale is C, the command uses a font name and cannot use a font-set alias. The following shows a command using the long name of an ASCII character font:

system% cmdtool -font 
-misc-fixed-medium-r-normal--9-80-100-100-c-60-iso8859-1 & 

Font Set Names

The Traditional Chinese OpenWindows environment provides several font sets that combine two or more fonts so that both English and Chinese characters can be used together in one window. Five of the font sets each comprise one Roman font (ASCII characters) in the ISO8859 standard plus a Chinese font specified in CNS 11643-92. A few examples are:

Each of these font sets is made up of several font files. The $OPENWINHOME/lib/locale/zh_TW/OW_FONT_SETS/OpenWindows.fs file defines the full Chinese Solaris font set.

In addition, the Traditional Chinese Solaris operating environment provides TrueType scalable fonts in the following type faces:

These fonts are located in $OPENWINHOME/lib/locale/zh_TW/X11/fonts/TrueType

Scaling Applications Windows and Fonts

The $OPENWINHOME/lib/locale/zh_TW/OW_FONT_SETS/OpenWindows.fs file also sets the following font size definitions for use in command lines:

For example, the following command line shows how to start a Command Tool window that uses 16-point type and is scaled proportionally larger than the default:

system% cmdtool -scale large &