Documentation

LineNumbering extends AbstractStyle
in package

Line numbering style.

Tags
see
http://www.schemacentral.com/sc/ooxml/t-w_CT_LineNumber.html
since
0.10.0

Table of Contents

Constants

LINE_NUMBERING_CONTINUOUS  = 'continuous'
LINE_NUMBERING_NEW_PAGE  = 'newPage'
LINE_NUMBERING_NEW_SECTION  = 'newSection'

Properties

$aliases  : array<string|int, mixed>
Aliases.
$index  : null|int
Index number in Style collection for named style.
$styleName  : string|null
Style name.
$distance  : float|int
Distance between text and line numbering in twip.
$increment  : int
Line number increments.
$isAuto  : bool
Is this an automatic style? (Used primarily in OpenDocument driver).
$restart  : string
Line numbering restart setting continuous|newPage|newSection.
$start  : int
Line numbering starting value.

Methods

__construct()  : mixed
Create a new instance.
getChildStyleValue()  : mixed
Return style value of child style object, e.g. `left` from `Indentation` child style of `Paragraph`.
getDistance()  : float|int
Get distance.
getIncrement()  : int
Get increment.
getIndex()  : null|int
Get index number.
getRestart()  : string
Get restart.
getStart()  : int
Get start.
getStyleName()  : string|null
Get style name.
isAuto()  : bool
Get is automatic style flag.
setAuto()  : self
Set is automatic style flag.
setDistance()  : self
Set distance.
setIncrement()  : self
Set increment.
setIndex()  : self
Set index number.
setRestart()  : self
Set distance.
setStart()  : self
Set start.
setStyleByArray()  : self
Set style by using associative array.
setStyleName()  : self
Set style name.
setStyleValue()  : self
Set style value template method.
setBoolVal()  : bool
Set bool value.
setEnumVal()  : mixed
Set enum value.
setFloatVal()  : null|float
Set float value: Convert string that contains only numeric into float.
setIntVal()  : null|int
Set integer value: Convert string that contains only numeric into integer.
setNonEmptyVal()  : string
Set default for null and empty value.
setNumericVal()  : null|float|int
Set numeric value.
setObjectVal()  : mixed
Set object value.
setPairedVal()  : self
Set $property value and set $pairProperty = false when $value = true.

Constants

LINE_NUMBERING_CONTINUOUS

public mixed LINE_NUMBERING_CONTINUOUS = 'continuous'
Tags
const

string Line numbering restart setting http://www.schemacentral.com/sc/ooxml/a-w_restart-1.html

LINE_NUMBERING_NEW_PAGE

public mixed LINE_NUMBERING_NEW_PAGE = 'newPage'

LINE_NUMBERING_NEW_SECTION

public mixed LINE_NUMBERING_NEW_SECTION = 'newSection'

Properties

$aliases

Aliases.

protected array<string|int, mixed> $aliases = []

$index

Index number in Style collection for named style.

protected null|int $index

This number starts from one and defined in Style::setStyleValues()

$distance

Distance between text and line numbering in twip.

private float|int $distance

$increment

Line number increments.

private int $increment = 1

$isAuto

Is this an automatic style? (Used primarily in OpenDocument driver).

private bool $isAuto = false
Tags
since
0.11.0

$start

Line numbering starting value.

private int $start = 1

Methods

__construct()

Create a new instance.

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

getChildStyleValue()

Return style value of child style object, e.g. `left` from `Indentation` child style of `Paragraph`.

public getChildStyleValue(AbstractStyle $substyleObject, string $substyleProperty) : mixed
Parameters
$substyleObject : AbstractStyle
$substyleProperty : string
Tags
since
0.12.0

getDistance()

Get distance.

public getDistance() : float|int
Return values
float|int

getIncrement()

Get increment.

public getIncrement() : int
Return values
int

getIndex()

Get index number.

public getIndex() : null|int
Return values
null|int

getRestart()

Get restart.

public getRestart() : string
Return values
string

getStart()

Get start.

public getStart() : int
Return values
int

getStyleName()

Get style name.

public getStyleName() : string|null
Return values
string|null

isAuto()

Get is automatic style flag.

public isAuto() : bool
Return values
bool

setAuto()

Set is automatic style flag.

public setAuto([bool $value = true ]) : self
Parameters
$value : bool = true
Return values
self

setDistance()

Set distance.

public setDistance([float|int $value = null ]) : self
Parameters
$value : float|int = null
Return values
self

setIncrement()

Set increment.

public setIncrement([int $value = null ]) : self
Parameters
$value : int = null
Return values
self

setIndex()

Set index number.

public setIndex([null|int $value = null ]) : self
Parameters
$value : null|int = null
Return values
self

setRestart()

Set distance.

public setRestart([string $value = null ]) : self
Parameters
$value : string = null
Return values
self

setStart()

Set start.

public setStart([int $value = null ]) : self
Parameters
$value : int = null
Return values
self

setStyleByArray()

Set style by using associative array.

public setStyleByArray([array<string|int, mixed> $values = [] ]) : self
Parameters
$values : array<string|int, mixed> = []
Return values
self

setStyleName()

Set style name.

public setStyleName(string $value) : self
Parameters
$value : string
Return values
self

setStyleValue()

Set style value template method.

public setStyleValue(string $key, array<string|int, mixed>|int|string $value) : self

Some child classes have their own specific overrides. Backward compability check for versions < 0.10.0 which use underscore prefix for their private properties. Check if the set method is exists. Throws an exception?

Parameters
$key : string
$value : array<string|int, mixed>|int|string
Return values
self

setBoolVal()

Set bool value.

protected setBoolVal(bool $value, bool $default) : bool
Parameters
$value : bool
$default : bool
Return values
bool

setEnumVal()

Set enum value.

protected setEnumVal([mixed $value = null ][, array<string|int, mixed> $enum = [] ][, mixed $default = null ]) : mixed
Parameters
$value : mixed = null
$enum : array<string|int, mixed> = []
$default : mixed = null

setFloatVal()

Set float value: Convert string that contains only numeric into float.

protected setFloatVal(mixed $value[, null|float $default = null ]) : null|float
Parameters
$value : mixed
$default : null|float = null
Return values
null|float

setIntVal()

Set integer value: Convert string that contains only numeric into integer.

protected setIntVal(null|float|int|string $value[, null|int $default = null ]) : null|int
Parameters
$value : null|float|int|string
$default : null|int = null
Return values
null|int

setNonEmptyVal()

Set default for null and empty value.

protected setNonEmptyVal(string|null $value, string $default) : string
Parameters
$value : string|null
$default : string
Return values
string

setNumericVal()

Set numeric value.

protected setNumericVal(mixed $value[, null|float|int $default = null ]) : null|float|int
Parameters
$value : mixed
$default : null|float|int = null
Return values
null|float|int

setObjectVal()

Set object value.

protected setObjectVal(mixed $value, string $styleName, mixed &$style) : mixed
Parameters
$value : mixed
$styleName : string
$style : mixed

setPairedVal()

Set $property value and set $pairProperty = false when $value = true.

protected setPairedVal(bool &$property, bool &$pairProperty, bool $value) : self
Parameters
$property : bool
$pairProperty : bool
$value : bool
Return values
self

        
On this page

Search results