There is a pretty common thing that various applications do now, generally touted as a major feature, such as "tabbed browsing" or "single-window chat" or whatever. Basically applications start out like this:

and then at some point later they do this:

I have been spending some of my spare time messing around with PyGTK, so here is some sample code in Python which does this thing.