|
From: Tom G. <gu...@ac...> - 2001-11-21 16:43:40
|
Goog Job on the plugin.
It is what I had in mind as a macro...
The picture in my head was a dialog that would pop up much
like your option pane. (I never got there obviously)
As far as the footers and headers.
Add a sub option pane to hold the text areas to edit them.
Add a few JTextArea components with some default html onto
the option pane. (header, footer, title , bottom)
To get a preview of the html....
Create a new MouseMotionListener and add it to the JTextArea for
each (header, footer...).
/************ Cut and paste code *************/
StringBuffer header = new StringBuffer("<B><A href=");
header.append("http://www.myproduct.com");
header.append(">MyProductName</A></B>");
header.append("<BR>Version xx.xx.xx");
// Format the current time.
java.text.SimpleDateFormat formatter
= new java.text.SimpleDateFormat ("yyyy.MMMMM.dd 'at' hh:mm:ss zzz");
java.util.Date currentTime_1 = new java.util.Date();
String dateString = formatter.format(currentTime_1);
header.append("<BR><font size=-1>");
header.append(dateString);
header.append("</font>");
JTextArea myHeaderJTextArea =
new JTextArea(header.toString());
MouseMotionAdapter myMouseMotionListener = new MouseMotionAdapter()
{
public void mouseMoved(MouseEvent e)
{
myHeaderJTextArea.setToolTipText("<html><BODY>"+
myHeaderJTextArea.getText() + "</body></html>");
}
};
myHeaderJTextArea.addMouseMotionListener(myMouseMotionListener);
/************ Cut and paste code *************/
When the mouse is moved over the text area the listener updates
the ToolTipText for the JTextArea to the actual text
from the JTextArea.
JToolTips render html!!!
When you float your cursor over the area a html popup will preview
the header or footer.
Other doclets
There aren't alot out there. And *most* Others I have seen produce html
When this is included, probably a seperate option page for each
doclet type. The one you already have would be under the
standard doclet.
tom
doug b wrote:
> i actually started working on a simple conversion of
> Tom's macro to a plugin. i'll attach what i've done
> so far since i'll be out on vacation for the next
> couple of weeks. don't expect too much, but the
> framework is there in case someone else wants to pick
> at it.
>
> so far, i've implemented the basics for "standard"
> javadoc. i haven't done the Bouvard & Pecuchet stuff,
> and i've left out some of the configurable options for
> now (like header, footer, etc.)
>
> it would be nice if the custom doclet support could be
> implemented with some sort of "add" process off the
> option pane. the user would specify the class name,
> jar file, and whatever else for each desired doclet
> implementation. unfortunately, i don't know enough
> about these other doclet environments to know whether
> or not that's feasible. maybe it's ok to just
> hardcode the major ones... also, i was thinking the
> headers/footers could be specified as HTML files to
> embed, but that was just an idea. eventually, some of
> these things should probably be tied to the
> project/session plugin, but i ramble...
>
> btw, the plugin version isn't noticeably any faster
> than the macro. the majority of the time seems to be
> in the spawning and starting the external javadoc
> process. oh, for the upcoming "callable" interface to
> javadoc...
>
> --- John Gellene <jge...@ny...> wrote:
>
>>JavaDoc pluginI'm not aware of anyone actively
>>developing a plugin based on
>>this macro. If someone is, I trust he or she will
>>speak up. It would make
>>a nice contribution to the project.
>>
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! GeoCities - quick and easy web site hosting, just $8.95/month.
> http://geocities.yahoo.com/ps/info1
>
--
--------------------------------------------------
Tom Gutwin P.Eng. Acterna
Sr. Developer t.g...@ie...
--------------------------------------------------
|