Geertjan's Blog

  • September 16, 2006

How NetBeans Got My Bag Stolen

Geertjan Wielenga
Product Manager
Ever since blogging about Jazzy, the Java open source spell checker, yesterday, I've been totally engrossed in working on an HTML spell checker. I've been especially focused on extending the Output window, because that way the hyperlinks from wrongly spelled words are provided by the NetBeans Platform, instead of by me.

The best way of learning about this NetBeans API feature is to read the interview with Jens Trapp and to then download his open sourced HTML Tidy integration module for NetBeans IDE. In that module, he provides an extension to the Output window, where error messages generated by HTML Tidy are listed as hyperlinks which can be clicked, and then the cursor lands on the line where the problem is found. Perfect for a spell check integration module, one would think. And a nice way of learning about this aspect of the NetBeans APIs.

So, while traveling to the airport in Oslo this morning, while waiting to check in, while waiting to board the plane, and while flying to Prague, I was constantly working on this part of my spell checker. Here's the result so far, you can see in the upper right corner the Output window with links, while below that is just a plain old JEditorPane. The lower one is going to contain Strings with different colors for the different types of spelling errors. The upper one is really meant for navigating (would be nice if there were some programmatic way of positioning the Output window, or at least one document within it, up there, instead of in the very large Output window space at the bottom, because the wrongly spelled words are never going to need as much width as the Output window provides). This is what it all looks like:

Half way to Prague, somewhere over Germany, I guess, the hyperlinks suddenly appeared. That was because earlier I had only sent the StringBuilder, i.e., without the OutputListener, to the OutputWriter. Both are needed. However, the hyperlinks don't actually work yet. A lot of work to be done there still. So, anyway, by this time I had arrived in Prague and was still working on the problem while sitting near the conveyor belt waiting for my bag. But I kind of drifted off into my coding... and the next thing I knew the conveyor belt was deserted, everyone had left, and there were no more bags coming out. It is possible that my bag just got lost, but I suspect that someone just picked up my bag and took it with them, after noticing that the one person still hanging out there wasn't picking up the one bag that was still circling the conveyor belt...

Join the discussion

Comments ( 1 )
  • Carl Smith Wednesday, September 27, 2006
    Hi, on my Jframe I have a date selection.(A person must select a date). I would like a month calendar to be displayed in the drop down box. I would like to know how to call the JCalendar. When I open the JCalendar in the editor, I see coding. I copied it to my palette window. When I look at the copy in the palette window, it is empty. How do I make the JCalendar pop up when i go to my date selection.
Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.