The first in a series by our favorite artist to take a look at the most commonly used window managers.
A few years ago, I did a four-part series on the GIMP for Linux Journal. Those articles served as the basis for my book, The Artists’ Guide to the GIMP, which was published about a year later. I like to write about using Linux from an end-user perspective. Developers are expected to be able to dig and scratch for information. End users need a little more hand-holding. Since the GIMP helped me pretend to be artistic, I tend to approach my writing from what I think an artist might want. In this way, I can show that Linux is more than just a place to dig and scratch. You can actually get real work accomplished here.
In this new series of articles, I’m going to look at the coming of age of the Linux desktop. In particular, I’ll talk about window managers. The desktop has not been the strongest arena for Linux. Many users have complained that the desktop is too clunky or lacks basic features. But the problems that have been pointed out simply require time—time for Linux to mature and developers to write code. What Linux currently lacks in basic features, however, it makes up for in pizzazz. The Linux desktop is an extremely personable place to work.
Some might say it’s fluff. Others refer to it as eye candy. Call it what you want, the Linux desktop has loads of personality. Window managers are a major part of this, although they should not be mistaken for the entire desktop environment. In fact, this is where we’ll start. Just what is the difference between a window manager and a desktop environment?
GNOMEs and Sprockets and Bears, Oh My!
The current buzz in the Linux desktop world focuses on two major players: GNOME and KDE. In nerd parlance, these are desktop environments. GNOME comes to us from Miguel de Icaza, et al. via support from Red Hat, and is based on GTK, the software libraries that are used for the buttons, sliders and so forth you see in GIMP. KDE is based on QT and comes from Matthias Ettrich and the KDE Development Group. Both QT and GTK are known as widget sets. Usually, you use widget sets to build applications, like GIMP or KIllustrator, but GNOME and KDE go beyond just providing applications. They provide infrastructure—underlying rules and guidelines for how applications should look and act. They provide software libraries for allowing applications to communicate with one another. This is how things like drag and drop get implemented. Without GNOME and KDE, dragging a file icon into a wastebasket or onto the printer icon wouldn’t be possible.
There are other environments besides GNOME and KDE. The most widely used environment on UNIX systems is probably CDE, the Common Desktop Environment. CDE is based on a commercial package which uses Motif, and is included on just about every major UNIX workstation these days. Versions of CDE are available for Linux, but most people have stuck to either KDE or GNOME because they have lower licensing fees. Motif used to be very expensive, and although its price has dropped considerably, it’s still relatively expensive to license for Linux distributors. Since the desktop environment is expected to be part of any OS distribution, Linux distributors had to either charge extra for CDE or work with KDE and GNOME. Their choice was obvious.
KDE and GNOME both offer very similar features. Each provides a panel—a bar along one edge of the screen used to launch applications, show system status and allow embedded applications—and can be used with any compliant window manager. Session managers and CORBA support are less visible than the panel, but are probably more important to users. Session managers allow you to start an application at the same place you left it the last time you used it. CORBA allows for interaction between applications. Session management and CORBA are provided as a set of rules (via programming libraries, if you care about that) applications must follow in order for them to work properly in these environments.
Desktop environments provide the entire desktop experience for the user. This ranges from pagers and drag and drop to standardized applications. Both KDE and GNOME have file managers—graphical interfaces for managing files. Window managers don’t usually provide such a tool. Calendars, word processors and spreadsheets are also applications that exist for use with KDE and GNOME, but which are not considered part of those environments; these are just ordinary applications which comply with the rules KDE and GNOME provide for interoperability. Although you’ll hear both GNOME and KDE talk about these tools as part of their environments, don’t be fooled—you can pick your own spreadsheet application; you don’t have to use the ones that come with KDE or GNOME.
One feature that is extremely useful is the pager. The Linux desktop allows you to have off-screen areas you can jump to. These are called virtual desktops, and each desktop often has multiple pages. Essentially, each of these is like an extension of your visible screen—extra screen space with which to work.
Both KDE and GNOME provide their own pagers, as do most window managers. In order for a window manager’s pager to work properly in its respective environment, the window manager needs to be compliant with that environment. Fortunately, the window managers we’ll be discussing are at least partially compliant in one or both environments.
There are a few other differences between GNOME and KDE. KDE already has a built-in help system, while GNOME just recently released one. GNOME is considered by some users to be a little top-heavy—it can use a lot of memory, for example. It’s also less stable than KDE. GNOME, as a project, is about a year younger than KDE, but both have strong development teams working on them. In general, you’ll probably be fairly happy with either environment. In fact, if you’re like me and don’t use drag and drop, file managers or worry about interoperability between applications, you can live without either KDE or GNOME. I don’t run either—at least not yet.
Window Managers
Where KDE and GNOME provide that overall desktop experience, window managers do something a little more basic. They provide the facility which allows you to move your windows around the screen, iconify and maximize them, and kill off those applications which just refuse to go away. Window managers also determine the look of the windows—the borders and title bars, the background images and so forth. The configurable framings you specify for your windows are called themes. It’s the pizzazz we talked of earlier. For artists and anyone interested in personalizing their private desktops, the window manager is the focus.
KDE and GNOME provide default window managers: kwm for KDE and Enlightenment (or, more recently, Sawmill) for GNOME. A desktop environment wouldn’t be very useful without a window manager. It would, in fact, be almost useless. The relationship between desktop environments and window managers is fairly symbiotic. However, you don’t have to use the default window managers provided by these environments. You can run any window manager—and there are several—with either environment. In order to make use of all the underlying features of KDE or GNOME (such as session management), you need to run a window manager which is compliant, and not all window managers are. In fact, very few are fully compliant with either KDE or GNOME, much less with both of them. For this reason, I’ll be focusing on three window managers that are compliant with at least one of these environments and which provide support for themes: Enlightenment, Window Maker and AfterStep.
Like their desktop environment counterparts, window managers usually provide extra features which border on being applications on their own. Pagers fit in this category. Whether you use the environment’s pager or the window manager’s pager depends mostly on choice, although use of the panel in either KDE or GNOME may force you to use their pagers as well. Window managers also provide management of desktop icons. In most cases, this is hidden from the user—you get a graphical tool for specifying where the icons get placed (left side, right side, restricted to a specific region, etc.). In some window managers, you get a visible box for the icons, called the icon box. Enlightenment, for example, uses a very obvious box by default which can be configured to be essentially invisible.
Themes
After all this technical jargon, we get to the part which artists will likely love the most—themes. Themes do nothing more than specify the look of backgrounds (on the root window or in any other window), window borders, icons, and in some cases, the applications themselves. It’s fluff, but interesting fluff—a personalization of the computer on which you spend so much of your life.
Window managers provide most of the features you need for themes. KDE and GNOME have support for themes, but they do it differently. KDE’s default window manager, kwm, supports themes like any other window manager. GNOME gets its support from GTK, the widget set I spoke of earlier. GTK is interesting because it allows you to give the same theme to any application based on it. In other words, GNOME applications, which are generally based on GTK, can all be changed at the same time by changing the GTK theme. This sort of change affects not just the window borders, but the buttons, menus and other visible pieces of an application. KDE, Enlightenment, Window Maker and AfterStep change only the look of window manager features. They don’t change the look of application buttons, menus and so forth.
KDE allows you to change the current theme on the fly using its Control Panel. GNOME does too, using its own Control Center. Both of these are accessed from their respective environment’s panels. Window Maker, AfterStep and Enlightenment allow you to change the theme on the fly as well by using tools that may or may not be included in their respective standard distributions. You can also change the themes by hand if you’re so inclined. However, themes are a relatively new phenomenon, and standardized ways of defining and installing them have not been set. In most cases, you’ll want to use the graphical tools for installing the themes. Creating new themes is rather complex and very specific to each environment or window manager. In this series of articles, I’ll stick to discussing installing themes. In the future, I’ll look into writing about making your own themes, once the process of doing so isn’t quite so convoluted.
What to Look For?
Since window managers keep less information on running applications than the desktop environments do (via their session management features), they tend to take up less memory. Of course, there are exceptions to every rule. AfterStep has a small memory footprint, but because Enlightenment is so graphics-intensive, it can have a huge footprint. On your desktop, which has a gigabyte of memory so you can work on huge print images in the GIMP, it probably won’t matter which window manager you use based on memory usage. But it will make a difference on memory-limited laptops. Memory usage is something to be aware of, depending on where you’re working.
A good pager is essential. I don’t work with GNOME or KDE (they don’t provide features I need right now), so I can choose any window manager. For a long time, I used only FVWM2, specifically because of its pager. The desktops and their pages were displayed as small boxes right on the screen, and I could drag windows from one desktop to another simply by dragging it from the pager into the main screen. The pager also showed the names of the windows (from their title bars), albeit in truncated form. The sizes of the windows in the pager were proportional to their actual sizes in their desktops. Enlightenment now has a very similar pager which I find very attractive in its look and usage. Window Maker, on the other hand, has a pager which is just a button that bounces you around the desktops, but I can’t see what’s in each of them until I get there. I also can’t divide the pager into multiple desktops with multiple pages in each. In Window Maker, I get essentially one page per desktop. Whether you consider this good or bad is a matter of personal taste. What is important is that you consider the pager in the window manager you choose, since you will be using it quite a bit.
On-line help is useful, but only initially. Both desktop environments have on-line help built into them. Enlightenment has its own help system; Window Maker and AfterStep have HTML-based help. The usefulness of this depends on how long it takes you to become familiar with the environment. In my opinion, if you need to refer to the help system for months on end, the system is far too complex and you should consider looking at another window manager.
Now, if we go beyond these basic necessities, we get into the niceties. It would be helpful if your window manager had the ability to add dockable applications. These are sometimes called applets, epplets and various other things (everyone has their own terminology, apparently). It’s an application with a very specific function—e.g., monitoring the time you’ve spent on-line with your ISP—that runs in a small icon or, more commonly, in a panel. You’ll want your window manager to provide features which can maximize screen space, too. Things like window shading—rolling a window up into its title bar to hide it, and unrolling it back down again. This reduces the visual clutter of your desktop, but it’s certainly not required for the window manager to be useful. A pager that can be hidden would also be nice. Enlightenment provides this, but Window Maker doesn’t because its pager doesn’t take up as much space as Enlightenment’s can. Of course, you’ll want theme support. After all, pizzazz is the whole point.
Changing Window Managers
How do you use your window manager of choice? If you’re using KDE or GNOME, you’re probably logging in and everything is already set for you.
With GNOME, you can specify a separate window manager just by editing your $HOME/.Xclients file. You probably don’t have one of these to start, but you can create it by hand. For example, to run GNOME with Window Maker, your .Xclients file would look like this:
gnome-session& wmaker
KDE is a little different. It needs to start a couple of different programs. If you have the startkde script (available on Red Hat 6.x or similar systems, possibly on others), you can replace kwm in that script with the window manager of your choice.
Whether you start X manually (using startx, for example) or have it start automatically when you log in, modifying your .Xclients file should be sufficient to get your window manager going.
So that’s an introduction to desktop environments and window managers. It can seem complex, but it really isn’t hard to understand after you’ve used it for a while. As with anything new, unfamiliarity breeds contempt. You just need some time to make friends with this new world.
In the next article, I’ll cover the Enlightenment window manager in depth. This will include issues on building, installing, configuring and using it. That will be followed by articles on Window Maker and AfterStep. In the end, you’ll become familiar enough with these so that you can pick and choose from the many window managers available. At that point, your computer will no longer be someone else’s idea of a desktop. It will truly be yours.