DhStyleBase | +--DhElement | +--DhTextpublic class DhText
Represents static text in an HTML document. This element is displayed in one of two modes: freely formatted (the default) or honor white space. The latter means that all white space (including carriage returns) is maintained.
Constructors
Name | Description |
---|---|
DhText() | Creates a DhText object. |
DhText( String text ) | Creates a DhText object. |
Methods
Name | Description |
---|---|
getRespectSpace() | Determines if this element currently honors white space. |
getText() | Retrieves the text this element currently displays when rendered. |
hasDefaultText() | Determines if there is text in the object. |
setRespectSpace(boolean f) | Sets the text format either to honor white space or to be freely formatted. |
setText( String s ) | Sets (or resets) the text to display in this element. |
Creates a DhText object.
Creates a DhText object. For one-step construction, the text parameter is what is displayed in this element.
Returns true if white space is honored; otherwise, returns false.
Determines if this element currently honors white space.
Returns the text this element displays.
Retrieves the text this element currently displays when rendered.
Returns true if there is no text; otherwise, returns false.
Determines if there is text in the object.
Sets the text format either to honor white space or to be freely formatted.
Sets (or resets) the text to display in this element.