To: Overview of X, Programming X, Window Managers, Fonts, Download X


Ring of Brodgar

X Fonts

Listing Available Fonts

The X Window system comes with a huge set of fonts. To see a listing of the fonts available on your system, try a program called xlsfonts:

xlsfonts | more 

This lists out many fonts, such as:

-adobe-courier-bold-r-normal--12-120-75-75-m-70-iso8859-1
-adobe-new century schoolbook-medium-r-normal--34-240-100-100-p-181-iso8859-1
-daewoo-gothic-medium-r-normal--16-120-100-100-c-160-ksc5601.1987-0
-misc-fixed-medium-r-normal--14-130-75-75-c-140-jisx0208.1983-0
lucidasans-bold-14
cursor

Decoding Long Font Names

Some of the multi-part names are quite long. These names follow a standard called X Logical Font Description, or XLFD.

Each part of an XLFD name is separated by a hyphen. If a part is missing, you'll see two hyphens in a row. You can also use wildcards, such as * for fields you don't care about.

Going in order, from left to right, the fields follow:

Field Example Description
Foundry adobe,b&h The company that created the font.
Font family times, lucidasans Basic font family name
Weight bold, medium How thick the letters are
Slant i, r Italic, roman, oblique, etc.
Code Meaning
i Italic
o Oblique
r Roman
ri Reverse Italic
ro Reverse Oblique
ot Other
number Scaled font (R6)
Set-width name normal, condensed Width of characters
Additional style sans Extra info to describe font
Pixel size 26, 20 Height, in pixels, of characters
Point size 190, 140 Ten times height of characters in points
Dots-per-inch 100-100, 75-75 Dots per inch in X and Y directions. You can generally ignore this.
Spacing m, p, c Spacing
Spacing Meaning
c Character-cell/monospaced
m Monospaced
p Proportional
number Scaled font (R6)
Average width 94, 159 Ten times the average width in pixels
Charset registry iso8859-1 Character set encoding in the font, some examples:
Character Set Meaning
iso8859-1 Western Europe
hp-roman8 Western Europe (Hewlett-Packard only)
iso8859-2 Eastern Europe
ksc5601.1987-0 Korean
jisx0208.1983-0 Japanese

For more information on XLFD fonts, see chapter 7 in The UNIX System Administrator's Guide to X.


All book covers are used with permission of the publisher.
Copyright ©1998-1999 Eric Foster-Johnson.


Home | Linux | Tcl | Perl | Motif | Computer User | Japanese | My Books | Contact Me

Last updated: August 30 1999