OverviewSingleDeprecated

package jsx3.html

Utility methods related to rendering HTML.

Class Summary
jsx3.html.BlockTag
Represents an HTML element that occupies a rectangle of the screen.
jsx3.html.FontTag
Represents an HTML element that defines font styles.
jsx3.html.Tag
Represents an HTML element.
jsx3.html.Text
Represents an HTML text node.
Method Summary
static void
copy(strText : String)
Copies the given string of text to the clipboard
static jsx3.app.Model
getJSXParent(objGUI : HTMLElement, objServer : jsx3.app.Server)
Traverses the browser DOM up from objGUI and returns the first GI DOM node that contains objGUI.
static void
getOuterHTML(objElement : HTMLElement)
Returns the serialized HTML representation of objElement.
static void
Pre-loads images into the HTML page so that they are available immediately when a control paints them.
static String
Returns the current text content of the clipboard
static void
setInnerText(objElement : HTMLElement, strText : String)
Replaces the children of objElement with a text node of value strText.
static void
setOuterHTML(objElement : HTMLElement, strHTML : String)
Replaces objElement with an HTML snippet, strHTML.
Method Detail

copy

static void copy(strText : String)
Copies the given string of text to the clipboard

Parameters:

strTexttext to copy

getJSXParent

static jsx3.app.Model getJSXParent(objGUI : HTMLElement, objServer : jsx3.app.Server)
Traverses the browser DOM up from objGUI and returns the first GI DOM node that contains objGUI.

Parameters:

objGUI
objServerif provided, only return a DOM node from this server.

Returns:

 

getOuterHTML

static void getOuterHTML(objElement : HTMLElement)
Returns the serialized HTML representation of objElement.

Parameters:

objElement

loadImages

static void loadImages(varImages : String... | jsx3.net.URI... | Array<String | jsx3.net.URI>)
Pre-loads images into the HTML page so that they are available immediately when a control paints them.

Parameters:

varImagesone or more relative URIs to image files. Each URI will be resolved against the default resolver.

paste

static String paste()
Returns the current text content of the clipboard

Returns:

 

setInnerText

static void setInnerText(objElement : HTMLElement, strText : String)
Replaces the children of objElement with a text node of value strText.

Parameters:

objElement
strText

setOuterHTML

static void setOuterHTML(objElement : HTMLElement, strHTML : String)
Replaces objElement with an HTML snippet, strHTML.

Parameters:

objElement
strHTML