Make the Swing code play nice with tools like WindowBuilder.

This enables us to work with the Swing code in plain Java and still preview and edit the GUI in a Swing designer tool. (there may be other tools than WindowBuilder able to do this, I don't know.)