com.steema.teechart.styles
Class CustomPolar

java.lang.Object
  extended by com.steema.teechart.TeeBase
      extended by com.steema.teechart.styles.Series
          extended by com.steema.teechart.styles.Circular
              extended by com.steema.teechart.styles.CustomPolar
All Implemented Interfaces:
ISeries, java.io.Serializable, java.lang.Cloneable
Direct Known Subclasses:
Custom2DPolar, Polar, Radar

public class CustomPolar
extends Circular

Title: CustomPolar class

Description: CustomPolar Series.

Copyright (c) 2005-2006 by Steema Software SL. All Rights Reserved.

Company: Steema Software SL

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class com.steema.teechart.styles.Series
Series.MarkTextResolver
 
Field Summary
protected  int iMaxValuesCount
           
protected  SeriesPointer iPointer
           
 
Fields inherited from class com.steema.teechart.styles.Circular
iCircleXCenter, iCircleYCenter, iXRadius, iYRadius, PIDEGREE, rCircleRect, rotDegree
 
Fields inherited from class com.steema.teechart.styles.Series
AUTODEPTH, AUTOZORDER, bActive, bBrush, bColorEach, calcVisiblePoints, colorMember, customMarkText, drawBetweenPoints, endZ, firstVisible, hasZValues, iColors, InternalUse, iNumSampleValues, iZOrder, labelMember, lastVisible, listenerList, mandatory, manualData, marks, middleZ, notMandatory, percentDecimal, percentFormat, sLabels, startZ, useAxis, useSeriesColor, valueFormat, vxValues, vyValues, yMandatory
 
Fields inherited from class com.steema.teechart.TeeBase
chart
 
Constructor Summary
CustomPolar()
           
CustomPolar(IBaseChart c)
           
 
Method Summary
 int calcXPos(int valueIndex)
          Returns the pixel Screen Horizontal coordinate of the ValueIndex Series value.
 int calcYPos(int valueIndex)
          Returns the pixel Screen Vertical coordinate of the ValueIndex Series value.
 int clicked(int x, int y)
          The ValueIndex of the "clicked" point in the Series.
protected  boolean clickedSegment(java.awt.Point p, java.awt.Point tmp, java.awt.Point old)
           
protected  void doAfterDrawValues()
           
protected  void doBeforeDrawValues()
           
protected  void draw()
           
protected  void drawLegendShape(IGraphics3D g, int valueIndex, Rectangle rect)
           
protected  void drawMark(int valueIndex, java.lang.String s, SeriesMarksPosition position)
           
 void drawRing(double value, int z)
           
 void drawValue(int valueIndex)
          Called internally.
 void drawZone(double min, double max, int z)
           
 double getAngleIncrement()
          The Bottom Axis is used as Angle axis.
 ValueList getAngleValues()
          Gets list of angle values for each polar point.
 ChartBrush getBrush()
          Sets Polar Back Brush.
 java.awt.Point getCircleCenter()
           
protected  java.lang.String getCircleLabel(double angle, int index)
           
 boolean getCircleLabels()
          Sets CicleLabel properties.
 ChartFont getCircleLabelsFont()
          The Font characteristics for the labels of a circular TeeChart.
 boolean getCircleLabelsInside()
          Enables/disables the display of the axis labels inside the circle area.
 boolean getCircleLabelsRotated()
          Places Circle Labels at an angle in line with the Radar/Polar circle at each Label point when true.
 ChartPen getCirclePen()
          Determines the pen used to draw the outmost circle of all CustomPolar series derived Series.
 boolean getClockWiseLabels()
          Displays the circle labels in a clockwise direction.
 boolean getCloseCircle()
          Draws a Line between the last and first PolarSeries point coordinates.
 ChartFont getFont()
          The label font characteristics.
 ChartPen getPen()
          Determines Pen used to draw the Line connecting PolarSeries points.
 SeriesPointer getPointer()
          Pointer contains several properties to control the formatting attributes of Points like Pen, Brush, Draw3D, Visible, etc.
 double getRadiusIncrement()
          Determines the increment used to draw the ring grid lines.
 ValueList getRadiusValues()
          Gets list of radius values for each polar point.
 int getTransparency()
          The Transparency level from 0 to 100%.
protected  double getXValue(int valueIndex)
           
 void prepareForGallery(boolean isEnabled)
           
 void setAngleIncrement(double value)
           
 void setChart(IBaseChart c)
          Chart associated with this object.
 void setCircleLabels(boolean value)
          Sets CicleLabel properties.
 void setCircleLabelsInside(boolean value)
          Enables/disables the display of the axis labels inside the circle area.
 void setCircleLabelsRotated(boolean value)
          Places Circle Labels at an angle in line with the Radar/Polar circle at each Label point when true.
 void setClockWiseLabels(boolean value)
          Displays the circle labels in a clockwise direction when true.
 void setCloseCircle(boolean value)
          Draws a Line between the last and first PolarSeries point coordinates.
 void setColor(Color c)
          Default color for all points.
 void setRadiusIncrement(double value)
          Sets the increment used to draw the ring grid lines.
 void setTransparency(int value)
          Sets Transparency level from 0 to 100%.
 
Methods inherited from class com.steema.teechart.styles.Circular
adjustCircleRect, angleToPos, associatedToAxis, calcCircleBackColor, calcCircleGradient, calcRadius, getCircleBackColor, getCircled, getCircleGradient, getCircleHeight, getCircleRect, getCircleWidth, getCircleXCenter, getCircleYCenter, getCustomXRadius, getCustomYRadius, getRotationAngle, getXRadius, getYRadius, onDisposing, pointToAngle, pointToRadius, prepareLegendCanvas, rotate, setActive, setCircleBackColor, setCircled, setCustomXRadius, setCustomYRadius, setParentProperties, setRotationAngle, shouldSerializeCircleBackColor
 
Methods inherited from class com.steema.teechart.styles.Series
add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, addChartValue, added, addNull, addNullXY, addSampleValues, addSeriesMouseListener, addSeriesPaintListener, addValues, assign, assignDispose, assignValues, beginUpdate, calcFirstLastVisibleIndex, calcHorizMargins, calcPosValue, calcVerticalMargins, calcXPosValue, calcXSizeValue, calcYPosValue, calcYSizeValue, calcZOrder, canAddRandomPoints, changeType, checkDataSource, checkMouse, checkOrder, checkOtherSeries, clear, clearLists, clicked, clone, cloneSeries, convertArray, createNewSeries, createNewSeries, createSubGallery, dataSourceArray, delete, delete, delete, dispose, doBeforeDrawChart, doClick, doClickPointer, doDoubleClick, drawLegend, drawLegend, drawMarks, drawSeries, drawSeriesForward, drawValuesForward, endUpdate, fillSampleValues, fillSampleValues, fireSeriesMouseEvent, fireSeriesPaint, galleryChanged3D, getActive, getAllowSinglePoint, getBitmapEditor, getColor, getColorEach, getColorMember, getColors, getCount, getCountLegendItems, getCursor, getCustomHorizAxis, getCustomVertAxis, getDataSource, getDepth, getDescription, getEndZ, getFields, getFirstVisible, getFunction, getHasZValues, getHorizAxis, getHorizontalAxis, getLabelMember, getLabels, getLastVisible, getLegendString, getMandatory, getMarks, getMarkText, getMarkValue, getMaxXValue, getMaxYValue, getMaxZValue, getMiddleZ, getMinXValue, getMinYValue, getMinZValue, getNotMandatory, getNumGallerySeries, getNumSampleValues, getOriginValue, getPercentFormat, getPoint, getSeriesColor, getShowInLegend, getStartZ, getTitle, getUseAxis, getValueColor, getValueFormat, getValueIndexSwapper, getValueList, getValueList, getValueMarkText, getValuesLists, getVertAxis, getVerticalAxis, getVisible, getXValues, getYMandatory, getYValueList, getYValues, getZOrder, hasDataSource, hasListenersOf, hasNoMandatoryValues, isNull, isValidSeriesSource, isValidSourceOf, legendItemColor, legendToValueIndex, maxMarkWidth, moreSameZOrder, mouseEvent, newFromType, numSampleValues, paintLegend, randomBounds, readResolve, recalcGetAxis, refreshSeries, removeMarkTextResolver, removeSeriesMouseListener, removeSeriesPaintListener, repaint, sameClass, setColorEach, setColorMember, setColors, setCursor, setCustomHorizAxis, setCustomHorizAxis, setCustomVertAxis, setCustomVertAxis, setDataSource, setDepth, setEndZ, setFunction, setHorizontal, setHorizontalAxis, setLabelMember, setLabels, setMarks, setMarkTextResolver, setMiddleZ, setNull, setPercentFormat, setSeriesColor, setShowInLegend, setStartZ, setSubGallery, setTitle, setValueFormat, setValueList, setVerticalAxis, setVisible, setXValues, setYValues, setZOrder, setZPositions, sortByLabels, sortByLabels, swapValueIndex, titleOrName, toString, valuesListAdd, xScreenToValue, yScreenToValue
 
Methods inherited from class com.steema.teechart.TeeBase
getChart, invalidate, setBooleanProperty, setColorProperty, setColorProperty, setDoubleProperty, setIntegerProperty, setStringProperty
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.steema.teechart.styles.ISeries
getChart, invalidate
 

Field Detail

iPointer

protected SeriesPointer iPointer

iMaxValuesCount

protected int iMaxValuesCount
Constructor Detail

CustomPolar

public CustomPolar()

CustomPolar

public CustomPolar(IBaseChart c)
Method Detail

getCircleLabelsFont

public ChartFont getCircleLabelsFont()
The Font characteristics for the labels of a circular TeeChart.

Returns:
ChartFont

getCircleCenter

public java.awt.Point getCircleCenter()

clickedSegment

protected boolean clickedSegment(java.awt.Point p,
                                 java.awt.Point tmp,
                                 java.awt.Point old)

clicked

public int clicked(int x,
                   int y)
The ValueIndex of the "clicked" point in the Series.

Specified by:
clicked in interface ISeries
Overrides:
clicked in class Series
Parameters:
x - int
y - int
Returns:
int

getXValue

protected double getXValue(int valueIndex)

getAngleIncrement

public double getAngleIncrement()
The Bottom Axis is used as Angle axis.
Gets angle in degrees used to draw the dividing grid lines in anti-clockwise direction.
The 0 starting angle is located at rightmost Polar coordinate. Valid increments are between 0 and 359 degree.
You can control the grid lines pen by using Chart.Axes.Bottom.Grid.

Returns:
double

getAngleValues

public ValueList getAngleValues()
Gets list of angle values for each polar point.
It is a TList object that stores each Polar point Angle value. You can change angle values by using AngleValues.Value[ ] array of doubles.

Returns:
ValueList

getRadiusValues

public ValueList getRadiusValues()
Gets list of radius values for each polar point.
It is a TList object that stores each Polar point Radius value. You can change Radius values by using RadiusValues.Value[] array of doubles.

Returns:
ValueList

doAfterDrawValues

protected void doAfterDrawValues()
Overrides:
doAfterDrawValues in class Series

doBeforeDrawValues

protected void doBeforeDrawValues()
Overrides:
doBeforeDrawValues in class Circular

draw

protected void draw()
Overrides:
draw in class Series

drawLegendShape

protected void drawLegendShape(IGraphics3D g,
                               int valueIndex,
                               Rectangle rect)
Overrides:
drawLegendShape in class Series

drawMark

protected void drawMark(int valueIndex,
                        java.lang.String s,
                        SeriesMarksPosition position)
Overrides:
drawMark in class Series

drawValue

public void drawValue(int valueIndex)
Called internally. Draws the "ValueIndex" point of the Series.

Specified by:
drawValue in interface ISeries
Overrides:
drawValue in class Series
Parameters:
valueIndex - int

getCircleLabel

protected java.lang.String getCircleLabel(double angle,
                                          int index)

prepareForGallery

public void prepareForGallery(boolean isEnabled)
Overrides:
prepareForGallery in class Series

setChart

public void setChart(IBaseChart c)
Description copied from class: TeeBase
Chart associated with this object.

Specified by:
setChart in interface ISeries
Overrides:
setChart in class Circular
Parameters:
c - IBaseChart

setColor

public void setColor(Color c)
Description copied from class: Series
Default color for all points.
Default value: Color.Empty

Overrides:
setColor in class Series
Parameters:
c - Color
See Also:
Series.getColorEach()

calcXPos

public int calcXPos(int valueIndex)
Returns the pixel Screen Horizontal coordinate of the ValueIndex Series value.
This coordinate is calculated using the Series associated Horizontal Axis.

Overrides:
calcXPos in class Series
Parameters:
valueIndex - int
Returns:
int

calcYPos

public int calcYPos(int valueIndex)
Returns the pixel Screen Vertical coordinate of the ValueIndex Series value.
This coordinate is calculated using the Series associated Vertical Axis.

Overrides:
calcYPos in class Series
Parameters:
valueIndex - int
Returns:
int

drawZone

public void drawZone(double min,
                     double max,
                     int z)

drawRing

public void drawRing(double value,
                     int z)

setAngleIncrement

public void setAngleIncrement(double value)

getBrush

public ChartBrush getBrush()
Sets Polar Back Brush.

Returns:
ChartBrush

getCircleLabels

public boolean getCircleLabels()
Sets CicleLabel properties.
Default value: false

Returns:
boolean

setCircleLabels

public void setCircleLabels(boolean value)
Sets CicleLabel properties.
Default value: false

Parameters:
value - boolean

getFont

public ChartFont getFont()
The label font characteristics.

Returns:
ChartFont

getCircleLabelsInside

public boolean getCircleLabelsInside()
Enables/disables the display of the axis labels inside the circle area.
Default value: false

Returns:
boolean

setCircleLabelsInside

public void setCircleLabelsInside(boolean value)
Enables/disables the display of the axis labels inside the circle area.
Default value: false

Parameters:
value - boolean

getCircleLabelsRotated

public boolean getCircleLabelsRotated()
Places Circle Labels at an angle in line with the Radar/Polar circle at each Label point when true.
Default value: false

Returns:
boolean

setCircleLabelsRotated

public void setCircleLabelsRotated(boolean value)
Places Circle Labels at an angle in line with the Radar/Polar circle at each Label point when true.
Default value: false

Parameters:
value - boolean

getCirclePen

public ChartPen getCirclePen()
Determines the pen used to draw the outmost circle of all CustomPolar series derived Series.

Returns:
ChartPen

getClockWiseLabels

public boolean getClockWiseLabels()
Displays the circle labels in a clockwise direction.
Default value: false

Returns:
boolean

setClockWiseLabels

public void setClockWiseLabels(boolean value)
Displays the circle labels in a clockwise direction when true.
Default value: false

Parameters:
value - boolean

getCloseCircle

public boolean getCloseCircle()
Draws a Line between the last and first PolarSeries point coordinates.
If true, the Polar series polygon is closed.
Default value: true

Returns:
boolean

setCloseCircle

public void setCloseCircle(boolean value)
Draws a Line between the last and first PolarSeries point coordinates.
Default value: true

Parameters:
value - boolean

getPen

public ChartPen getPen()
Determines Pen used to draw the Line connecting PolarSeries points.
Points can be displayed by setting Pointer.Visible to true.
You can set the Pen used to draw the circle using CirclePen.

Returns:
ChartPen

getPointer

public SeriesPointer getPointer()
Pointer contains several properties to control the formatting attributes of Points like Pen, Brush, Draw3D, Visible, etc.
It is a subclass of Points series, Line series and all other derived Points series classes like Bubble series, Polar series and Candle series.
Each point in a Polar series is drawn using the Pointer properties.

Returns:
SeriesPointer

getRadiusIncrement

public double getRadiusIncrement()
Determines the increment used to draw the ring grid lines.
It is the same as accessing Chart.Axes.Left.Increment when using Polar series.
You can use RadiusIncrement with Polar series .AngleIncrement to control how gridlines are displayed in Polar charts.

Returns:
double

setRadiusIncrement

public void setRadiusIncrement(double value)
                        throws ChartException
Sets the increment used to draw the ring grid lines.

Parameters:
value - double
Throws:
TeeChartException
ChartException

getTransparency

public int getTransparency()
The Transparency level from 0 to 100%.
Default value: 0

Returns:
int

setTransparency

public void setTransparency(int value)
Sets Transparency level from 0 to 100%.
Default value: 0

Parameters:
value - int