How do I get the Window ID of a GtkWindow? [GTK 2.x]

The actual Gdk/X window will be created when the widget gets realized. You can get the Window ID with:

#include <gdk/gdkx.h>

Window xwin = GDK_WINDOW_XWINDOW (GTK_WIDGET (my_window)->window);