Oracle Blog

Random NetBeans Stuff

Adding a Visual Tab to the NetBeans Java Editor

With the upcoming NetBeans Platform 7.1, because of the new ability to add tabs to existing file editors, you'll be able to do this, i.e., you'll be able to add tabs to a file editor "from the outside", via a new plugin that you've created yourself:

What you see above is a new tab in the Java editor, containing a LabelWidget from the Visual Library for each method found in the Java class.

Here's the code and, again, note that this will work in NetBeans Platform 7.1 (i.e., a download of a recent trunk build) only:

About

Geertjan Wielenga (@geertjanw) is a Principal Product Manager in the Oracle Developer Tools group living & working in Amsterdam. He is a Java technology enthusiast, evangelist, trainer, speaker, and writer. He blogs here daily.

The focus of this blog is mostly on NetBeans (a development tool primarily for Java programmers), with an occasional reference to NetBeans, and sometimes diverging to topics relating to NetBeans. And then there are days when NetBeans is mentioned, just for a change.