From MEPIS Documentation Wiki

Jump to: navigation, search

Customized Fluxbox Desktop


Getting started with Fluxbox.

Fluxbox is an extremely fast and customizable low resource X11 Window manager. It has cool features such as menu transparency, window tabs (like firefox), configurable key bindings, a toolbar and a menu bar put where you want it. Although it may appear too simplistic when you first install it, here are some ways to set up, reconfigure and add extra eyecandy/functionality to fluxbox.

How to install Fluxbox

(at present - fluxbox version 0.9.14)

Apt-get install fluxbox or through kpackage/synaptic

It is probably worth installing fluxconf too and the artwiz fonts.

Fluxbox can be chosen from the kdm login screen in the menu list.

When first started, you should see a blank background and a little toolbar at the bottom. Right-clicking on the background pops out the fluxbox menu. Clicking an item on the menu opens the package. If there is no menu, or hardly anything in it, you can auto generate one by typing fluxbox-generate_menu in a terminal as user or make a menu from scratch. If you cannot do this, then login to KDE and edit the init file in /home/username/.fluxbox to read:

session.menuFile: /home/username/.fluxbox/fluxbox-menu

see How to edit the menu The toolbar works as expected, showing the icons of every open window as well as the date and time.

Yuck! It's too basic. How to configure Fluxbox

Now that you have a working Fluxbox installation, you will first want to customize the functionality to your needs and work habits. Let's check the files in the ~/.fluxbox directory.

  • init: Main configuration file.
  • menu: File that changes the items in your root menu.
  • keys:Let's you change keybindings and create new ones.
  • apps:Stores information about every application that you want fluxbox to remember, such as default position, size and decoration.
  • lastwallpaper:Created by fbsetbg (more on that later), this file stores the information about the last wallpaper you used so that you don't have to specify its location again.

Make programs startup when Fluxbox starts

To make a program startup, in the /home/user/.fluxbox/apps file add

[startup] {programname}

An example of this is:

[startup] {conky}

[startup] {aterm}

How to set wallpaper/background

For transparency, install feh or Eterm (through apt-get) then

Type in a terminal

fbsetbg -i

You should get a message something like "feh is a nice wallpapersetter. You won't have any problems."

Open up the command-line and type

fbsetbg -f /path/to/wallpaper.jpg (png images work too.)

fbsetbg doesnt set the wallaper itself, it uses other programs to set it for you ie feh or Eterm's esetroot.

eg fbsetbg -f /home/anticapitalista/wallpaper/redrev.jpg

How to make Fluxbox remember the wallpaper

Open up "~/.fluxbox/init" and find the line:


And replace it with

session.screen0.rootCommand: fbsetbg -l

How to hotkey

Customise Fluxbox's key handling through the ~/.fluxbox/keys file. The file takes the format of :

<modifier> <key> [...] :<operation>

In the example below, Mod1 is the 'Alt' key on the PC keyboard and Mod4 is one of the three extra keys on a pc104 "branded with a sickening corporate logo".


  1. Fluxbox keys file.
  2. Any line starting with a # is a comment.

Mod1 Tab :NextWindow

Mod1 F1 :Workspace 1

Mod1 F2 :Workspace 2

Mod1 F3 :Workspace 3

Mod1 F4 :Workspace 4

Mod1 F5 :Workspace 5

Mod1 F6 :Workspace 6

Mod1 F7 :Workspace 7

Mod1 F8 :Workspace 8

Mod1 F9 :Workspace 9

Mod4 b revWorkspace

Mod4 c :Minimize

Mod4 r :ExecCommand rox

Mod4 v :ExecCommand firefox

Mod4 x :ExecCommand thunderbird

Mod4 m :ExecCommand tuxkart

Make sure your ~/.fluxbox/init file has this line:

session.keyFile: ~/.fluxbox/keys

How to make menus transparent

You can change the level of transparency in the menu, or the menu alpha by right clicking to bring up the fluxbox menu then

Fluxbox menu > Fluxbox > Configure >Transparency> Menu Alpha

You can click on the value there to adjust it. "0" is fully transparent, "255" is solid. Values in between have varying levels of transparency.

If you find that the menu's transparency does not take effect immediately, try restarting fluxbox.

How to configure the toolbar

The toolbar can be configured in many ways, by right clicking on it and making the changes ie toolbar width, placement, transparency (alpha), clock editing.

How to edit the time/date format

to look like this: Fri 16 Sep 16.00

To edit clock format edit to this line in the init file.

session.screen0.strftimeFormat: %a %d %b  %k:%M

How to use Fluxbox tabs

Fluxbox is able to tab windows, just like tabbed browsing in Mozilla browsers. This can be a great way of saving space, organising windows, and it's a great feature to show off to your GNOME or KDE friends. These tabs are integrated into the titlebar of a program and are very easy to work with.

