Monday, August 06, 2012

xterm fonts

I needed to figure out how to cope with setting the font size for xterm.  Historically I have used "xterm -fn 10x20", which gives a nice font.  The "-fn" option specifies a font name.  Now depending on what a person has installed on their Linux system there could be a large number of fonts.  Running "xlsfonts" will print a list of fonts.  On my computer I noticed "terminus-32" which gave a pretty large font.

This is needed as I start letting users configure ebe.  One of the configurable items will be the font for xterm which is used for terminal I/O for the program being debugged.  I can't figure out a good way to settle this issue inside ebe, so I will give the user a few suggestions for fonts on my computer and suggest experimenting  with the names printed by xlsfonts.

Another option is to use TrueType fonts.  A useful list can be obtained using

    fc-list :scalable=true:spacing=mono: family

Then you can specify a font for xterm using -fa Courier (or whatever) and specify a size using -fs 14 (or some other number).  This gives more options.

No comments: