class RichText implements IComparable (View source)

Methods

__construct(Cell $pCell = null)

Create a new RichText instance.

addText(ITextElement $pText)

Add text.

createText(string $pText)

Create text.

Run
createTextRun(string $pText)

Create text run.

string
getPlainText()

Get plain text.

string
__toString()

Convert to string.

getRichTextElements()

Get Rich Text elements.

setRichTextElements(array $textElements)

Set Rich Text elements.

string
getHashCode()

Get hash code.

__clone()

Implement PHP __clone to create a deep clone, not just a shallow copy.

Details

__construct(Cell $pCell = null)

Create a new RichText instance.

Parameters

Cell $pCell

Exceptions

Exception

RichText addText(ITextElement $pText)

Add text.

Parameters

ITextElement $pText Rich text element

Return Value

RichText

TextElement createText(string $pText)

Create text.

Parameters

string $pText Text

Return Value

TextElement

Exceptions

Exception

Run createTextRun(string $pText)

Create text run.

Parameters

string $pText Text

Return Value

Run

Exceptions

Exception

string getPlainText()

Get plain text.

Return Value

string

string __toString()

Convert to string.

Return Value

string

ITextElement[] getRichTextElements()

Get Rich Text elements.

Return Value

ITextElement[]

RichText setRichTextElements(array $textElements)

Set Rich Text elements.

Parameters

array $textElements Array of elements

Return Value

RichText

string getHashCode()

Get hash code.

Return Value

string Hash code

__clone()

Implement PHP __clone to create a deep clone, not just a shallow copy.