Class HTMLText

  • All Implemented Interfaces:
    java.lang.Cloneable, HasTypeConstraints, Typeable, Changeable, Debuggable, DebugListener, Derivable, ModelErrorHandler, MoMLExportable, Moveable, Nameable, Settable, ValueListener, WebExportable

    public class HTMLText
    extends WebContent
    Attribute for inserting HTML text into the page exported by Export to Web. Drag its icon onto the background of a model, and specify the HTML text to export (double click on the attribute to set the text). By default, this text will be placed before the image for the model, after the title, but you can change the position by setting the textPosition parameter. You can also separately control what text is displayed in the model, or make the attribute disappear altogether in the model (for this, just set displayText to an empty string).
    Since:
    Ptolemy II 10.0
    Version:
    $Id$
    Author:
    Edward A. Lee
    Pt.AcceptedRating:
    Red (cxh)
    Pt.ProposedRating:
    Red (cxh)
    • Field Detail

      • textPosition

        public HTMLTextPosition textPosition
        Parameter specifying the position into which to export HTML text. The parameter offers the following possibilities:
        • end: Put the text at the end of the HTML file.
        • header: Put the text in the header section.
        • start: Put the text at the start of the body section.
        • anything_else: Put the text in a div of this name.
        The default is "start".
    • Method Detail

      • getMimeType

        public java.lang.String getMimeType()
        HTMLText is of type text/html.
        Returns:
        The string text/html
      • isOverwriteable

        public boolean isOverwriteable()
        Return true, since new content should overwrite old.
        Returns:
        true, since new content should overwrite old