cpr.ufc.StyledString

A class that abstracts styled text.

Index

Methods
Name Return Type Description
append StyledString Add text at the end.
getCopy StyledString
isEmpty Boolean
prepend StyledString Puts a string at the beginning of the string.

Constructor

StyledString()
Creates an empty style string.

Methods

append(text, style)
Add text at the end.
Parameters
name type description
text String The text to add.
styleoptional TextStyle The style to be applied to the part to be added.
return StyledString
append(styledString)
Add another style string at the end.
Parameters
name type description
styledString StyledString The style string to append.
return StyledString
getCopy()
return StyledString Get a copy of the style string.
isEmpty()
return Boolean Is it an empty style string?
prepend(text, style)
Puts a string at the beginning of the string.
Parameters
name type description
text String The string to insert.
styleoptional TextStyle The style to be applied to that string.
return StyledString
prepend(styledString)
Insert another style string in the front part.
Parameters
name type description
styledString StyledString The style string to embed.
return StyledString