Method XbpHTMLStyle():draw() Foundation
Draws HTML markup into a Presentation Space.
:draw( <oPS>, <aRect>, <cHTML>, [<nState>] ) --> lSuccess
The :draw() method can be used to draw arbitrary HTML markup into the Presentation Space passed in the <oPS>parameter. <aRect> specifies the output area for the operation. If the representation of the HTML markup exceeds the bounds defined for the output area, the respective content is clipped.
:draw() first computes the representation of the HTML markup, then draws it to the Presentation Space. If CSS styling information was specified when instantiating the XbpHTMLStyle object by calling the method :new(), the CSS is applied to the HTML content when the representation is computed.
The <nState> parameter can be used to activate dedicated CSS styling with respect to a certain draw state. For this, the desired representation must be defined in the CSS using a set of pre-defined CSS selectors. The selectors are activated by the :draw() method depending on the value passed in the <nState> parameter. The following table lists the CSS selectors defined along with their associated draw state.
|CSS selector||Draw state|
In addition, a set of pre-defined CSS classes exist which can also be activated using the <nState> parameter. These CSS classes represent standard UI elements such as the edit field of a combo box.
|CSS class||Draw state|
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.