in FreeBSD, UNIX

Part 3: Getting Started With Window Maker

With Vim and Doas handy, you’re ready to start conquering the world! Well, maybe not the world, but you’re at least ready to start conquering FreeBSD!

To get started, we’re just going to install X11 and Window Maker itself. X11 is the 11th version of the X Window System, a framework used to develop windowing systems that allow you to see, use and manipulate graphical windows. Window Maker is a window manager that uses X11 to draw graphical applications on your screen. In case you want to take a look at it before installing it, you can see it in action in this Debian GNU/Linux screenshot. It will look the same on any operating system, we just won’t have the same applications.

Let’s run the pkg command required to get Window Maker installed from your user account.

doas pkg install xorg windowmaker

Now that we have doas installed, we no longer need to log in as root via any other method. Confirm you want to install the packages, and we’re off. If you finished the drink you fetched during the last package installation, feel free to get another. I and your FreeBSD install will still be here when you get back.

Once everything is installed, we need to tell X11 what window manager to use. You can use X11’s default window manager, twn, but it isn’t very versatile. We have to create a new file, ~/.xinitrc, and use that to tell X11 to start Window Maker. We’re going to do this in Vim!

vim ~/.xinitrc

Vim should open up again, this time with the new file that we have specified.

Terminal Tip: If you want to create a file without using an editor such as Vim, use touch. Entering touch ~/.xinitrc will create an empty file of that name at that location.

In the same way we entered the doas configuration, go ahead and enter the following in the new file, then write it to your disk and quit Vim.

exec wmaker

That’s it. X11 is now configured to open Window Maker when you run it. There should be no additional configuration to make at this stage, as X11 will detect your system configuration automatically and create all of its configuration files by itself. Let’s go ahead and start X11 by entering the startx command. You should be greeted with your new Window Maker window manager in its default configuration.

The default Window Maker configuration.

The default Window Maker configuration.


That’s it. Window Maker is now installed and fully functional. But we don’t know how to use it, do we? The first thing we need to do is get another terminal window open, so that we can continue configuring everything. There are two ways we can do this – via the root window menu or via the dock.

Using Window Maker: The Basics

Window Maker, showing the root window menu and the dock side by side.

The root window menu (left) and the dock (right).


The dock, visible in the image above on the right-hand side of the screen, works very similarly to the macOS dock introduced with Mac OS X. You can add new items to it by dragging them to the dock, and you can open any of the items in the dock by clicking on their icon.

The very first item in the default dock is the Window Maker Preferences panel. Clicking that will open Window Maker’s preferences, which we will come to shortly. The second item is xterm, X11’s terminal emulator. It won’t have an icon to begin with, but the icon will appear the first time you run it.

The root window menu, visible in the image above on the left-hand side, is accessible by right clicking on your workspace – the blank background area that looks like a desktop.

As you can see, the menu has a lot of submenus and items. This menu is where you will be launching most of your programs, and it can be customised to host buttons that run specific commands or scripts. You can access xterm through the root window menu by navigating to Applications -> Terminals -> xterm and clicking it.

Open xterm now, through either method, and you will be greeted by xterm opening in your workspace.

Xterm open in the current Window Maker workspace.

xterm open in the current Window Maker workspace.

Now that we have xterm open, we can learn some of Window Maker’s basic window management functions. First, try double-clicking on the titlebar at the top of the window. The client area – the application window below the titlebar – will minimize, and only the titlebar will remain. Double-click again to reveal the window once again. You can use this to hide the current window when you have multiple windows open.

Alternatively, click the miniaturise button, located at the left end of the titlebar. The application should drop down into a miniwindow, located at the bottom-left of the screen. Now the application is minimised in a manner more familiar to users of Windows or macOS. You can return the window to its original state by clicking on the miniwindow.

A minimised window and a miniaturised window.

A minimised window (above) and a miniaturised window (below).

That’s all we need to know about managing windows and launching applications for now. If you want to play around some more, try using a mixture of the shift and control keys when double clicking the titlebar, or explore the menu that appears when you right click the titlebar.

Keeping xterm open for the time being, now we can move on to using a graphical login manager to facilitate logging in to your new desktop without having to use the command line.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.