A PieChart2D object is an enclosed are with a title, pie sectors, pie labels, and a legend.
Changes through its set methods are updated upon next repaint() or getImage() calls.
Constructor Summary
public
PieChart2D() Creates a PieChart2D object with its defaults.
validate(boolean debug) Validates the properties of this object.
If debug is true then prints a messages indicating whether each property is valid.
Returns true if all the properties were valid and false otherwise.
Parameters: debug - If true then will print status messages.
Gets the preferred size of the chart.
The preferred size is within the maximum and minimum sizes of the chart.
Much calculation is performed when calling this method.
The preferred minimum size of the chart.
Sets the Dataset for this PieChart2D.
Parameters: d - The Dataset.
setLayoutRatios
final public void setLayoutRatios(float pieInfoW)(Code)
Sets the allocation of space to each component of a pie chart.
There are three components: pieInfo and legend.
The pieInfoW needs to be within 0f and 1f.
The legendW will be 1f - pieInfoW.
Both the pieInfoW and the legendH will be 1f.
Parameters: pieInfoW - The ratio of pieInfo width to total.
Sets a custom preferred size for the chart.
This custom size will override the preferred size calculations that normally occurr.
If null is passed, the preferred size calculations will be reinstated.
Parameters: size - The custom preferred size for this chart.
validate
final public boolean validate(boolean debug)(Code)
Validates the properties of this object.
If debug is true then prints a messages indicating whether each property is valid.
Returns true if all the properties were valid and false otherwise.
Parameters: debug - If true then will print status messages. If true then valid.
Methods inherited from net.sourceforge.chart2d.Chart2D