Documentation

Font extends AbstractStyle

RTF font style writer.

Tags
since
0.11.0

Table of Contents

$colorIndex  : int
$nameIndex  : int
$parentWriter  : AbstractWriter
Parent writer.
$style  : array<string|int, mixed>|AbstractStyle
Style.
__construct()  : mixed
Create new instance.
getParentWriter()  : AbstractWriter
Get parent writer.
getStyle()  : array<string|int, mixed>|AbstractStyle
Get style.
setColorIndex()  : void
Set font color index.
setNameIndex()  : void
Set font name index.
setParentWriter()  : void
Set parent writer.
write()  : string
Write style.
assembleCss()  : string
Takes array where of CSS properties / values and converts to CSS string.
getValueIf()  : string
Get value if .

Properties

$colorIndex

private int $colorIndex = 0

$nameIndex

private int $nameIndex = 0

Methods

__construct()

Create new instance.

public __construct([array<string|int, mixed>|AbstractStyle $style = null ]) : mixed
Parameters
$style : array<string|int, mixed>|AbstractStyle = null
Return values
mixed

setColorIndex()

Set font color index.

public setColorIndex(int $value) : void
Parameters
$value : int
Return values
void

setNameIndex()

Set font name index.

public setNameIndex(int $value) : void
Parameters
$value : int
Return values
void

write()

Write style.

public write() : string
Return values
string

assembleCss()

Takes array where of CSS properties / values and converts to CSS string.

protected assembleCss(array<string|int, mixed> $css) : string
Parameters
$css : array<string|int, mixed>
Return values
string

getValueIf()

Get value if .

protected getValueIf(null|bool $condition, string $value) : string

..

Parameters
$condition : null|bool
$value : string
Return values
string

Search results