Constants

xlLegendPositionBottom

xlLegendPositionBottom = -4107

Legend positions

xlLegendPositionCorner

xlLegendPositionCorner = 2

xlLegendPositionCustom

xlLegendPositionCustom = -4161

xlLegendPositionLeft

xlLegendPositionLeft = -4131

xlLegendPositionRight

xlLegendPositionRight = -4152

xlLegendPositionTop

xlLegendPositionTop = -4160

POSITION_RIGHT

POSITION_RIGHT = 'r'

POSITION_LEFT

POSITION_LEFT = 'l'

POSITION_BOTTOM

POSITION_BOTTOM = 'b'

POSITION_TOP

POSITION_TOP = 't'

POSITION_TOPRIGHT

POSITION_TOPRIGHT = 'tr'

Properties

$_positionXLref

$_positionXLref : 

Type

$_position

$_position : string

Legend position

Type

string

$_overlay

$_overlay : boolean

Allow overlay of other elements?

Type

boolean

Methods

__construct()

__construct(  $position = self::POSITION_RIGHT, \PHPExcel_Chart_Layout  $layout = NULL,   $overlay = FALSE) 

Create a new PHPExcel_Chart_Legend

Parameters

$position
\PHPExcel_Chart_Layout $layout
$overlay

getPosition()

getPosition() : string

Get legend position as an excel string value

Returns

string

setPosition()

setPosition(string  $position = self::POSITION_RIGHT) 

Get legend position using an excel string value

Parameters

string $position

getPositionXL()

getPositionXL() : \number

Get legend position as an Excel internal numeric value

Returns

\number

setPositionXL()

setPositionXL(\number  $positionXL = self::xlLegendPositionRight) 

Set legend position using an Excel internal numeric value

Parameters

\number $positionXL

getOverlay()

getOverlay() : boolean

Get allow overlay of other elements?

Returns

boolean

setOverlay()

setOverlay(boolean  $overlay = FALSE) : boolean

Set allow overlay of other elements?

Parameters

boolean $overlay

Returns

boolean