1. Home
  2. Computing & Technology
  3. Focus on Linux

By Juergen Haas, About.com

font specification for ASCII characters would be this:
-*-fixed-medium-r-normal-*-24-*-ISO8859-1

and the font specification for Chinese GB2312 characters would be this:

-*-fixed-medium-r-normal-*-24-*-gb2312*-*

You may not have any Chinese font matching the above font specification. Most X distributions include only Chinese fonts that have song ti or fangsong ti in family field. In such a case, Fontset-n can be specified as below:

Emacs.Fontset-0: -*-fixed-medium-r-normal-*-24-*-*-*-*-*-fontset-24,\ chinese-gb2312:-*-*-medium-r-normal-*-24-*-gb2312*-*

Then, the font specifications for all but Chinese GB2312 characters have fixed in the family field, and the font specification for Chinese GB2312 characters has a wild card * in the family field.

The function that processes the fontset resource value to create the fontset is called create-fontset-from-fontset-spec. You can also call this function explicitly to create a fontset.

See Font X, for more information about font naming in X.

Explore Focus on Linux

More from About.com

  1. Home
  2. Computing & Technology
  3. Focus on Linux

©2008 About.com, a part of The New York Times Company.

All rights reserved.