<p>This attribute is a visible attribute that displays documentation when
configured by double clicking on it or by invoking Configure in the context
menu.
</p><p>
The method
that causes the documentation to be displayed is createEditor, which
is normally used to configure an attribute. This means that the
DocumentationAttribute can't be configured. That is, if a
double-click occurs or the Configure menu item is selected the
documentation will be displayed, and the normal configure dialog
will not be offered. Special provisions for "configuring" a
DocumentationAttribute are described below.
</p><p>
The documentation is in a file specified by the FileParameter
attribute with the name _documentation. The _documentation FileParameter can
be on any object, including this DocumentationAttribute, in the containment
hierarchy. (As explained below, the _documentation FileParameter will be
found on the container of this DocumentationAttribute.) If a
_documentation FileParameter can not be found a JFileChooser is
presented. The resulting selection, if there is one, is then used
to create a _documentation FileParameter on the <i>container</i>.
There are two reasons for this. First, the documentation most likely
applies to the container. I.e., this DocumentationAttribute isn't
being documented, rather, the thing that this DocumentationAttribute
is an attribute of is being documented. Second, the container most
likely can be configured in the normal way. Since, the
_documentation FileParameter will be on the container the
specification for the file containing the documentation can be
modified.
</p>
<p>Note that if a DocumentationAttribute refers to a pdf file, then it
may not be possible to view the pdf file in an applet because
<a href="../../../../ptolemy/actor/gui/BrowserLauncher.xml">ptolemy.actor.gui.BrowserLauncher</a> uses reflection to look up
classes. The workaround is to use
ptolemy.vergil.pdfrenderer.PDFRenderer
Rowland R Johnson
$Id: DocumentationAttribute.java 70402 2014-10-23 00:52:20Z cxh $
Ptolemy II 4.0
Red (rowland)
Red (rowland)