TextBoxCollection

class Communicator.Markup.Shape.TextBoxCollection()

This class is useful for drawing a number of text boxes which share the same visual settings.

Methods

addString()

clear()

getBoxPortion()

getPadding()

getStrings()

getTextPortion()

setPadding()


Methods

addString

Communicator.Markup.Shape.TextBoxCollection.addString(text, position)

Adds a string to the collection

Arguments
  • text (string()) – the text to render

  • position (Communicator.Point2()) – the top left position of the text

Return type

void

clear

Communicator.Markup.Shape.TextBoxCollection.clear()

Removes all text strings from this collection

Return type

void

getBoxPortion

Communicator.Markup.Shape.TextBoxCollection.getBoxPortion()

Gets the Box portion of the TextBox. Use the methods on this object to modify the appearance of the rectangle around the text string

Return type

Communicator.Markup.Shape.RectangleBase

Returns

the rectangle markup object.

getPadding

Communicator.Markup.Shape.TextBoxCollection.getPadding()

Gets the Pixel distance between the text and outer rectangle

Return type

number

Returns

the padding value.

getStrings

Communicator.Markup.Shape.TextBoxCollection.getStrings()

Gets the strings in the collection

Return type

[_MarkupTextData]

getTextPortion

Communicator.Markup.Shape.TextBoxCollection.getTextPortion()

Gets the Text portion of the TextBox. Use the methods on this object to modify the appearance of the text string

Return type

Communicator.Markup.Shape.TextMarkupBase

Returns

the text markup object

setPadding

Communicator.Markup.Shape.TextBoxCollection.setPadding(padding)

Sets the Pixel distance between the text and outer rectangle

Arguments
  • padding (number()) – the padding value.

Return type

void