GetLegendSize — Return the amount of space required for the legend box
list($width, $height) = $plot->GetLegendSize()
GetLegendSize
returns the size (in pixels) required
for the legend box. This might be used to adjust the plot margins based on
the legend size, for example. After calling GetLegendSize
,
you can use SetPlotAreaWorld or
SetMarginsPixels to leave room for the legend.
Returns an array of two values ($width, $height). These are the width and height required for the box containing the legend.
This function will return valid numbers after the legend has been set up (including using SetLegend to set all the text lines, and optional calls to set the font, linespacing, and style). The results from this function do not depend on data values, plot type, or other plot elements.