ChartDirector Ver 3.0 (Perl Edition)

BaseChart.addLegend


Usage

addLegend(x, y[, vertical[, font[, fontSize]]])

Description

Add a legend box to the chart.

Arguments

ArgumentDefaultDescription
x(Mandatory)The x coordinate of the left of the legend box.
y(Mandatory)The y coordinate of the top of the legend box.
verticaltrue (non-zero)Determine if the legend keys are laid out vertically (from top to bottom) or horizontally (from left to right, top to bottom). A true (non-zero) value means vertical layout. A false (zero) value means horizontal layout.
font""The font file for the legend font. The default is arial.ttf (Arial). See Font Specification for details on various font attributes.
fontSize10The font size of the legend font.

Return Value

A LegendBox object representing the legend box. You may use this object to fine-tune the appearance of the legend box.