![]() |
ubuntu.com - launchpad.net - ubuntu help
|
|
|||||||
|
Tutorials & Tips The place to find Ubuntu related Tips & Tricks. |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
May the Ubuntu Be With You!
![]() Join Date: Apr 2005
Location: Under the Jolly Roger
Beans: 1,564
|
How to use Openbox in GNOME and by itself.
Introduction
Metacity, while a fair default, is not the only window manager you can use with GNOME. Openbox is a lightweight, customizable window manager that works either by itself or as a drop-in replacement for Metacity. Its advantages include the ability to switch desktops with the mouse wheel, a built-in, customizable menu that allows stand-alone operation with some GNOME components in order to build a GNOME-like system on low-end gear, and (this is subjective) better looking, cleaner themes that don't depend on resource-intensive pixmaps. Installation and Basic Usage If you have the Universe repository, all you have to do to install Openbox is enter a command: Code:
sudo apt-get install openbox obconf
Code:
openbox --replace
Installation and Selection of Themes Now that you have Openbox running, you'll probably need some themes. I can help you with that, being an Openbox fan. But first, I should tell you how to obtain, install, and select themes. Once you have downloaded a theme to your home directory, open a terminal and enter the following commands (This example assumes you've downloaded Mistodon to $HOME): Code:
cd ~/.themes tar xzvf ~/mistodon.tar.gz Theme List and Links The following list names themes I've made available to the public, with screenshots and descriptions. As other users provide links to their themes, I will post them after my list.
Forum member Smoon has his own theme page. It's written in German, but the screenshots provide adequate explanation. Also, boxwhore.org hosts Openbox themes with screenshots. (No, I didn't pick the name.) More importantly, the developers/maintainers of Openbox provide documentation at this location. It covers the basic operating principles, though it doesn't offer in-depth coverage on how to theme Openbox. I may provide a section on advanced theming later on. Since Openbox does not handle setting wallpapers, you have to use external tools. I recommend feh, which is primarily an image viewer but includes "set wallpaper" functionality both in its menu and as a commandline tool. Fun with Keybindings; or, getting an ALT+Tab that rocks like ninja. Openbox's default ALT+Tab functionality is a bit limited compared to Metacity, which shows a dialog listing all the open apps on a given workspace similar to Windows. You don't have to settle for Openbox's anemic ALT+Tab. If you're using Openbox, try middle-clicking anywhere on your desktop. You'll see a menu listing each of your workspaces, starting with the first, and each workspace entry will have a submenu displaying the running windows on that workspace, with iconified (minimised) windows in brackets. It's also possible to bind this menu, which is referred to internally as the "Client List Menu", to any key you like, and then to navigate that menu with your keyboard's arrow keys. Just follow the steps below. 1. Open a terminal and enter the following command: Code:
gedit ~/.config/openbox/rc.xml Code:
<keybind key="A-Tab">
<action name="NextWindow"/>
</keybind>
<keybind key="A-S-Tab">
<action name="PreviousWindow"/>
</keybind>
Code:
<keybind key="A-Tab">
<action name="ShowMenu"><menu>client-list-menu</menu></action>
</keybind>
<keybind key="A-S-Tab">
<action name="ShowMenu"><menu>client-list-menu</menu></action>
</keybind>
5. If you're using Openbox as part of GNOME, and Openbox is part of your GNOME session, then typing killall openbox at the terminal should cause GNOME to restart Openbox for you. If GNOME won't play ball, you should be able to click on the Applications menu, select "Run Application", and type "openbox" into the prompt. Or, you could avoid all this by logging out and logging in again. If you're using Openbox on its own, then right-click on the desktop for the main menu, and choose the Reconfigure option. Openbox will reread its config file. By following the above steps, you've modified the keybindings for ALT+Tab and SHIFT+ALT+Tab to bring up the same client list menu that appears when you middle-click on the desktop. You can navigate it using your arrow keys, and press "Enter" to go to a running app, even if that app is on a different workspace. More Fun with Keybindings; or, opening apps without reaching for the rodent. So, are you tired of having to take your hands off the keyboard in order to open a program? I can help you with that too. The principles are the same as when you modified your config, (~/.config/openbox/rc.xml) to give you a sweet ALT+Tab. Open your config file as explained in "Fun with Keybindings; or, getting an ALT+Tab that rocks like ninja." and do the following: 1. Find the line that reads "<chainQuitKey>C-g</chainQuitKey>". Create a blank line between this keybinding and the next. 2. If you're using GNOME or have gnome-panel running in Openbox, paste the following XML: Code:
<keybind key="A-F1">
<action name="execute"><execute>gnome-panel-control --main-menu</execute></action>
</keybind>
<keybind key="A-F2">
<action name="execute"><execute>gnome-panel-control --run-dialog</execute></action>
</keybind>
If you aren't using GNOME or gnome-panel, but want a "Run Program" dialog, then run sudo apt-get install gmrun from a terminal. Once you've installed gmrun, paste the following XML into the editor at the blank line you created in step 1: Code:
<keybind key="A-F1">
<action name="ShowMenu"><menu>root-menu</menu></action>
</keybind>
<keybind key="A-F2">
<action name="execute"><execute>gmrun</execute></action>
</keybind>
3. Save your changes, close the editor, and restart Openbox. Even More Fun with Keybindings: Switch to a Specific Desktop It's possible to configure keybindings in Openbox to allow you to switch to a specific desktop. For the purpose of this demonstration, I'll show you how to use ALT+1 to switch to desktop 1, ALT+2 to switch to desktop 2, etc. Just paste the following code into your ~/.config/openbox/rc.xml file's <keyboard> section, save, and restart Openbox: Code:
<keybind key="A-1">
<action name="Desktop"><desktop>1</desktop></action>
</keybind>
<keybind key="A-2">
<action name="Desktop"><desktop>2</desktop></action>
</keybind>
<keybind key="A-3">
<action name="Desktop"><desktop>3</desktop></action>
</keybind>
<keybind key="A-4">
<action name="Desktop"><desktop>4</desktop></action>
</keybind>
Caveat 0: When running Openbox by itself, running Nautilus without the --no-desktop option will cause Nautilus to take over the desktop, trashing your wallpaper and rendering your menu inaccessable. Keep this in mind when hacking your menu. Caveat 1: This HOWTO may not work with Fluxbox due to possible incompatibility with the EWMH specs and definite lack of a --replace switch. Also, their config and menu file structures are not XML-based.
__________________
My sole duty is to my own happiness and well-being. I recognize no other. Last edited by Stormy Eyes; October 14th, 2005 at 08:45 AM.. |
|
|
|
|
|
#2 |
|
5 Cups of Ubuntu
![]() |
Re: How to use Openbox in GNOME and by itself.
will this work on fluxbox?
|
|
|
|
|
|
#3 |
|
Just Give Me the Beans!
![]() Join Date: Sep 2005
Beans: 49
Ubuntu Breezy 5.10
|
Re: How to use Openbox in GNOME and by itself.
It depends how fluxbox is compliant with freedesktop wm-spec! If not you can have problems with panels and virtual desktops.
|
|
|
|
|
|
#4 | |
|
May the Ubuntu Be With You!
![]() Join Date: Apr 2005
Location: Under the Jolly Roger
Beans: 1,564
|
Re: How to use Openbox in GNOME and by itself.
Quote:
1. I don't know if Fluxbox is EWMH-compliant. 2. I do not use or recommend Fluxbox because I consider it slow and clunky.
__________________
My sole duty is to my own happiness and well-being. I recognize no other. |
|
|
|
|
|
|
#5 |
|
5 Cups of Ubuntu
![]() Join Date: Aug 2005
Beans: 16
|
Re: How to use Openbox in GNOME and by itself.
Instead of executing
Code:
openbox --replace
Code:
export WINDOW_MANAGER="/usr/bin/openbox" Next time you log into Gnome, openbox will be managing your windows. |
|
|
|
|
|
#6 |
|
Just Give Me the Beans!
![]() |
Re: How to use Openbox in GNOME and by itself.
Anyone know what happened to the theme links? I can't seem to get to the starbreaker server. Does anyone else have the themes to post somewhere?
|
|
|
|
|
|
#7 |
|
Just Give Me the Beans!
![]() Join Date: Apr 2005
Beans: 26
|
Re: How to use Openbox in GNOME and by itself.
I'm not sure about those links but I've found a really nice theme, a port of clearlooks. It can be downloaded at http://hewphoria.com/?p=themes&id=127 .
|
|
|
|
|
|
#8 |
|
Dipped in Ubuntu
![]() Join Date: Oct 2004
My beans are hidden!
Ubuntu Karmic Koala (testing)
|
Re: How to use Openbox in GNOME and by itself.
When I was playing with openbox I noticed obconf would also launch when you go Preferences->Windows (going from memory).
I think having the other->obconf entry becomes a waste?
__________________
The idea of copyright did not exist in ancient times, when authors frequently copied other authors at length in works of non-fiction. This practice was useful, and is the only way many authors' works have survived even in part. -- Richard Stallman |
|
|
|
|
|
#9 | |
|
May the Ubuntu Be With You!
![]() Join Date: Apr 2005
Location: Under the Jolly Roger
Beans: 1,564
|
Re: How to use Openbox in GNOME and by itself.
Quote:
__________________
My sole duty is to my own happiness and well-being. I recognize no other. |
|
|
|
|
|
|
#10 | |
|
May the Ubuntu Be With You!
![]() Join Date: Apr 2005
Location: Under the Jolly Roger
Beans: 1,564
|
Re: How to use Openbox in GNOME and by itself.
Quote:
__________________
My sole duty is to my own happiness and well-being. I recognize no other. |
|
|
|
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|