Why I Disabled NetBeans’ Code Completion Feature

NetBeans code completion

One of the nice things about NetBeans – well okay, one of the nice things about any modern IDE for any programming language these days – is the automatic code completion feature. The way it works is that as you type, the system checks what you’ve typed against a data dictionary of class and method names, deduces what you obviously meant, and then – if there’s only one possibility – fills it in for you. As is more usual, if there are several possibilities, the system pops up a little window, in which you can select which possibility to go with. If there’s JavaDoc available, this is shown too. It’s neat.

But it can also be a real pain in the neck!

If my current project has reached anything like a respectable size, the code completion results are never instantaneous. More often than not, the completion window will pop up, but all I’ll see is a “Please Wait...” message as it searches libraries, jar files, other projects that happen to be mounted... whatever’s currently in the classpath.

So I wait a few seconds... and, often, wait a few seconds more. By the time it’s ready, I could have manually typed the complete line several times over. And this is on a speedy, 3Ghz PC with 2GB of RAM.

Often, I just grow frustrated with waiting, and press ESCape to dismiss the completion window. But then, when I continue typing, the window soon reappears; so I hit ESCape to clear it again; and so on.

It very quickly becomes second nature to tap the ESCape key while typing to clear the useless completion window with its eternal “Please wait...” message; it’s rather like absent-mindedly swatting away a pesky fly every few seconds. It’s annoying, but your subconscious soon assumes responsibility for the task, so your conscious mind can just keep on thinking and typing.

However, when I’m really motivated on some programming task or other, and coding rapidly like a crazy person, being repeatedly told to “Please Wait...” is utterly contrary to my frame of mind at that moment.

In fact, I soon grew so frustrated with this aspect of NetBeans’ UI, that I delved into the deeper abyss of its multi-layered options system and disabled the auto-completion window altogether. I felt a tad guilty doing this, as I felt as if I was rejecting a really cool feature.

But I can still bring the completion window up manually by pressing Ctrl-Space, should I have the urge to stare at a “Please Wait...” message for a while.

About the Author

Matt Stephens is a senior architect, programmer and project leader based in Central London. He co-wrote Agile Development with ICONIX Process, Extreme Programming Refactored, and Use Case Driven Object Modeling with UML - Theory and Practice.

Featured

Most   Popular
Upcoming Events

AppTrends

Sign up for our newsletter.

Terms and Privacy Policy consent

I agree to this site's Privacy Policy.