ChartDirector 7.0 (Perl Edition)

Axis.setMargin


Usage

setMargin(topMargin [, bottomMargin ])

Description

Reserve margins at the ends of the axis.

This method is usually used to reserve space in the plot area. For example, if some margin is reserved at the top of the vertical y-axis, the top of the plot area will contain no data points. It is because this region would be outside the active range of the y-axis. If anything is put at the top of the plot area (such as a legend box or custom text), it will not overlap with the data points.

Note if auto-scaling is used, there is an alternative way to reserve space at the top and/or bottom of the plot area - the Axis.setAutoScale method.

Arguments

ArgumentDefaultDescription
topMargin(Mandatory)The margin reserved at the top end (or right end for horizontal axis) of the axis in pixels.
bottomMargin0The margin reserved at the bottom end (or left end for horizontal axis) of the axis in pixels.

Return Value

None