Geertjan's Blog

  • May 14, 2010

Things To Do In Berlin When You're Waiting For A Train

Geertjan Wielenga
Product Manager
It was 3AM this morning on the return trip from Poznan to Prague, which required a 5 hour lay over in Berlin. So around 3AM I found by accident that the 24-hours McDonald's at Berlin Ostbahnhof has a power point in one of its corners so that I could plug my laptop into it and via TMobile get on-line. (Though greatful for this accidental service, I still avoided partaking of McDonald's dubious cuisine.) Where I found this question on oreilly.com and cobbled together a fresh plugin, uploading it to the Plugin Portal right before my train continued its journey at 4:57:


The process was simple: find, in the NetBeans sources, the package containing the code for the Window Component wizard, copy it into your own new fresh module, tweak it, and voila:

It's not really a non-GUI window, of course, but a non-Matisse window. But let's agree to not quibble and split hairs at 3AM, OK. When you use the template above, you get exactly what you'd normally get, except no ".form" file, nor the code referencing it, i.e., the "initComponents()" is removed from the generated ".java" file.

A future version of NetBeans IDE should have the above functionality integrated into the Window Component wizard, i.e., when you create a new window, you should be able to specify whether Matisse support should be provided.

Join the discussion

Comments ( 2 )
  • Jesse Glick Friday, May 14, 2010

    I don't think this should be an apisupport template. There are any number of templates for GUI-oriented things, not just in apisupport, and they all create GUI builder forms; it would be unwieldy to provide alternates for all of them. Anyway you would need to decide and understand in advance that you did not want to use the GUI builder.

    Rather, any GUI builder form should have an option visible somewhere in the UI to "debuilderize" it: delete the \*.form file and remove guards in the \*.java. (You can of course do this in an external editor by hand.)

    The UI would of course have to warn you that the conversion should be considered irreversible. (There are experimental tools to reconstruct a \*.form for a hand-edited GUI class, though most people would be using JGoodies Forms or MiGLayout, neither of which the NB GUI builder supports.)

  • Geertjan Sunday, June 20, 2010

    "debuilderize" would be great!

Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.