Next 14.C: Adding an
Application
Up 14: Customizing Prev 14.A: Creating an Alias Contents Contents

Basic

wprefsicon§ 14.B: Changing Screen Appearancewprefsicon


A neat way to change your work environment is to change the colors, fonts and sizes of windows. (Everyone believes the defaults colors are awful.) There are several ways to do this. On some machines, your default environment includes the icon shown next to the section title. Doubleclicking on this icon will open a utility called the Window Maker Preferences Utility. If you don't have the icon available, enter

at your shell prompt to start the utility. This program lets you change a lot more than "just" the colors. For the color-button, you need to scroll to the right; it is the second-to-last one. wprefs might not be the most intuitive program ever written, but by simply playing around with the controls you might create something you like. (There is a promising-looking site for explanations, but last time we checked the reviews for the menu items were still missing.)

The other way to change colors is to actually edit your WindowMaker file, which can be found in your home directory under GNUstep/Defaults/WindowMaker. This file also controls a lot more than just the colors of your windows, but we'll mainly focus on that one aspect. If you really want to personalize every last detail of your XWindows environment, using the Window Maker Preferences Utility mentioned above might be easier. To this end, you can also check out http://wm.current.nu/ where (with some patience) you'll probably find just about anything you could possibly want to know about WindowMaker.

If you decide to go ahead with the editing, start by saving the WindowMaker file as WindowMaker.old or something similar. Here you can look at a sample file. In case your WindowMaker file does not contain the color and font information, you can put it there. Issue the command getstyle at your command line. This command dumps all the Window Maker style related configuration information to standard output. By redirecting the output to a file of your choice, you create a so-called style file.

The -t option makes getstyle include information about your current background. (If you look at the style file you just created, you'll see that it looks just like the bottom part of the sample file.) After saving a backup copy of your current WindowMaker file, you can now issue the setstyle command followed by the name of your style file. There should not be any noticable changes in your display, but now your WindowMaker file contains lots of stuff for you to edit! You do need to be careful and adhere to the given syntax; otherwise, your changes will most likely mess up your environment instead of improving it. It might be useful to read section 4.1.3 (scroll down to Appearance Options) of the WindowMaker User's Guide to get an idea of available options, and a description of the color-syntax.

When you feel you're ready to roll, click here for a rather extensive listing of RGB values. The color names used in XWindows are slightly different, so you might just want to use the hexadecimal values in either the "#nnnnnn" or the "rgb:nn/nn/nn" format when you change your WindowMaker file. There is a command called showrgb - pipe its output to more - that lists the XWindows color names, but it displays the RGB values in a decimal format. If you absolutely want to use the color names, you could pipe showrgb's output to grep. For example

will produce
255 165 0 orange 255 140 0 dark orange 255 69 0 orange red 255 165 0 orange1 238 154 0 orange2 205 133 0 orange3 139 90 0 orange4

In case you cannot use your account after you have modified your colors, you can always login using a telnet session and restore your backup by first cding into GNUstep/Defaults/ and then cp WindowMaker.old WindowMaker).

While you're editing away on the colors, you might notice that right above, there is a section controlling the fonts of your screen components. They are given in the so-called X Logical Font Description ("XLFD")-format. The command xfontsel can be used to see the fonts available on your X server. Each field in the second line corresponds to a parameter in the XLFDescription of a font, and clicking these fields will make menus appear from which you can select your font options. For starters, you might want to try reproducing the XLFD strings in your WindowMaker file to get a feel for the sizes, etc. Then, if you decide to actually change your fonts, it's probably easiest to just replace their respective fields in your WindowMaker file as to minimize the chance of syntax errors.

In the next section, we'll show you how to invoke applications when logging into an X environment.


Next 14.C: Adding an
Application
Up 14: Customizing Prev 14.A: Creating an Alias Contents Contents

Comments and questions to request@cs.fiu.edu.