Sunday, April 6, 2008

Net Beans 6.1 Beta

After trying so many IDES starting from AdventNet Bean Builder, Emacs, GVIM, Eclipse & Netbeans, I now find the Net Beans more convenient for my development. Recently I downloaded the NetBeans 6.1 Beta. One thing I like most, is the improved Java Script support. Code completion is more relevant now in 6.1 Beta than in 6.0.1. One other thing I liked is the comment section. Previously when I type enter after opening a comment section with a forward slash followed by two stars (/**) a new line with a star followed by a space (* ) will be added by default. It will look like below.




Cursor will be at the position of the hypen in the above line. If I need to close that comment section, I need to type a backspace and a backslash.

Now in 6.1 Beta if I open a comment section and type enter, the comment section will be completed by default, with some intelligence.

1) If a comment section is opened for anything other than class definition or method definition (one exception to this is a method definition with no arguments and which returns void), it is completed as below and the cursor stays at the position of the hypen.




2) If a comment is opened for class definition, it is completed as below.




If a comment is opened for method definition, it is completed with little more smartness.

3) For a method which takes no arguments and returns an object, comment section is closed as





4) For a method that takes some arguments and returns anything but void, comment section is closed as below.




It is something that is not much to do with any functionalities but is a cool function that caught my interest.

Apart from these, one thing I haven't figured out yet is the collapse and expand code. It is not working as it was in 6.0.1. When you start editing the code, suddenly, the collapse / expand is not functioning. When I close the IDE and start again collapse / expand is back. I guess there is something to be fixed. Let me hope for the fix soon.