Oct 102012

A while ago I decided that there is one particular module in a Maven-based NetBeans Platform application that I want to document properly with Javadocs, since it contains an API that other developers will (hopefully) use in future. And so I set out to find where the overview.html and package.html files should go. It turns out that it is actually very simple – just follow the same structure as for any Maven project! There is a very useful description of the structure available here.

Lesson learned: If you don’t find any useful information about some aspect of building Maven-based NetBeans Module projects specifically, the answer might very well just be a standard, generic Maven one. 🙂

Oct 092012

Sometimes it is useful to be able to visually separate groups of buttons on the main application toolbar. However, the NetBeans Platform doesn’t add separators to the toolbar by default as it is able to for the menubar. When I recently saw the question being posed again, I decided that it is time to find a way to accomplish this. And the key was in fact the NetBeans IDE 7.2 Plugin Quick Start tutorial. That tutorial describes how you can add other components besides buttons to the toolbar.

I followed the tutorial, but I didn’t create a panel. Instead I implemented the getToolbarPresenter() as follows:

public Component getToolbarPresenter() {
    JSeparator separator = new JSeparator();
    return separator;

That is it. Now I have a separator between two of the buttons on the toolbar.

Separator on the toolbar

Separator on the toolbar