Page 1 of 8 123 ... LastLast
Results 1 to 10 of 76

Thread: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

  1. #1
    Join Date
    Apr 2005
    Location
    Lancaster, PA
    Beans
    166
    Distro
    Ubuntu Breezy 5.10

    HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    Welcome to my Openbox guide. First, I must thank Fuscia, Stormy Eyes, benplaut the Gentoo and Ubuntu wiki pages. I plan to cover the installation and customization of Openbox as far as use and looks go. I am assuming that you have installed Ubuntu 6.06 with the full Gnome set up. If you are using Kubuntu, Xubuntu, or a server install, some things may change. I may or may not cover those areas. This guide will not cover how to integrate OpenBox into Gnome, KDE, or any other DE. Sorry if you find this a little (or a lot) verbose, but I hate reading guides that leave gaps. So, if I leave some gaps, let me know and I will try to fill them in.

    If you want a pure OpenBox installation without the requirement of Gnome, see here.

    For themes please see
    http://www.boxwhore.org/modules/news/
    http://hewphoria.com/?p=submission&type=theme&cat=7


    All of my instructions are based on using the command line.


    Installation:
    To install Openbox, all that is necessary is
    Code:
    sudo apt-get install openbox
    I recommend installing the themes, obconf, and pypanel as well.
    Code:
    sudo apt-get install openbox obconf openbox-themes pypanel
    Now you are ready to use Openbox. Log out, and at the login screen select Openbox under sessions.

    Upon entry into Openbox you are provided with nothing more than a mouse cursor. Right-clicking will bring up the root menu, and as you will see it is pretty minimal, but provides all that you need to go on (the terminal).



    Setting Up the Menu:
    The menu is the most important part of Openbox usability (in my opinion). The most basic way to edit the menu is to edit the menu.xml file. I will list three methods to edit the menu, which method you choose is up to you but I suggest checking out each method before actually editing the menu. In my opinion it is much easier to trim down a bloated menu than build up an empty menu. Thus, my reccomended method for seting up the Openbox menu is to run menumaker first and then use the XML or obmenu to trim it down.

    First, copy the default menu into your $HOME/.config/openbox directory.
    Code:
    cp /etc/xdg/openbox/menu.xml ~/.config/openbox/menu.xml
    *Important!* Every time you edit the menu, you must reconfigure by right-clicking to bring up the root menu and selecting reconfigure.

    A.) Edit the raw XML
    This method deals with editing the raw XML. Open the file by using
    Code:
    gedit ~/.config/openbox/menu.xml
    Here you can see how to format the XML to add entries. This is about as far as I'll go here, because there are much easier ways to edit the menu, but this method can be very fast.

    B.) Use obmenu
    The second method uses obmenu to edit the menu entries in a graphical interface. It is very easy to use and can create sub-menus and seperators. Obmenu must be installed from source, and has three dependencies that can be filled through apt/synaptic.

    The obmenu homepage is here: http://obmenu.sourceforge.net/index.html and the download page is here: http://obmenu.sourceforge.net/download.html

    1. To install the dependencies
    Code:
    sudo apt-get install python2.4 python2.4-glade2 python2.4-gtk2
    The glade and gtk2 parts might be wrong, but I am fairly certain they are correct.

    2. Now to install obmenu simply
    Code:
    tar xzvf ~/obmenu-1.0.tar.gz
    cd obmenu-1.0
    sudo python setup.py install
    3. Run obmenu
    Code:
    obmenu
    4. Add entries, save, and reconfigure.

    I suggest adding obmenu first, so you have easy access to it. Also add obconf as well if you installed it.

    C.) Use menumaker
    Menumaker is a tool that will generate a full menu of (almost) everything you have installed. Menumaker can be installed or run from the source tarball. I will show you how to use it without installing it.

    1. Download the latest version here: http://sourceforge.net/projects/menumaker and unpack it
    Code:
    tar xzvf ~/menumaker-0.99.7.tar.gz
    2. Go into the menumaker dir and run mmaker
    Code:
    cd ~/menumaker-0.99.7/
    ./mmaker OpenBox3
    3. Reconfigure

    Like magic, you have a new menu. Menu maker moves the reconfigure option into the OpenBox sub-menu. Now you have a pretty much fully working set up, but if you're like me, you want a clock, a panel, and a desktop bg, as well as some better looking themes.



    Setting the Background Image:
    This one is simple, install feh if you don't have it.
    Code:
    sudo apt-get install feh
    Then simply run
    Code:
    feh --bg-scale path/to/the/image.ext
    ex: feh --bg-scale ~/backgrounds/desktop.jpg

    Be warned that the image will reset when you log out and back in. I will cover this soon.



    Installing and Using Themes and Window Decorations:
    I will instruct you on how to install the exact theme and window decoration I use.

    Window decorations can be extracted to your .themes directory and changed in obconf.
    1. Download the clearlooks-olive theme from here http://hewphoria.com/get.php?t=theme&id=129 and save it to your home folder.

    2. Move the theme to .themes and extract it
    Code:
    mv ~/clearlooks-olive-0.2.tar.gz ~/.themes/clearlooks-olive-0.2.tar.gz
    tar xzvf ~/.themes/clearlooks-olive-0.2.tar.gz
    3. Open obconf (either from the menu or command line) and select Clearlooks-Olive from the list under Appearance.


    Now, to get rid of those nast GTK controls. This part is pretty easy too, but for some reason the themes installed with Gnome don't work for me, so you have to extract your own to .themes like above.

    1. Download the Olive Suite theme from gnome-look.org here http://www.gnome-look.org/content/do...ent=35572&id=1

    2. Move the theme to .themes and extract it, just like above but replace the file name.

    3. Install switch2
    Code:
    sudo apt-get install gtk-theme-switch
    4. Run switch2 and select Olive, apply.

    Now you should have a much nicer looking windows and control scheme for GTK apps.



    Installing and Using a Panel:
    If you haven't already, install pypanel. There are several other panels you can use, but pypanel is in the repos and easy to use.
    Code:
    sudo apt-get install pypanel
    To use pypanel, just run pypanel from the command line or add it to the menu. Pypanel can be configured through editing .pypanelrc found in your home directory.



    Getting Backgrounds and Panels to Show Up at Start:

    I originally used the .xsession method, but benplaut provided a much more generic way to go about it. This is pretty much verbatim what he outlined in here http://ubuntuforums.org/showpost.php...8&postcount=22


    First, make the file ~/.config/openbox/autostart.sh. In it modify the following to fit your needs.
    Code:
    gedit ~/.config/openbox/autostart.sh
    Panels usually cooperate better if you let them load after the WM, so this is a bit different from others.

    Code:
    #!/bin/sh 
    # Auto-mounting drives 
    # gnome-volume-manager & 
    # GTK themes... this is just one method 
    # gnome-settings-daemon & 
    # feh stores the last background in .fehbg 
    eval `cat $HOME/.fehbg` &
    pypanel & 
    # This prevents the panel from failing if it loads too fast 
    if pgrep pypanel 
    then exec openbox 
    else pypanel && exec openbox 
    fi
    *Rauble's note* I commented out gnome-volume-manager and gnome-settings-daemon. These are not necessary but can be very useful. If you cannot use CDs, uncomment the gnome-volume-manager line. For me, my extra harddrive and CD-ROM drives work without it. **

    Panels are finicky... the little thing at the end should help.

    OK, here's for gdm:

    First,
    Code:
    chmod +x ~/.config/openbox/autostart.sh
    Now, edit the session file:
    Code:
    sudo gedit /usr/share/xsessions/openbox-autostart.desktop
    and insert the following into the file:

    Code:
    [Desktop Entry] 
    Encoding=UTF-8 
    Name=Openbox Autostart 
    Comment=Openbox with autostart goodness 
    Exec=/home/dapper/.config/openbox/autostart.sh 
    Icon= 
    Type=Application
    Note: Edit the Exec line to match your user account

    finally,
    Code:
    sudo chmod +x /usr/share/xsessions/openbox-autostart.desktop
    (i'm not sure if that's required, but it can't hurt)

    Now you must restart and log into the OpenBox Autostart session
    Code:
    sudo reboot


    Using OpenBox Like a Pro:

    Stormy Eyes has a great how-to here: http://doc.gwos.org/index.php/Openbox_Gnome . It describes many things I have gone over, as well as how to add keybindings. I will leave his explaination be and just go over some extra stuff.

    Adding the following provides an easy way to capture screenshots.
    Code:
      <keybind key="A-F11">
        <action name="execute"><execute>gnome-screenshot</execute></action>
      </keybind>
    OpenBox has some great keybindings by default. Some of my favorites are the following:
    alt-F10 (A-F10): Maximize window
    alt-F5 (A-F5): Unmaximize window
    alt-F12 (A-F12): Roll up window
    ctrl-alt-left/right: switch to next/previous desktop
    shift-alt-left/right (S-A-Left/Right): switches and sends program to next/previous desktop
    ctrl-alt-d (C-A-d): show desktop (minimize all windows)

    You may also want menu entries for reboot and shutdown. Logging out of openbox has been finnicky for me, sometimes it just goes to a light blue, hard to see login screen. So, here are some menu entries to try:
    add a command for "sudo reboot" to restart the computer
    or "sudo shutdown -t now" to shutdown
    More info can be found here: http://enterprise.linux.com/article....1219226&tid=89



    Credits:
    (I basically compiled a lot of good information into one source that makes it easy for me to follow, hopefully it will be easy for new OpenBox users as well)

    Random Openbox Chatter

    Linux.xom | CLI Magic: shutdown - Using the command line for shutdown commands.

    OpenBox Gnome - Stormy Eyes' HOW-TO on configuring OpenBox on its own and with Gnome.

    Openbox - Ubuntu Wiki - Ubuntu's wiki entry, good info but some of the suggestions are not preferred by me (like using Rox-filer)

    Gentoo Openbox Entry - Some great technical info.


    *To be added*
    - Using and configuring idesk
    - Better use of docks and panels

  2. #2
    Join Date
    Jun 2005
    Beans
    177

    Re: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    Nice howto! =D> Just one suggestion:
    If you start gnome-settings-manager at startup, you can launch the Gnome theme manager by executing gnome-theme-manager. It's better than gtk-theme-switch (at least IMO) and also gives you control over icon themes.

  3. #3
    Join Date
    Apr 2005
    Location
    Lancaster, PA
    Beans
    166
    Distro
    Ubuntu Breezy 5.10

    Re: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    ah, excellent for pointing that out! i figured that was the key, but using switch2 still didn't work... i didn't think to use the Gnome switcher! i'll add that in later.

  4. #4
    Join Date
    Jun 2005
    Beans
    177

    Re: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    Oh, and one more thing: laptop users may want to add gnome-power-manager to their autostart script. If you run gnome-power-preferences after this you can check "Always display icon" to get a battery indicator on your pypanel (only need to check this once).

  5. #5
    Join Date
    Aug 2005
    Beans
    992

    Re: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    screenshots?

  6. #6
    Join Date
    Jun 2005
    Beans
    177

    Re: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    Here's one screenshot. Very minimalistic, but that's the reason I use OpenBox.

  7. #7
    Join Date
    Apr 2005
    Location
    Lancaster, PA
    Beans
    166
    Distro
    Ubuntu Breezy 5.10

    Re: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    http://ubuntuforums.org/gallery/show...riginal=1&c=13

    there is my screen. i'll fix up my first post later tonight or tomorrow.

  8. #8
    Join Date
    Apr 2005
    Location
    Not-So-Sunny Hawaii
    Beans
    Hidden!

    Re: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    i've got a bad feeling about the 'feh' line... i wouldve done it:

    feh --bg-scale `cat $HOME/.fehbg` &

    not sure what the diff is, tho.

    Tomorrow i'll write up something on configuring idesk... it's pretty easy, especially with idesktool.
    So... a 1337 java programmer walks into a bar...

  9. #9
    Join Date
    Jun 2006
    Beans
    30

    Re: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    what about one of those DOCK thingies that I've heard that you cand use with openbox? How do you install and configure it for openbox? Sry If I missed anything.

  10. #10
    Join Date
    Jun 2005
    Location
    Land of the Longleaf Pine
    Beans
    Hidden!

    Re: HOW-TO: Install, Customize, and Configure Openbox (lots of options)

    nice howto, dude. you may want to include instructions on how to get to openbox using startx (edit .xinitrc to say exec openbox). and you might want to have some links to some of the more hardcore minimal apps (dillo, links2, sylpheed-claws, etc.). i'm glad you warned everyone about the blank screen. somewhere on here, there is a thread of mine whining about openbox not working.
    Last edited by fuscia; June 10th, 2006 at 03:00 PM.

Page 1 of 8 123 ... LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •