Documentation

Legend
in package

Table of Contents

Constants

POSITION_BOTTOM  = 'b'
POSITION_LEFT  = 'l'
POSITION_RIGHT  = 'r'
POSITION_TOP  = 't'
POSITION_TOPRIGHT  = 'tr'
POSITION_XLREF  = [self::XL_LEGEND_POSITION_BOTTOM => self::POSITION_BOTTOM, self::XL_LEGEND_POSITION_CORNER => self::POSITION_TOPRIGHT, self::XL_LEGEND_POSITION_CUSTOM => '??', self::XL_LEGEND_POSITION_LEFT => self::POSITION_LEFT, self::XL_LEGEND_POSITION_RIGHT => self::POSITION_RIGHT, self::XL_LEGEND_POSITION_TOP => self::POSITION_TOP]
XL_LEGEND_POSITION_BOTTOM  = -4107
Legend positions
XL_LEGEND_POSITION_CORNER  = 2
XL_LEGEND_POSITION_CUSTOM  = -4161
XL_LEGEND_POSITION_LEFT  = -4131
XL_LEGEND_POSITION_RIGHT  = -4152
XL_LEGEND_POSITION_TOP  = -4160

Properties

$borderLines  : GridLines
$fillColor  : ChartColor
$layout  : Layout|null
Legend Layout.
$legendText  : AxisText|null
$overlay  : bool
Allow overlay of other elements?
$position  : string
Legend position.

Methods

__clone()  : mixed
Implement PHP __clone to create a deep clone, not just a shallow copy.
__construct()  : mixed
Create a new Legend.
getBorderLines()  : GridLines
getFillColor()  : ChartColor
getLayout()  : Layout|null
Get Layout.
getLegendText()  : AxisText|null
getOverlay()  : bool
Get allow overlay of other elements?
getPosition()  : string
Get legend position as an excel string value.
getPositionXL()  : false|int
Get legend position as an Excel internal numeric value.
setBorderLines()  : self
setLegendText()  : self
setOverlay()  : void
Set allow overlay of other elements?
setPosition()  : bool
Get legend position using an excel string value.
setPositionXL()  : bool
Set legend position using an Excel internal numeric value.

Constants

POSITION_BOTTOM

public mixed POSITION_BOTTOM = 'b'

POSITION_LEFT

public mixed POSITION_LEFT = 'l'

POSITION_RIGHT

public mixed POSITION_RIGHT = 'r'

POSITION_TOP

public mixed POSITION_TOP = 't'

POSITION_TOPRIGHT

public mixed POSITION_TOPRIGHT = 'tr'

POSITION_XLREF

public mixed POSITION_XLREF = [self::XL_LEGEND_POSITION_BOTTOM => self::POSITION_BOTTOM, self::XL_LEGEND_POSITION_CORNER => self::POSITION_TOPRIGHT, self::XL_LEGEND_POSITION_CUSTOM => '??', self::XL_LEGEND_POSITION_LEFT => self::POSITION_LEFT, self::XL_LEGEND_POSITION_RIGHT => self::POSITION_RIGHT, self::XL_LEGEND_POSITION_TOP => self::POSITION_TOP]

XL_LEGEND_POSITION_BOTTOM

Legend positions

public mixed XL_LEGEND_POSITION_BOTTOM = -4107

XL_LEGEND_POSITION_CORNER

public mixed XL_LEGEND_POSITION_CORNER = 2

XL_LEGEND_POSITION_CUSTOM

public mixed XL_LEGEND_POSITION_CUSTOM = -4161

XL_LEGEND_POSITION_LEFT

public mixed XL_LEGEND_POSITION_LEFT = -4131

XL_LEGEND_POSITION_RIGHT

public mixed XL_LEGEND_POSITION_RIGHT = -4152

XL_LEGEND_POSITION_TOP

public mixed XL_LEGEND_POSITION_TOP = -4160

Properties

$overlay

Allow overlay of other elements?

private bool $overlay = true

$position

Legend position.

private string $position = self::POSITION_RIGHT

Methods

__clone()

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

public __clone() : mixed

__construct()

Create a new Legend.

public __construct([string $position = self::POSITION_RIGHT ][, Layout|null $layout = null ][, bool $overlay = false ]) : mixed
Parameters
$position : string = self::POSITION_RIGHT
$layout : Layout|null = null
$overlay : bool = false

getOverlay()

Get allow overlay of other elements?

public getOverlay() : bool
Return values
bool

getPosition()

Get legend position as an excel string value.

public getPosition() : string
Return values
string

getPositionXL()

Get legend position as an Excel internal numeric value.

public getPositionXL() : false|int
Return values
false|int

setBorderLines()

public setBorderLines(GridLines $borderLines) : self
Parameters
$borderLines : GridLines
Return values
self

setLegendText()

public setLegendText(AxisText|null $legendText) : self
Parameters
$legendText : AxisText|null
Return values
self

setOverlay()

Set allow overlay of other elements?

public setOverlay(bool $overlay) : void
Parameters
$overlay : bool

setPosition()

Get legend position using an excel string value.

public setPosition(string $position) : bool
Parameters
$position : string

see self::POSITION_*

Return values
bool

setPositionXL()

Set legend position using an Excel internal numeric value.

public setPositionXL(int $positionXL) : bool
Parameters
$positionXL : int

see self::XL_LEGEND_POSITION_*

Return values
bool

        
On this page

Search results