getCharacterFormat
getCharacterFormat(selection: Boolean; faceName: String output; size: Real output; color: Integer output; bold: Integer output; italic: Integer output; strikethru: Integer output; underline: Integer output);
The getCharacterFormat method of the JadeRichText class retrieves common character formatting attributes of the receiver.
The method parameters are listed in the following table.
Parameter | Description |
---|---|
selection | Specify true to get the character format of any selected text, or if no text is selected, of the insertion point and specify false to get the default character format of the control |
faceName | Obtains the value of the selFontName property |
size | Obtains the value of the selFontSize property |
color | Obtains the value of the selTextColor property |
bold | Obtains the value of the selFontBold property |
italic | Obtains the value of the selFontItalic property |
strikethru | Obtains the value of the selFontStrikethru property |
underline | Obtains the value of the selFontUnderline property |
If no text is selected, this method applies to the insertion point. The character formatting of the insertion point is applied to newly inserted text if the current selection is empty.
When the selection changes, the default formatting changes to match the first character in the new selection.
Although individual properties enable you to get character formatting attributes, you should consider the number of requests made to the control, particularly when running the JADE application in thin client mode. For example, calling the getCharacterFormat method involves one request from the application server but making individual calls from the application server to the presentation client for specific formatting information within the control requires seven requests.