Ubuntu desktop magic

There are several things I really like about my Ubuntu installation, but there is some fantastic usability thing I did set up after a while and I don't want to keep it from you:

The common way
Most probably you will start your machine once or twice a day, coming up with a fresh desktop. You will start Firefox, Pidgin, Thunderbird, probably Songbird for the music, Nautilus to do some file actions and maybe open a terminal window. You'll show and hide them, close and reopen them. Some application windows will remember their position and sizes, some won't. During your session you'll feel the need to resize windows, move them, hide them or even put them to another workspace. Usually your application window won't stay on in the same place with the same size for a long time. We're used to those procedures because we did that way since we use window managers. But they take time and clicks. If we search an application we have to look in the window list or use the window switcher to identify and show it. If we bring all that to mind we realize that this is a bit of pain.

What if...
So what if we could fill the desktop with the basic applications automatically. And what if we put them on a default position with a default size on a default workspace, so we don't feel the need to move, resize, show or hide anything at all. All which is left is switching the workspace. And we'll know exactly where to find a application window because it stays always in the same place.

How to do it
On my Gnome desktop I set up six workspaces. On the first one I put Firefox, Skype and Pidgin, the second one has Thunderbird on it, the third one is clean ( to run free), the fourth shows two Nautilus windows of the same size side by side ( yeah, i like orthodox file managers), the fifth runs two terminals and on workspace six Songbird plays the music. All those applications are startet and put into position by a script, which I linked on my Desktop. All it needs is the package wmctrl. Here's the scripts source. Have fun!


#! /bin/sh

# start on workspace 0
wmctrl -s 0

# start firefox with a default page and go on
firefox "http://de.indymedia.org/index.shtml" &
{
    # wait for firefox to start
    sleep 20s

    # resizing and positioning
    wmctrl -r Firefox -e 0,10,40,1090,700

    # set a custom window title
    wmctrl -r Firefox -T "Ich trinke ein Getränk und esse ein Geäst und sing..."

    pidgin &
    skype &
    {
        sleep 20s
        wmctrl -r Buddy List -e 0,1120,40,140,700
        wmctrl -r Skype -e 0,875,40,225,400
        wmctrl -s 1

        thunderbird &
        {
            sleep 10s
            wmctrl -r Thunderbird -e 0,10,40,1250,700

            wmctrl -s 3
            nautilus &
            {
                sleep 3s
                wmctrl -r File Browser -e 0,10,40,620,700
                wmctrl -r File Browser -T "Soll"
                
                nautilus &
                {
                    sleep 3s
                    wmctrl -r File Browser -e 0,645,40,620,700
                    wmctrl -r File Browser -T "Haben"

                    wmctrl -s 4
                    gnome-terminal &
                    gnome-terminal -e "sudo -i" &
                    {
                        sleep 4s
                        wmctrl -r matze -e 0,10,40,620,700
                        wmctrl -r root -e 0,645,40,620,700
                        
                        wmctrl -s 5
                        Apps/Songbird/songbird &
                        
                        {
                                sleep 15s
                                wmctrl -r Songbird -e 0,10,40,1250,700
                        }
                    }
                }
            }
        }
    }
}

 

Bookmark this page
General Tags: 
General category: 

ad ubuntu linux

Greenpeace Energy

www.lobbycontrol.de