I'd like to make the background of a Gtk+ window transparent so that only the widgets in the window are visible. I found a few tutorials:
http://mikehearn.wordpress.com/2006/03/26/gtk-windows-with-alpha-channels/
http://macslow.thepimp.net/?p=26
But they both appear to listen to the "expose" event, and then delegate to Cairo to do the rendering. This means that other widgets added to the window are not rendered (for example, I've tried adding a button to the window as well).
I see that there's a method modify-bg on GtkWidget: http://library.gnome.org/devel/gtk/stable/GtkWidget.html#gtk-widget-modify-bg
However, GdkColor does not appear to accept a parameter for transparency: http://library.gnome.org/devel/gdk/stable/gdk-Colormaps-and-Colors.html
I've tried the GtkWindow.set_opacity method as well, but this sets the opacity for the window contents as well, which is not what I want.
I'd appreciate any guidance anyone can provide in this.