Hypercyber...   Steal this incremental menu      Java?

Steal this incremental menu!
A drop-in incremental menu in JavaScript.

One thing that really sucks about Java programming is the keyboard-unfriendly user interface to the normal "javadoc"-generated documentation. To look up a class in the HTML documentation, one scrolls to the class name in a long list of links in a frame, then clicks on that. Scrolling is a lousy user interface; it requires much more hand-eye coordination than typing.

So, I decided to build something in JavaScript that you could drop into a javadoc-generated file to make it an incremental menu. To my great surprise, it turned out to be possible.

The source: incremental-menu.txt (a JavaScript fragment)

Demo: steal-this-incremental-menu-demo.html

Works with:

Netscape 4.76 on Windows.
Netscape 6.1 on Windows (slow)
Internet Explorer 5.50 (slow)
The "slow" part is at startup - the script compiles an array of strings for it to index when searching, and the old Netscape made that a lot easier than the new one. I'm hoping that this might be acceptably slow on modern systems with fast processors.

If you can verify that it runs on other systems, or you can suggest changes to the code to make it run on other systems, or speed it up on those that it is slow on, or some other interesting modifications, send me e-mail at <jutta@pobox.com>.

To install:

  1. Find the allclasses-frame.html file that's part of the documentation you want to turn into an incremental menu.
  2. Download the source, and copy ("yank") it into a buffer.
  3. Paste it into the allclasses-frame.html's <HEAD> element, and save.


This was my first larger JavaScript program, and I sincerely hope it will be my last. What a nightmare of incompatibilities, bugs and special cases. Peter-Paul Koch's W3C DOM Compatibility Table saved me much time and quite possibly my sanity.

Other Sources

JavaDoc is very modular and flexible; there are other documentation systems that build on top of that. If you've got a favorite that you would like listed, send me email at <jutta@pobox.com>.

Native javadoc integration for the Emacs JDE

Bouvard & Pècuchet
A javadoc extension generates database files that can be viewed by a special browser.


You can modify or copy this for any use, commercial or private, free of charge, but leave my copyright notice in my part of the code, and don't claim I wrote something I didn't.


Nov 5, 2001 - added "other sources" section.
Oct 30, 2001 - initial publication.

(c) Jutta Degener, 2001. Neither Sun nor the TU Berlin know about, care about, or endorse this page. Sun and Java are trademarks of Sun Microsystems Inc.