Friday, August 7, 2009

Openbox in Lenny

Recently installed the window manager Openbox, which I love as much as Fluxbox, in Debian Lenny after previously installing it in Mepis, and then later in Mint Elyssa and Ubuntu Hardy. I'm using the KDE version of Lenny.

Openbox takes a bit of work to install and set up, but in the end you'll have a very nice, light-weight, attractive, usable desktop.

For Lenny, I started out by installing the following packages from Synaptic (default repos):

- openbox (brought in libobparser21, libobrender21, openbox-themes)
- obconf
- obmenu (brought in libffi5, python-cairo, python-glade2, python-gobject, python-gtk2, python-numeric, python-support)
- fbpanel
- numlockx
- feh (brought in giblib1, libid3tag0, libimlib2)
- xscreensaver (brought in xli, xscreensaver-data
- xscreensaver-data-extra (brought in libnetpbm10, netpbm)
- xscreensaver-gl
- xscreensaver-gl-extra (brought in libgle3)
- menu, the app for the Debian menu, was already installed

Openbox doesn't come with its own panel; I had previously used pypanel, which is nice, but it wasn't in the default repos; so I went with fbpanel. fbpanel is cool, confiigurable, and comes with it's own menu, populated by the Debian menu package.

I found multiple Openbox entries to log into from my kdm log-in screen, including one titled "Openbox" and another titled "Openbox (Session)." The latter is the correct one to use, because the former does not reference any autostart script.

I installed xscreensaver so that I could use the GL Text (Clock) screensaver, a favorite of mine.

Instructions for using and configuring fbpanel were found in man fbpanel.

I used an autostart script (created ~/.config/openbox/autostart.sh) and a script that I'd found and tweaked that gives you an random wallpaper each time you log in (~/wallpaper.sh). The wallpaper.sh script uses photos from my ~/photos-openbox directory Here are the scripts I'm using:


~/.config/openbox/autostart.sh

# Programs to launch at startup

#numlock
numlockx &

#screensaver
xscreensaver &

# Programs that will run after Openbox has started
(sleep 2 && fbpanel) &

#My wallpaper (random wallpaper script)
./wallpaper.sh


~/wallpaper.sh

#!/bin/bash

WALLPAPERS="$HOME/photos-openbox"
ALIST=( `ls -w1 $WALLPAPERS` )
RANGE=${#ALIST[*]}
SHOW=$(( $RANDOM % $RANGE ))

feh --bg-scale $WALLPAPERS/${ALIST[$SHOW]}


I added an entry in the Openbox menu for wallpaper.sh so that I can manually change to a new (random) wallpaper whenever I feel like it.

I tweaked fbpanel -- changed the default menu icon, altered the clock's font color, etc.; and filled in the Openbox menu (which I prefer to use instead of the fbpanel menu) to my tastes, using the GUI ObMenu. Here's my Openbox desktop in Debian Lenny:



Simple, clean, and nice, just how I like it!

No comments: