All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class MSBChart.PieDataSerie

java.lang.Object
   |
   +----MSBChart.DataSerie
           |
           +----MSBChart.PieDataSerie

public class PieDataSerie
extends DataSerie

The PieDataSerie is actually not a serie of value but a set of values to be plotted as a pie chart.

Example:

// data
double[] d1={64,95,11,70};
// style of the pie
FillStyle[] s1={new FillStyle(java.awt.Color.cyan),new FillStyle(java.awt.Color.blue),new FillStyle(java.awt.Color.green),new FillStyle(java.awt.Color.yellow)};
PieDataSerie data1= new PieDataSerie(d1,s1);


Variable Index

 o drawPercentages
 o textDistanceToCenter
 o valueColor
 o valueFont

Constructor Index

 o PieDataSerie(double[], FillStyle[])

Method Index

 o addPieData(double, FillStyle)

Variables

 o valueColor
 public Color valueColor
color of the font used to display the values/percentages.
 o valueFont
 public Font valueFont
font used to display the values/percentages.
 
 o textDistanceToCenter
 public double textDistanceToCenter

distance of the text to the center of the pie. The default value is 1 (outside the pie). A value of 0.5 means half of the radius of the pie.

 

 o drawPercentages
 public boolean drawPercentages
if true the percenteges will be displayed instead of the actual values.

Constructors

 o PieDataSerie
 public PieDataSerie(double y[],
                     FillStyle s[])
creates a PieDataSerie to display a list of values on a pie chart. Each element must have also a styled.
 

Methods

 o addPieData
 public void addPieData(double y,
                        FillStyle s)
Adds a new value to the set.

All Packages  Class Hierarchy  This Package  Previous  Next  Index