org.jCharts.properties
Class PieChart2DProperties

java.lang.Object
  |
  +--org.jCharts.properties.ChartTypeProperties
        |
        +--org.jCharts.properties.PieChart2DProperties
All Implemented Interfaces:
HTMLTestable

public final class PieChart2DProperties
extends ChartTypeProperties
implements HTMLTestable


Field Summary
private  java.awt.Paint borderPaint
           
private  java.awt.Stroke borderStroke
           
static java.awt.Paint DEFAULT_BORDER_PAINT
           
static java.awt.Stroke DEFAULT_BORDER_STROKE
           
private  boolean isCurrency
           
private  PieLabelType pieLabelType
           
private  int roundingPowerOfTen
           
private  boolean showGrouping
           
private  float tickLength
           
private  ChartFont valueLabelFont
           
private  float zeroDegreeOffset
           
 
Constructor Summary
PieChart2DProperties()
           
 
Method Summary
 java.awt.Paint getBorderPaint()
           
 java.awt.Stroke getBorderStroke()
           
 PieLabelType getPieLabelType()
           
 float getTickLength()
           
 ChartFont getValueLabelFont()
           
 int getValueLabelRoundingPowerOfTen()
           
 float getZeroDegreeOffset()
           
 void setBorderPaint(java.awt.Paint paint)
           
 void setBorderStroke(java.awt.Stroke stroke)
           
 void setCurrency(boolean currency)
           
 void setPieLabelType(PieLabelType pieLabelType)
          Sets the type of label to draw on the PieChart.
 void setRoundingPowerOfTen(int roundingPowerOfTen)
           
 void setShowGrouping(boolean showGrouping)
           
 void setTickLength(float tickLength)
           
 void setValueLabelFont(ChartFont valueLabelFont)
          Sets the ChartFont used to draw the chart value labels.
 void setZeroDegreeOffset(float zeroDegreeOffset)
          The offset from zero degrees which the first slice of pie is drawn.
 boolean showValueLabelCurrency()
           
 boolean showValueLabelGrouping()
           
 void toHTML(HTMLGenerator htmlGenerator)
          Enables the testing routines to display the contents of this Object.
 void validate(Chart chart)
          Validates the properties.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_BORDER_PAINT

public static final java.awt.Paint DEFAULT_BORDER_PAINT

DEFAULT_BORDER_STROKE

public static final java.awt.Stroke DEFAULT_BORDER_STROKE

borderPaint

private java.awt.Paint borderPaint

borderStroke

private java.awt.Stroke borderStroke

zeroDegreeOffset

private float zeroDegreeOffset

pieLabelType

private PieLabelType pieLabelType

isCurrency

private boolean isCurrency

showGrouping

private boolean showGrouping

roundingPowerOfTen

private int roundingPowerOfTen

valueLabelFont

private ChartFont valueLabelFont

tickLength

private float tickLength
Constructor Detail

PieChart2DProperties

public PieChart2DProperties()
Method Detail

setZeroDegreeOffset

public void setZeroDegreeOffset(float zeroDegreeOffset)
The offset from zero degrees which the first slice of pie is drawn. Charts look better to my eye when they do not start at zero degrees, but beauty is in the eye of the beholder.

Parameters:
zeroDegreeOffset -

getZeroDegreeOffset

public float getZeroDegreeOffset()
Returns:
double

getBorderStroke

public java.awt.Stroke getBorderStroke()
Returns:
stroke

setBorderStroke

public void setBorderStroke(java.awt.Stroke stroke)
Parameters:
stroke -

getBorderPaint

public java.awt.Paint getBorderPaint()
Returns:
Paint

setBorderPaint

public void setBorderPaint(java.awt.Paint paint)
Parameters:
paint -

getPieLabelType

public PieLabelType getPieLabelType()
Returns:

setPieLabelType

public void setPieLabelType(PieLabelType pieLabelType)
Sets the type of label to draw on the PieChart. The default value is: PieLabelType.NO_LABELS so no labels will be drawn on chart.

Parameters:
pieLabelType -

getValueLabelFont

public ChartFont getValueLabelFont()

setValueLabelFont

public void setValueLabelFont(ChartFont valueLabelFont)
Sets the ChartFont used to draw the chart value labels.

Parameters:
valueLabelFont -

setCurrency

public void setCurrency(boolean currency)

setShowGrouping

public void setShowGrouping(boolean showGrouping)

setRoundingPowerOfTen

public void setRoundingPowerOfTen(int roundingPowerOfTen)

setTickLength

public void setTickLength(float tickLength)

getTickLength

public float getTickLength()

showValueLabelCurrency

public boolean showValueLabelCurrency()

showValueLabelGrouping

public boolean showValueLabelGrouping()

getValueLabelRoundingPowerOfTen

public int getValueLabelRoundingPowerOfTen()

toHTML

public void toHTML(HTMLGenerator htmlGenerator)
Enables the testing routines to display the contents of this Object.

Specified by:
toHTML in interface HTMLTestable
Parameters:
htmlGenerator -

validate

public void validate(Chart chart)
              throws PropertyException
Validates the properties.

Parameters:
chart -
Throws:
PropertyException