To tab one program with another, use your middle mouse button (left and right mouse buttons together if you don't have one) on the titlebar and drag it onto the window you want to have the program tabbed with. It should automatically tab them together and you can choose either one by clicking on it as you would in Mozilla. To untab a program, middle click it's title and drag it away, making sure it is not over any other windows.

How to install icons to the desktop


There are at least 3 ways I know of to do this. 1. Using Rox 2. Using Idesk 3. Using adesklets

1. Using Rox.

Rox is a desktop environment in its own right. Here we will use rox pinboard and panel so icons can be added to the desktop.

Install rox-filer with apt-get or synaptic.

3. Using adesklets.

This involves installing 2 packages.

1. Install adesklets with apt-get or synaptic.

2. Download yab from: http://adesklets.sourceforge.net/desklets.html and untar to /home/

3. Find some nice icons for yab from here: http://www.gentoo.org/dyn/icons.xml and untar them and put them in your icons folder in /home/yab0.0.2

4. Open a terminal and type adesklets (as user)

5. cd yab-0.0.2/

6. ./yab.py

7. You will be asked to register or test. Try test and yab should open in the top left hand corner. Right click on it and you can move it to where you want by dragging.

8. When you close the terminal, yab will disappear, so do 7 again and choose register.

9. Type adesklets

10. Move it to where you want.

11. Create a file named apps in your /home/.fluxbox folder

12. Write this line, then save: [startup] {adesklets}

11. Add this line (or alter if present) to the /home/.fluxbox/init file: session.appsFile: ~/.fluxbox/apps

12. Restart fluxbox and yab should automatically open.

Customise yab by using your own icons etc by editing the config.text

How to edit the menu

If you have no menu, you can auto-create one by typing, in a terminal as user,


If that doesn't work, then follow these steps.

In a konsole:

cd /usr/share/doc/fluxbox


gunzip fluxbox-generate_menu.gz

chmod 755 fluxbox-generate_menu

mv fluxbox-generate_menu /usr/bin



Then, as user, type:


This will create a menu of all apps installed. You will probably want to remove some or make changes.

There is a package that makes this a bit easier called fluxconf. Otherwise do it by hand.

Open this file ~/.fluxbox/menu with your favourite text editor.

Scroll down to the line "[begin] (Fluxbox-0.9.14)". This line begins the menu. You must not delete it, nor the last "[end]" statement. You can change Fluxbox-0.9.14 to whatever you want, it is the title that will be shown when you right click. Next you should see lines similar to "[exec] (Eterm) {Eterm}". This is a basic line in your menu, which executes something. The [exec] declares it as an execution line. (Eterm) states that the menu should display the title "Eterm" and {Eterm} tells fluxbox what to do when you click on that menu entry ie open it. The other basic component of the menu is the submenu. It is declared as "[submenu] (Tile of menu)". All entries below it are a part of the submenu until an [end] is reached, where the entries then return to the main menu.

sample menu:

  1. Automatically generated file. Do not edit (see /usr/share/doc/menu/html/index.html)

[begin] (FLUXBOX 0.9.14)

[submenu] (EDITORS)

[submenu] (TEXT)

[exec] (KATE) {kate}

[exec] (KEDIT) {kedit}


[submenu] (CONSOLE)

[exec] (QEMACS) {qemacs}

[exec] (NANO) {aterm -T "Nano" -e nano}

[exec] (NEDIT) {nedit}


[submenu] (WEB)

[exec] (BLUEFISH) {bluefish}

[exec] (NVU) {nvu}



How to add icons to the menu

If you want include some icons in your menu use this...

[exec] (BLEUFISH) {bluefish } <~/.icons/bluefish.xpm>

[exec] (FIREFOX) {firefox} <~/.icons/firefox.xpm>

[exec] (NVU) {nvu} <~/.icons/nvu.xpm>

where /.icons is where your icons are.

How to lock session

Using xscreensaver

Xscreensaver is a screensaver and can lock the session. You can also add screensavers from KDE to xscreensaver.

See here:[1]

Install xscreensaver through apt-get or synaptic.

To configure xscreensaver, simply open a terminal and type


In Display Modes, choose your screensaver of choice and set the times.

You can also set Lock Screen after x minutes too.

Goto File, (re)start daemon.

To start xscreenserver on boot, add this line to your .fluxbox/apps file.

[startup] {xscreensaver}

To add xscreensaver lock to .fluxbox/menu

[exec] (lock) {xscreensaver-command -lock}

And/Or add to .fluxbox/keys

Mod4 l :ExecCommand xscreensaver-command -lock

Using xlockmore/xlock

Install xlockmore through apt-get or synaptic

Type xlock in a terminal and it locks. To unlock press any key, then type password.

Add this line to .fluxbox/menu

[exec] (lock) {xlock}

And/Or add to .fluxbox/keys

Mod4 l :ExecCommand xlock

(After restarting x, there is no need to type xlock if you use fluxbox menu and/or keys)

Some Quick Fixes

1. If you are having problems with screen resolution making things too small you need to put "xrandr -s 1" in your "/fluxbox/apps" file as the first line.

[startup] {xrandr -s 1}

Links: http://fluxbox-wiki.org/index.php/Fluxbox-wiki

Personal tools