|
ChartCat 1.2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectli.netcat.chart.util.AbstractPart
li.netcat.chart.util.GraphPart
li.netcat.chart.util.PolarGraphPart
li.netcat.chart.util.RingPart
Represents a round graph that looks for example like this:
It can be used to paint pies and doughnuts. Each data segment can be empahsized by moving it in the radial direction.
Field Summary |
Fields inherited from class li.netcat.chart.util.PolarGraphPart |
NET, RING |
Fields inherited from class li.netcat.chart.util.GraphPart |
STACK_STRATEGY_APPEND, STACK_STRATEGY_GROUP, STACK_TYPE_NOT_STACKED, STACK_TYPE_STACKED, STACK_TYPE_STACKED_PERCENT |
Fields inherited from class li.netcat.chart.util.AbstractPart |
BACKGROUND, FOREGROUND, PERSPECTIVE |
Constructor Summary | |
RingPart(ChartModel model)
Constructs a new RingPart using the given ChartModel and the type STACK_TYPE_STACKED_PERCENT . |
|
RingPart(ChartModel model,
int stackType)
Constructs a new RingPart using the given ChartModel and the given type. |
Method Summary | |
void |
clearRadialMove()
Clears all radial move entries. |
float |
getFlatness()
Returns the maximum distance that the line segments used to approximate the curved segments are allowed. |
Layout |
getLayout(java.awt.Graphics g)
Returns an instance of a layout that is able to report the bounds of this part and is able to paint this part. |
float |
getRadialMove(int rowIndex,
int columnIndex)
Returns the radial movement of a data element. |
ValueLocation |
getValueLocation(int rowIndex,
int columnIndex)
Abstract function that calculates a ValueLocation for a given cell. |
void |
setFlatness(float flatness)
Sets the maximum distance that the line segments used to approximate the curved segments are allowed. |
void |
setRadialMove(int rowIndex,
int columnIndex,
float move)
Sets a radial movement of a data element. |
Methods inherited from class li.netcat.chart.util.PolarGraphPart |
getCenterX, getCenterY, getConverter, getInnerRadius, getOrientation, getRadialScaleModel, getRadius, getStretch, getTangentialScaleModel, getThickness, invalidate, setRadialScaleModel, setSize, setStretch, setTangentialScaleModel |
Methods inherited from class li.netcat.chart.util.GraphPart |
getChartModel, getDiscreetLength, getDiscreetScaleModel, getGraphLook, getLegendModel, getNumericLength, getNumericScaleModel, getStackModel, setChartModel, setDiscreetLength, setDiscreetScaleModel, setGraphLook, setLegendModel, setNumericLength, setNumericScaleModel, setStackModel |
Methods inherited from class li.netcat.chart.util.AbstractPart |
getChart, getPerspective, setChart, setPerspective |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public RingPart(ChartModel model)
RingPart
using the given ChartModel
and the type STACK_TYPE_STACKED_PERCENT
.
model
- The ChartModel
that provides the data. null
will be replaced by an empty ChartModel
.public RingPart(ChartModel model, int stackType)
RingPart
using the given ChartModel
and the given type.
model
- The ChartModel
that provides the data. null
will be replaced by an empty ChartModel
.stackType
- The type of the resulting graph. Specify one of
STACK_TYPE_NOT_STACKED
, STACK_TYPE_STACKED
or STACK_TYPE_STACKED_PERCENT
.
Note that values other than STACK_TYPE_STACKED_PERCENT
are not usual.Method Detail |
public float getFlatness()
public void setFlatness(float flatness)
flatness
- The maximum distance that the line segments used to
approximate the curved segments are allowed. It must be >= 0.001f.public void clearRadialMove()
public void setRadialMove(int rowIndex, int columnIndex, float move)
rowIndex
- The row index of the data element in the model.columnIndex
- The column index of the data element in the model.move
- The amount of the movement in pixel. Negative values move the element towards the center.public float getRadialMove(int rowIndex, int columnIndex)
rowIndex
- The row index of the data element in the model.columnIndex
- The column index of the data element in the model.public ValueLocation getValueLocation(int rowIndex, int columnIndex)
GraphPart
ValueLocation
for a given cell.
getValueLocation
in class PolarGraphPart
public Layout getLayout(java.awt.Graphics g)
Part
g
- The relevant graphics object.
null
.
|
ChartCat 1.2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |