I've been bugged by the ugly icon for Skype ever since I started using it. This bothering was especially caused by the fact that I don't even use the Skype interface because I use the skype4pidgin plugin to use my Skype.
Most common window managers/panel applications have the option to hide icons from the system tray, but openbox/tint2 doesn't (at least for as far as I am concerned). I learned about xdotool and found an interesting section in the man pages. Using this information I've found a possibility to hide Skype. More about the tricks I used will be explained below.
The 'Window commands'
xdotool has got some excellent commands to get information about the windows that your window manager is serving. It can also manipulate these windows, by for instance resizing them. The manipulation action that was used in my solution is 'windowunmap', which unmaps the window from your Window Manager. The Skype interface will not be accessible after it is unmapped, so to access it again, you'll have to disable the script (following below) and restart Skype.
More information about the available window commands can be found here.
I've created the following script in
#!/bin/bash # Hide all skype-related windows by unmapping them :D # by Bas Dalenoord, mijn.me.uk for LINE in $(xdotool search --class skype); do $(xdotool windowunmap --sync $LINE) done
Make the script executable and you can hide your Skype by simply running the script. I don't like to have to call the script manually every time Skype is started, so below follows a way to automate this.
To hide Skype when it starts you'll have to modify
/usr/bin/skype. Make sure to back it up as I am not responsible for messing up your installation.
/usr/bin/skype AS ROOT in your favourite text editor
sudo nano /usr/bin/skype
Add a question mark after the line that states:
exec "$LIBDIR/skype/skype" "$@"
So it will look like this:
exec "$LIBDIR/skype/skype" "$@" &
Add the following two lines to the file:
Save the file and you are ready to go. Start (or restart) Skype to see the effects.
I am not responsible for any problem with your installation caused, being it directly or indirectly, by the steps/scripts above. Feel free to ask questions in the comments.
To use the script above, you need a working installation of
xdotool for your distro. I've tested this on Arch Linux running OpenBox and I can not assure proper functioning of the script on other setups, even though I am quite certain it should work in most cases.
Copyright (c) 2012 by Bas Dalenoord, mijn.me.uk. All rights reserved.