I've been playing around with a couple of approaches to see what gives the best results. There are three basic approaches I've been trying.
- Set the icon to a 1x1 transparent pixbuf. It works but you still have the awn-effects related padding around it taking up several more horizontal pixels.
- Use awn_draw_set_window_size() and set the dimensions to 0x0. If you do this you also need to combine with method 1. This seems to convince awn-effects to remove the buffer pixels... so the overall results are better. It seems to end up using 1 pixel.
- Just calling gtk_widget_hide() on the applet object itself seems to have similar results to 2. There is still a visible movement in the bar when the applet is completely removed, even when it is hidden.
If you don't feel like messing around with the awn-effects stuff my suggestion is that method 3 appears to work relatively well by itself.
I would still like to have the ability to hide an applet icon in such a way as to have no visible movement in the bar when the applet is removed. If anyone has thoughts on how to do this please leave a comment. thanks.