PERGOLA LOGO

pergola.Caption

System events: YES.

User events and functions: NO.

Use this component to label selectors, input boxes, etc. Example. See also the Caption's subclass pergola.Suffix.

Listed: class properties/methods; prototype properties and methods; instance properties. Prototype properties and methods inherited by the Class superclass are not listed.

class

None

prototype

PROPERTIES

parent

pergola.user. For this class this property should normally be overridden to designate the container of the object requesting the instance.

position

"left" – string (values: "left"; "right").

"text-anchor"

"end" – string. Note: this property should not be overridden as it is set to the appropriate value depending on position.

textFill

Color string. Defined in pergola.presentationAttributes.

inverse

false – boolean. If set to true, the default value of this textFill is overridden to get the value of pergola.presentationAttributes.text.fill, which is dependent of the themeLuminosity. In practice you will set this property to true if the text color doesn't read well against any particular color in the background.

activator

true – boolean. If true, the caption is sensitive to events and can activate the control to which it relates (selectors, input boxes).

METHODS

build(object)

this inherits the properties specified in object. Prototype properties specified in object are overridden. Creates elements. Returns this.

instance

name

String. If not passed to the constructor, gets a generated XML name (Class).

id

String. The return value of this name.toXML().

owner

Required, designates the owner object.

x

If not specified in the initialization object, the computed x position relative to the value of this "text-anchor".

y

If not specified in the initialization object, the inherited value 0 (the text element may not be visible).

textNode

Must be specified in the initialization object – string.

element

<text> element.