|
JIDE 3.5.15 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent com.jidesoft.chart.Chart
public class Chart
The main charting component. By default, used for XY charts, categorical charts, time series charts and bar charts. Also used for pie charts by changing the chartType property.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
Chart()
Zero-argument Constructor |
|
Chart(ChartModel model)
Create a chart from the supplied model |
|
Chart(Dimension size)
Creates a Chart, and sets its size (and preferred size) to be the supplied dimensions. |
|
Chart(String name)
The idea of this constructor is to encourage the naming of chart components. |
Method Summary | |
---|---|
void |
addDoubleClickListener(ActionListener listener)
|
Chart |
addDrawable(Drawable d)
Adds an object that implements the drawable callback method. |
Chart |
addModel(ChartModel newModel)
Adds the supplied ChartModel to the Chart so that it is drawn in the chart area. |
Chart |
addModel(ChartModel model,
Axis axis)
Adds the supplied ChartModel to the Chart, also assigning the model to the supplied axis. |
Chart |
addModel(ChartModel model,
Axis axis,
ChartStyle style)
Adds the supplied ChartModel to the Chart, also assigning the model to the supplied axis. |
Chart |
addModel(ChartModel model,
boolean makeDirty)
Adds the supplied ChartModel to the Chart, but does not force a repaint. |
Chart |
addModel(ChartModel model,
ChartStyle style)
Adds the supplied ChartModel to the Chart, also assigning the supplied style to the chart. |
Chart |
addMousePanner()
Makes it possible for the user to 'pan' the chart easily by clicking and dragging the mouse. |
Chart |
addMousePanner(boolean horizontalPan,
boolean verticalPan)
Make it possible for the user to pan the chart easily, but specifying whether panning is allowed in the horizontal and/or vertical axes. |
Chart |
addMouseZoomer()
A convenience method for easily adding a mouse wheel zoom facility to a chart |
Chart |
addMouseZoomer(boolean horizontalZoom,
boolean verticalZoom)
Adds a MouseWheelZoomer to this chart instance, and specifies whether zooming should be enabled in the horizontal and vertical directions. |
Chart |
addYAxis(Axis newAxis)
Adds a y axis |
void |
autoRange()
Causes the ranges of the chart to be adjusted according to the data. |
int |
axisWidth(Graphics g,
Axis axis)
Returns the width of the supplied axis due to the rendering of ticks and tick labels (but not the main axis label) |
Point |
calculatePixelPoint(Point2D userPoint)
Calculate the pixel coordinates of a point using the default y axis. |
Point |
calculatePixelPoint(Point2D userPoint,
Axis axis)
Calculate the pixel coordinates of a point using the supplied y axis |
Point |
calculatePixelPoint(Point2D userPoint,
UserToPixelTransform transform)
Calculates the pixel point using the supplied transform. |
Point2D |
calculatePixelPoint2D(Point2D userPoint)
Calculate the pixel coordinates of a point using the default y axis. |
Point2D |
calculatePixelPoint2D(Point2D userPoint,
Axis axis)
Calculate the pixel coordinates of a point using the supplied y axis |
Point2D |
calculatePixelPoint2D(Point2D userPoint,
UserToPixelTransform transform)
|
Point2D |
calculateUserPoint(Point p)
Calculates the point in the user's coordinate system for the pixel coordinate given by p . |
void |
chartModelChanged()
This is the method of the ChartModelListener interface; it is called whenever the chart model has changed and all points need to be updated. |
void |
chartModelChanged(ChartModelChangeEvent changeEvent)
This method is called to inform the ChartModelChangeListener of an event that changed the ChartModel to which the listener is attached. |
Chart |
clearHighlights()
Removes all known highlights and their associated styles from this class |
PointDescriptor |
containingBar(Point p)
You can use this method to test whether the supplied pixel point is contained by the rendering of a bar. |
PointDescriptor |
containingPoint(Point p)
Determines whether the supplied pixel point is contained by the rendering of a (model) point in a chart. |
Collection<PointDescriptor> |
containingPoints(Point p)
Returns a collection of descriptors for all (model) points rendered at the supplied pixel point |
PointDescriptor |
containingSegment(Point p)
Determines whether the supplied pixel point is contained by the rendering of a segment in a pie chart. |
PointDescriptor |
containingShape(Point p)
Determines whether there is a shape rendered that contains the supplied pixel point. |
Collection<PointDescriptor> |
containingShapes(Point p)
Returns point descriptors for all the Chartables rendered at the specified point |
boolean |
containsDrawable(Drawable drawable)
Determines whether this chart object already contains the supplied Drawable. |
boolean |
containsModel(ChartModel model)
Returns a boolean to indicate whether the supplied model is known to this Chart instance |
double |
convertPrimaryToY(double primaryY,
Axis yAxis)
Converts a point scaled against the primary yAxis to its equivalent point on the supplied y Axis Note that this will not work with a logarithmic range |
double |
convertYToPrimary(double userY,
Axis yAxis)
Converts a point scaled against the supplied yAxis to its equivalent point on the primary y axis. |
JToolTip |
createToolTip()
This fixes a painting problem with the shadow rendering code when a tool tip disappears. |
static double |
distance(Point2D point,
Chartable chartable)
|
static double |
distanceSq(Point2D point,
Chartable chartable)
|
void |
drawInBackground()
You should not need to call this method often. |
protected boolean |
drawRotatedStringIfWithinBounds(Graphics g,
String s,
int x,
int y,
double rotation)
|
protected boolean |
drawStringIfWithinBounds(Graphics g,
String s,
int x,
int y)
Paints a string but only if the whole of the string will be visible according to the bounds of the component |
void |
drawXAxisTickLabel(Graphics g,
Axis axis,
String s,
int x,
int y)
Draws a tick label onto the Graphics context. |
protected void |
drawYAxisTickLabel(Graphics g,
Axis yAxis,
String s,
int x,
int y)
|
double |
getAnimationPosition()
Get the current animation position, 0.0 is the start and 1.0 is the end |
AutoRanger |
getAutoRanger()
Returns the autoRanger used for setting the ranges of the axes |
Color |
getAxisColor()
Returns the color of the axes |
Axis |
getAxisForModel(ChartModel model)
|
int |
getAxisLabelPadding()
Returns the padding around the axis labels. |
int |
getBarGap()
|
int |
getBarGroupGap()
|
BarRenderer |
getBarRenderer()
|
BarRenderer |
getBarRenderer(ChartModel model)
Returns the bar renderer associated with the given model. |
BarResizePolicy |
getBarResizePolicy()
|
Paint |
getChartBackground()
Returns the background used for the area displaying the chart |
Border |
getChartBorder()
Returns the border used to surround the chart area |
int |
getChartHeight()
|
ChartType |
getChartType()
|
int |
getChartWidth()
|
Chartable |
getCurrentChartPoint()
|
Collection<Drawable> |
getDrawables()
Returns a Collection of Drawable objects known by the Chart |
Color |
getGridColor()
Returns the color used for the grid |
ChartStyle |
getHighlightStyle(Highlight h)
Retrieves the ChartStyle associated with the supplied highlight |
Stroke |
getHorizontalGridStroke()
Returns the Stroke used for the style of horizontal lines of the grid corresponding to major ticks |
Stroke |
getHorizontalMinorGridStroke()
Returns the Stroke currently used for horizontal lines of the grid corresponding to minor ticks |
Color |
getLabelColor()
Returns the color of the axis labels |
com.jidesoft.chart.LazyRenderer<ChartModel> |
getLazyChartRenderer()
|
int |
getLazyRenderingThreshold()
Returns the total size that data sets must be before switching to lazy rendering |
LineRenderer |
getLineRenderer()
|
LineRenderer |
getLineRenderer(ChartModel model)
Returns the line renderer associated with the given model. |
int |
getMaxBarWidth()
Get the current maximum bar width. |
Color |
getMinorGridColor()
Returns the color used for the minor grid lines |
protected Color |
getMinorTickColor(Axis axis)
Finds the minor tick color to use for the supplied axis. |
int |
getMinorTickLength()
Returns the length of minor ticks, in pixels |
ChartModel |
getModel()
|
ChartModel |
getModel(int i)
|
ChartModel |
getModel(String modelName)
Returns the model with the specified name; null otherwise |
List<ChartModel> |
getModels()
|
Paint |
getPanelBackground()
Returns the background used for the area surrounding the main chart area |
Integer |
getPieDiameter()
Returns the diameter of the pie chart in pixels, or null if no pixel diameter has been specified. |
PieSegmentRenderer |
getPieSegmentRenderer()
|
PointRenderer |
getPointRenderer()
|
PointRenderer |
getPointRenderer(ChartModel model)
Returns the point renderer associated with the given model. |
ListSelectionModel |
getSelectionsForModel(ChartModel model)
|
ShadowRenderer |
getShadowRenderer()
|
ShadowVisibility |
getShadowVisibility()
|
ChartStyle |
getStyle(ChartModel model)
Returns the Chart Style associated with the supplied chart model, or null if there is no style associated with the model. |
Color |
getTickColor()
Returns the current tick color |
protected Color |
getTickColor(Axis axis)
Returns the tick color to use when painting (a major tick) on an axis. |
Font |
getTickFont()
Returns the font used when painting tick labels. |
protected Font |
getTickFont(Axis axis)
Returns the font to use for painting tick labels on the supplied axis. |
int |
getTickLength()
Returns the length of major ticks, in pixels |
Stroke |
getTickStroke()
Returns the stroke used when painting ticks |
AbstractAnnotation |
getTitle()
Returns the current title of the chart |
UserToPixelTransform |
getTransformForAxis(Axis yAxis)
Returns the Affine Transform associated with the given y axis |
UserToPixelTransform |
getTransformForModel(ChartModel model)
|
UserToPixelTransform |
getUserToPixelTransform()
Returns the transformation from user coordinates to pixel coordinates |
Stroke |
getVerticalGridStroke()
Returns the Stroke currently used for vertical lines of the grid corresponding to major ticks |
Stroke |
getVerticalMinorGridStroke()
Returns the Stroke currently used for vertical lines of the grid corresponding to minor ticks |
Axis |
getXAxis()
Returns the chart's x axis |
int |
getXEnd()
|
int |
getXStart()
|
Axis |
getYAxis()
Returns the primary y axis. |
Axis |
getYAxis(int n)
Returns the nth y axis (indexed from zero) |
int |
getYAxisCount()
Returns the number of y axes |
int |
getYEnd()
|
int |
getYStart()
|
double |
getYSum(ChartModel model)
|
Integer |
getZOrder(ChartModel model)
|
protected void |
init()
Initialise the component by setting defaults and listeners |
int |
interpolateXForAnimation(int inputX,
ChartModel model)
Transforms an input x value to a value used during the animateOnShow phase |
int |
interpolateYForAnimation(int inputY,
ChartModel model)
Transforms an input y value to a value used during the animateOnShow phase |
boolean |
isAllowTickLabelOverlap()
Returns a value to indicate whether tick label overlaps are currently allowed |
boolean |
isAnimateOnShow()
Get if the animation should start when the chart is first drawn to screen. |
boolean |
isAntiAliasing()
Returns whether anti-aliasing is currently being used when drawing the main chart |
boolean |
isAutoRanging()
Returns whether we currently have auto-ranging switched on |
boolean |
isBarsGrouped()
|
boolean |
isHighQuality()
|
boolean |
isHorizontalGridLinesVisible()
Returns whether the horizontal grid lines corresponding to major ticks on the y axis are visible |
boolean |
isHorizontalMinorGridLinesVisible()
Returns whether the horizontal grid lines corresponding to minor ticks on the y axis are visible |
boolean |
isLabellingTraces()
|
boolean |
isLazyRendering()
Returns a boolean to indicate whether lazy rendering is currently being used |
boolean |
isPixelPointViewable(int x,
int y)
|
boolean |
isRecordingShapes()
Return a boolean to indicate whether we are recording the shapes for points and bars |
boolean |
isRolloverEnabled()
|
boolean |
isSelectionEnabled()
|
boolean |
isSelectionShowsExplodedSegments()
|
boolean |
isSelectionShowsOutline()
|
boolean |
isShadowVisible()
Returns a boolean to indicate whether shadows are being applied to elements of the chart |
boolean |
isShadowVisible(ChartModel model)
Returns a boolean to indicate whether shadows have been applied to the specified model |
boolean |
isTitleVisible()
Returns a boolean to indicate whether the chart should display a title |
boolean |
isUserPointViewable(Point2D userPoint,
ChartModel model)
We need to specify which model the point belongs to, so that we know which axis and therefore which point ranges to apply. |
boolean |
isVerticalGridLinesVisible()
Returns whether the vertical lines corresponding to major ticks on the x axis are visible |
boolean |
isVerticalMinorGridLinesVisible()
Returns whether the vertical grid lines corresponding to minor ticks on the x axis are visible |
int |
modelCount()
The number of chart models currently loaded into the chart component |
ChartModel |
nearestModel(Point p)
Note that the current implementation may take some time to execute for larger data sets. |
Pair<Chartable,Double> |
nearestPoint(Point2D realPoint,
ChartModel model)
Returns the nearest point in a model to the specified real point. |
PointSelection |
nearestPoint(Point hitPoint,
ChartModel model)
Returns the nearest point to a specified pixel point from a given ChartModel. |
Collection<ChartModel> |
nearLine(Point p,
float radius)
Determines whether there is a line segment close to p, within a supplied 'radius'. |
protected void |
paintAnnotations(Graphics2D g)
|
protected void |
paintAxes(Graphics2D g)
Paint all axes |
protected void |
paintComponent(Graphics g)
|
protected void |
paintHorizontalGrid(Graphics g,
Axis axis,
UserToPixelTransform transform)
|
protected void |
paintModels(Graphics2D g,
Graphics2D shadowGraphics,
Shape clipBounds,
Shape chartAreaClip)
|
protected void |
paintXAxis(Graphics2D g)
Paints the X axis onto the Graphics context |
protected void |
paintXAxisGridLines(Graphics2D g,
Tick[] ticks)
|
protected void |
paintXAxisTicks(Graphics2D g,
Tick[] ticks)
|
protected void |
paintYAxis(Graphics2D g,
Axis axis,
int xPosition)
Paint a single Y axis |
protected void |
paintYAxisLabels(Graphics2D g)
Paint all y axis tick labels |
void |
paintYAxisTicks(Graphics g,
Axis axis,
Point midPoint,
int xPixelCoord)
|
protected void |
paintYAxisTicks(Graphics g,
Axis axis,
UserToPixelTransform transform,
Point midPoint,
int xPixelCoord)
|
int |
pointCount()
|
void |
propertyChange(PropertyChangeEvent pce)
|
void |
removeDoubleClickListener(ActionListener listener)
|
Chart |
removeDrawable(Drawable d)
Removes a drawable from the chart (and all references to the Drawable from the chart object too). |
Chart |
removeDrawables()
Removes all drawables from the chart |
Chart |
removeModel(ChartModel model)
Removes the chart model from the chart. |
Chart |
removeModels()
Stops any background drawing, and removes all the known ChartModels by repeated calls to removeModel() |
Chart |
removeMousePanner()
Remove the panning ability for this chart. |
Chart |
removeMouseZoomer()
Removes any MouseWheelZoomer that was created using one of the addMouseZoomer methods. |
PointDescriptor |
rendered(Chartable chartable)
|
Shape |
renderedAs(Chartable chartable)
Returns the shape that is being used to render the supplied chartable point, or null if not known. |
Chart |
replaceModel(ChartModel oldModel,
ChartModel newModel)
Allows you to replace an existing chart model with a new instance with the same model name. |
void |
setAllowTickLabelOverlap(boolean allowTickLabelOverlap)
Specify whether tick labels are allowed to overlap. |
void |
setAnimateOnShow(boolean animateOnShow)
Specify whether the chart should updateChart the appearance of the chart when first shown |
void |
setAnimationPosition(double position)
Specify the animation position as a value from 0 (the initial position) to 1 (the final position). |
void |
setAntiAliasing(boolean antiAliasing)
Specify whether to use anti-aliasing when drawing. |
void |
setAutoRanger(AutoRanger autoRanger)
Specify the class used to implemented an auto-ranging policy |
void |
setAutoRanging(boolean autoRanging)
Specify whether to compute ranges for the axes automatically, based on the data seen. |
void |
setAxisColor(Color axisColor)
Specify the color to use for the axes |
void |
setAxisLabelPadding(int axisLabelPadding)
Specify the padding around the axis labels measured in pixels. |
void |
setBackground(Color background)
Sets the background for a chart. |
void |
setBarGap(int barGap)
Specify the pixel gap between bars in a bar chart |
void |
setBarGroupGap(int barGroupGap)
Specify the gap (in pixels) between groups of bars in a grouped bar chart |
void |
setBarGroupGapProportion(Double barGroupGapProportion)
Specify the size of the group gap as a proportion of the space available to the group. |
void |
setBarRenderer(BarRenderer barRenderer)
Specify the bar renderer to use |
void |
setBarRenderer(ChartModel model,
BarRenderer barRenderer)
Specify the bar renderer to use for the given model. |
void |
setBarResizePolicy(BarResizePolicy policy)
Specify the bar resize policy when bars are assigned a width and the space available does not match the widths |
void |
setBarsGrouped(boolean barsGrouped)
Specify whether bars should be grouped or stacked when they have the same axis value |
void |
setChartBackground(Paint chartBackground)
Specify the paint to use for the main chart area. |
void |
setChartBorder(Border chartBorder)
Specify the border to use around the chart area |
void |
setChartType(ChartType chartType)
Specify the type of chart, eg. |
void |
setGridColor(Color gridColor)
Specify the color to use for the grid |
void |
setHighlightStyle(Highlight highlight,
ChartStyle style)
Specifies a ChartStyle to be associated with the given Highlight |
void |
setHighQuality(boolean highQuality)
Specify whether to invest additional computational effort to try to avoid the possibility of pixel value rounding errors. |
void |
setHorizontalGridLinesVisible(boolean gridLinesVisible)
Specify whether horizontal grid lines should be visible |
void |
setHorizontalGridStroke(Stroke horizontalGridStroke)
Sets the stroke used for the style of horizontal lines in the grid of an XY chart |
void |
setHorizontalMinorGridLinesVisible(boolean horizontalMinorGridLinesVisible)
|
void |
setHorizontalMinorGridStroke(Stroke stroke)
Sets the stroke to use when painting horizontal grid lines that correspond to minor ticks |
void |
setLabelColor(Color labelColor)
Specify the color to use for the labels of the axes |
void |
setLabellingTraces(boolean labellingTraces)
|
void |
setLazyChartRenderer(com.jidesoft.chart.LazyRenderer<ChartModel> lazyChartRenderer)
Specify the lazy chart renderer to use |
void |
setLazyChartRenderer(com.jidesoft.chart.LazyRenderer<ChartModel> lazyChartRenderer,
boolean autoRefresh)
|
void |
setLazyRenderingThreshold(int lazyRenderingThreshold)
How large does a data set have to be before we switch into lazy rendering mode? |
void |
setLineRenderer(ChartModel model,
LineRenderer lineRenderer)
Specify the line renderer to use for the given model. |
void |
setLineRenderer(LineRenderer lineRenderer)
Specify the renderer to use for drawing lines in a chart |
void |
setMaxBarWidth(int maxBarWidth)
Specify the maximum width for a bar in a bar chart. |
void |
setMinorGridColor(Color minorGridColor)
|
void |
setMinorTickLength(int minorTickLength)
Specify the length of minor ticks, in pixels |
void |
setModel(ChartModel model)
First removes any models held by this object, then sets the supplied model as the single known model. |
void |
setModel(ChartModel model,
ChartStyle style)
First removes any models held by this object, then sets the supplied model as the single known model with the supplied style |
void |
setModelAxis(ChartModel model,
Axis axis)
Asserts that the supplied model should be plotted against the supplied axis rather than the default axis |
void |
setPanelBackground(Paint background)
Note that we can't call this method setBackground, as that method already exists and expects a Color rather than a Paint. |
void |
setPieDiameter(Integer diameter)
Specify the diameter of the pie chart, in pixels. |
void |
setPieSegmentRenderer(PieSegmentRenderer segmentRenderer)
Specify the renderer to use for drawing pie charts |
void |
setPointRenderer(ChartModel model,
PointRenderer pointRenderer)
Specify the point renderer to use for the given model. |
void |
setPointRenderer(PointRenderer pointRenderer)
Specify the point renderer to use |
void |
setRecordingShapes(boolean recordingShapes)
Specify whether we want to record the shapes that are drawn out by the point and bar renderers. |
void |
setRolloverEnabled(boolean rollover)
|
void |
setSelectionEnabled(boolean selectable)
Specify whether the displayed chart should respond to selections. |
void |
setSelectionsForModel(ChartModel chartModel,
ListSelectionModel selectionModel)
|
void |
setSelectionShowsExplodedSegments(boolean selectionShowsExplodedSegments)
Specify whether to use an explosion effect to indicate selection of segments |
void |
setSelectionShowsOutline(boolean selectionShowsOutline)
Specify whether segment selection should be indicated by an outline on the segment |
void |
setShadowRenderer(ShadowRenderer shadowRenderer)
|
void |
setShadowVisibility(ShadowVisibility shadowVisibility)
You can use this property to be more selective about which elements in a chart cast a shadow |
void |
setShadowVisible(boolean shadowVisible)
Use to specify whether shadows should be drawn under lines, points etc. |
void |
setShadowVisible(ChartModel model,
boolean shadowVisible)
Marks the specified model with the given shadow visibility. |
void |
setStyle(ChartModel model,
ChartStyle style)
Applies the supplied chart style to the specified chart model |
void |
setStyle(ChartModel model,
ChartStyle style,
boolean makeDirty)
Applies the supplied chart style to the specified chart model, and additionally allows the caller to specify whether the change should trigger a repaint. |
void |
setTickColor(Color tickColor)
Specify the color to use for ticks along the axes |
void |
setTickFont(Font font)
Specify the font used for tick labels. |
void |
setTickLength(int tickLength)
Specify the length of major ticks, in pixels |
void |
setTickStroke(Stroke tickStroke)
Specify the stroke used when painting ticks |
void |
setTitle(AbstractLabel title)
Specify the title of the chart |
void |
setTitle(String title)
Sets the (optional) title for the chart |
void |
setTitleVisible(boolean titleVisible)
Specify whether the chart should display a title |
void |
setVerticalGridLinesVisible(boolean gridLinesVisible)
Specify whether the vertical lines of the grid should be painted |
void |
setVerticalGridStroke(Stroke verticalGridStroke)
Sets the stroke used for the style of vertical lines in the grid of an XY chart |
void |
setVerticalMinorGridLinesVisible(boolean verticalMinorGridLinesVisible)
|
void |
setVerticalMinorGridStroke(Stroke stroke)
Specify the Stroke to use when painting vertical grid lines that correspond to minor ticks on the x axis |
void |
setXAxis(Axis axis)
Set the x axis |
void |
setYAxis(Axis newAxis)
Set the primary y axis |
void |
setZOrder(ChartModel model,
Integer zOrder)
Specify the z order of a model. |
void |
startAnimation()
Explicitly start the animation |
void |
stopAnimation()
Explicitly stop the animation |
int |
titleHeight()
|
void |
update()
Updates margins and coordinate systems according to the size of the component. |
protected void |
update(boolean canInvokeLazyRenderer)
Updates margins and coordinate systems according to the size of the component. |
void |
updateUI()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final String PROPERTY_ANIMATE_ON_SHOW
public static final String PROPERTY_ANIMATION_POSITION
public static final String PROPERTY_ANTI_ALIASING
public static final String PROPERTY_AUTO_RANGING
public static final String PROPERTY_AXIS_COLOR
public static final String PROPERTY_BAR_RENDERER
public static final String PROPERTY_BAR_GAP
public static final String PROPERTY_BAR_GROUP_GAP
public static final String PROPERTY_BARS_GROUPED
public static final String PROPERTY_CHART_BACKGROUND
public static final String PROPERTY_CHART_BORDER
public static final String PROPERTY_CURRENT_CHART_POINT
public static final String PROPERTY_CHART_TYPE
public static final String PROPERTY_GRID_COLOR
public static final String PROPERTY_HIGHLIGHT_STYLE
public static final String PROPERTY_HIGH_QUALITY
public static final String PROPERTY_HORIZONTAL_GRID_LINES_VISIBLE
public static final String PROPERTY_HORIZONTAL_MINOR_GRID_LINES_VISIBLE
public static final String PROPERTY_HORIZONTAL_MINOR_GRID_STROKE
public static final String PROPERTY_HORIZONTAL_GRID_STROKE
public static final String PROPERTY_LABEL_COLOR
public static final String PROPERTY_LABELLING_TRACES
public static final String PROPERTY_LAZY_RENDERING_THRESHOLD
public static final String PROPERTY_LINE_RENDERER
public static final String PROPERTY_MAX_BAR_WIDTH
public static final String PROPERTY_MINOR_GRID_COLOR
public static final String PROPERTY_MODEL
public static final String PROPERTY_PANEL_BACKGROUND
public static final String PROPERTY_PIE_DIAMETER
public static final String PROPERTY_PIE_SEGMENT_RENDERER
public static final String PROPERTY_POINT_RENDERER
public static final String PROPERTY_ROLLOVER_VISIBLE
public static final String PROPERTY_SELECTABLE
public static final String PROPERTY_SELECTION_SHOWS_EXPLODED_SEGMENTS
public static final String PROPERTY_SELECTION_SHOWS_OUTLINE
public static final String PROPERTY_SHADOW_RENDERER
public static final String PROPERTY_SHADOW_VISIBLE
public static final String PROPERTY_SHADOW_VISIBILITY
public static final String PROPERTY_CHART_STYLE
public static final String PROPERTY_TICK_COLOR
public static final String PROPERTY_TICK_STROKE
public static final String PROPERTY_TICK_FONT
public static final String PROPERTY_TICK_LENGTH
public static final String PROPERTY_MINOR_TICK_LENGTH
public static final String PROPERTY_ALLOW_TICK_LABEL_OVERLAP
public static final String PROPERTY_TITLE
public static final String PROPERTY_TITLE_VISIBLE
public static final String PROPERTY_VERTICAL_GRIDLINES_VISIBLE
public static final String PROPERTY_VERTICAL_GRID_LINES_VISIBLE
public static final String PROPERTY_VERTICAL_MINOR_GRIDLINES_VISIBLE
public static final String PROPERTY_VERTICAL_MINOR_GRID_LINES_VISIBLE
public static final String PROPERTY_VERTICAL_MINOR_GRID_STROKE
public static final String PROPERTY_VERTICAL_GRID_STROKE
public static final String PROPERTY_X_AXIS
public static final String PROPERTY_Y_AXIS
Constructor Detail |
---|
public Chart()
public Chart(ChartModel model)
model
- the model that will be used initially by the Chartpublic Chart(String name)
setName
method, but many programmers do not use this method. Naming the chart instance is optional
but can help with testing and debugging, especially if you are using more than one chart instance.
name
- the name of the Chart instancepublic Chart(Dimension size)
size
- the size of the chartMethod Detail |
---|
protected void init()
public void updateUI()
updateUI
in class JComponent
public void setZOrder(ChartModel model, Integer zOrder)
model
- the model whose z order we wish to setzOrder
- the z order for the specified model (a positive integer)public Integer getZOrder(ChartModel model)
public ChartType getChartType()
public void setChartType(ChartType chartType)
chartType
- the new chart typepublic ShadowRenderer getShadowRenderer()
public void setShadowRenderer(ShadowRenderer shadowRenderer)
public PointRenderer getPointRenderer()
public void setPointRenderer(PointRenderer pointRenderer)
pointRenderer
- the new point rendererpublic PointRenderer getPointRenderer(ChartModel model)
model
- the chart model we are interested in
public void setPointRenderer(ChartModel model, PointRenderer pointRenderer)
setPointRenderer(PointRenderer)
.
model
- the model with which the renderer is associatedpointRenderer
- the point rendererpublic LineRenderer getLineRenderer(ChartModel model)
model
- the chart model we are interested in
public void setLineRenderer(ChartModel model, LineRenderer lineRenderer)
setLineRenderer(LineRenderer)
.
model
- the model with which the renderer is associatedlineRenderer
- the line rendererpublic BarRenderer getBarRenderer()
public void setBarRenderer(BarRenderer barRenderer)
barRenderer
- the new bar rendererpublic BarRenderer getBarRenderer(ChartModel model)
model
- the chart model we are interested in
public void setBarRenderer(ChartModel model, BarRenderer barRenderer)
setBarRenderer(BarRenderer)
.
model
- the model with which the renderer is associatedbarRenderer
- the bar rendererpublic boolean isRecordingShapes()
public void setRecordingShapes(boolean recordingShapes)
recordingShapes
- whether to record the shapes for the points and barspublic void setPieDiameter(Integer diameter)
null
), a 'best fit' size will be calculated.
diameter
- the new diameter of pie chartspublic Integer getPieDiameter()
public Stroke getHorizontalGridStroke()
public Stroke getHorizontalMinorGridStroke()
public void setHorizontalMinorGridStroke(Stroke stroke)
stroke
- the stroke to use when painting horizontal grid lines that correspond to minor tickspublic void setHorizontalGridStroke(Stroke horizontalGridStroke)
horizontalGridStroke
- the new Strokepublic Stroke getVerticalGridStroke()
public void setVerticalGridStroke(Stroke verticalGridStroke)
verticalGridStroke
- the new Strokepublic Stroke getVerticalMinorGridStroke()
public void setVerticalMinorGridStroke(Stroke stroke)
stroke
- the stroke to use when painting vertical grid lines corresponding to minor ticks on the x axispublic Chartable getCurrentChartPoint()
public Shape renderedAs(Chartable chartable)
chartable
- the point in the model for which we would like to know the rendered shape
public PointDescriptor rendered(Chartable chartable)
public PointDescriptor containingShape(Point p)
p
- a coordinate in pixel space
public Collection<PointDescriptor> containingShapes(Point p)
p
- the specified pixel point
public PointDescriptor containingBar(Point p)
p
- the point to be tested
public PointDescriptor containingSegment(Point p)
p
- a coordinate in pixel space
public Collection<ChartModel> nearLine(Point p, float radius)
p
- the point of interestradius
- the allowed distance from a line at which the line is said to 'contain' the point
public PointDescriptor containingPoint(Point p)
p
- a coordinate in pixel space
public Collection<PointDescriptor> containingPoints(Point p)
p
- a coordinate in pixel space
public PieSegmentRenderer getPieSegmentRenderer()
public void setPieSegmentRenderer(PieSegmentRenderer segmentRenderer)
segmentRenderer
- the new pie segment rendererpublic LineRenderer getLineRenderer()
public void setLineRenderer(LineRenderer lineRenderer)
lineRenderer
- the new line rendererpublic void setBarGap(int barGap)
barGap
- the new pixel gappublic int getBarGap()
public void setMaxBarWidth(int maxBarWidth)
maxBarWidth
- the new maximum widthpublic int getMaxBarWidth()
public int getBarGroupGap()
public void setBarGroupGap(int barGroupGap)
barGroupGap
- the new gap between groups of barspublic void setBarGroupGapProportion(Double barGroupGapProportion)
setBarGroupGap
)
will be used instead.
barGroupGapProportion
- the size of the group gap as a proportion of the space available to the grouppublic void setBarsGrouped(boolean barsGrouped)
barsGrouped
- whether bars should be grouped (if not grouped they are stacked)public boolean isBarsGrouped()
public void setBarResizePolicy(BarResizePolicy policy)
policy
- the bar resize policypublic BarResizePolicy getBarResizePolicy()
public boolean isHighQuality()
public void setHighQuality(boolean highQuality)
highQuality
- whether to try to avoid pixel value rounding errorspublic boolean isVerticalGridLinesVisible()
public boolean isVerticalMinorGridLinesVisible()
public void setVerticalMinorGridLinesVisible(boolean verticalMinorGridLinesVisible)
public void setVerticalGridLinesVisible(boolean gridLinesVisible)
gridLinesVisible
- should the lines be painted?public boolean isHorizontalGridLinesVisible()
public boolean isHorizontalMinorGridLinesVisible()
public void setHorizontalGridLinesVisible(boolean gridLinesVisible)
gridLinesVisible
- whether horizontal grid lines are to be visiblepublic void setHorizontalMinorGridLinesVisible(boolean horizontalMinorGridLinesVisible)
public boolean isTitleVisible()
public void setTitleVisible(boolean titleVisible)
titleVisible
- whether to display a title for the chartpublic Font getTickFont()
setTickFont()
adjusts the tick font for both axes, but must be called after the
axes have been configured on the chart.
protected Font getTickFont(Axis axis)
axis
- the axis of interest
public void setTickFont(Font font)
font
- the font to be used for tick labelspublic Stroke getTickStroke()
public void setTickStroke(Stroke tickStroke)
tickStroke
- the stroke to use when painting tickspublic Color getAxisColor()
public void setAxisColor(Color axisColor)
axisColor
- the new axis colorpublic Color getGridColor()
public void setGridColor(Color gridColor)
gridColor
- the new color for the grid linespublic Color getMinorGridColor()
public void setMinorGridColor(Color minorGridColor)
public Paint getPanelBackground()
getChartBackground()
public void setPanelBackground(Paint background)
setBackground(java.awt.Color)
,
setChartBackground(java.awt.Paint)
public void setBackground(Color background)
setBackground
in class JComponent
background
- the background color of the chart.setChartBackground(java.awt.Paint)
public Paint getChartBackground()
getPanelBackground()
public void setChartBackground(Paint chartBackground)
chartBackground
- the new paint to usesetPanelBackground(java.awt.Paint)
public Border getChartBorder()
public void setChartBorder(Border chartBorder)
chartBorder
- the border for the chart areapublic UserToPixelTransform getUserToPixelTransform()
public boolean isAntiAliasing()
public void setAntiAliasing(boolean antiAliasing)
antiAliasing
- whether to use anti-aliasingpublic boolean isAllowTickLabelOverlap()
public void setAllowTickLabelOverlap(boolean allowTickLabelOverlap)
allowTickLabelOverlap
- whether to allow tick labels to overlappublic boolean isAutoRanging()
public void setAutoRanging(boolean autoRanging)
autoRanging
- a boolean to specify whether auto-ranging should be switched onpublic void setAutoRanger(AutoRanger autoRanger)
autoRanger
- the class that implements the auto-ranging policypublic AutoRanger getAutoRanger()
public boolean isLabellingTraces()
public void setLabellingTraces(boolean labellingTraces)
public Chart addMouseZoomer()
public Chart addMouseZoomer(boolean horizontalZoom, boolean verticalZoom)
horizontalZoom
- whether the zoom operates along the x axisverticalZoom
- whether the zoom operates along the y axis
public Chart removeMouseZoomer()
public Chart addMousePanner()
public Chart addMousePanner(boolean horizontalPan, boolean verticalPan)
horizontalPan
- do we allow horizontal panningverticalPan
- do we allow vertical panning
public Chart removeMousePanner()
public void setRolloverEnabled(boolean rollover)
public boolean isRolloverEnabled()
public void setSelectionEnabled(boolean selectable)
selectable
- whether selection is switched onpublic boolean isSelectionEnabled()
public boolean isSelectionShowsExplodedSegments()
public void setSelectionShowsExplodedSegments(boolean selectionShowsExplodedSegments)
selectionShowsExplodedSegments
- used to specify whether selecting segments of a pie chart
will show those segments as 'exploded' away from the rest of the piepublic boolean isSelectionShowsOutline()
public void setSelectionShowsOutline(boolean selectionShowsOutline)
selectionShowsOutline
- should selection outlines be visible?public void addDoubleClickListener(ActionListener listener)
public void removeDoubleClickListener(ActionListener listener)
public void chartModelChanged()
chartModelChanged
in interface ChartModelListener
public void chartModelChanged(ChartModelChangeEvent changeEvent)
chartModelChanged
in interface ChartModelChangeListener
changeEvent
- the ChartModelChangeEventpublic boolean isShadowVisible()
public void setShadowVisible(boolean shadowVisible)
setShadowVisible(true)
is equivalent to setShadowVisibility(ShadowVisibility.ALL);
and
setShadowVisible(false)
is equivalent to setShadowVisibility(ShadowVisibility.NONE)
.
shadowVisible
- boolean to indicate whether shadows should be drawnpublic ShadowVisibility getShadowVisibility()
public void setShadowVisibility(ShadowVisibility shadowVisibility)
public void setShadowVisible(ChartModel model, boolean shadowVisible)
model
- the model for which we wish to mark the shadow's visibilityshadowVisible
- whether the shadow is visiblepublic boolean isShadowVisible(ChartModel model)
model
- the chart model
public void autoRange()
public void update()
protected void update(boolean canInvokeLazyRenderer)
canInvokeLazyRenderer
- specify whether this method is allowed to explicitly invoke an update
on the lazy renderer. Use with caution as wrong usage can cause recursive
event loops.public void drawInBackground()
public void propertyChange(PropertyChangeEvent pce)
propertyChange
in interface PropertyChangeListener
public Chart addDrawable(Drawable d)
d
- the Drawable to add
public Chart removeDrawable(Drawable d)
Note: Make sure your Drawables have good implementations of equals() and hashCode()
d
- the Drawable to remove
public Chart removeDrawables()
public boolean containsDrawable(Drawable drawable)
drawable
- the Drawable object to test
public Collection<Drawable> getDrawables()
public int getAxisLabelPadding()
public void setAxisLabelPadding(int axisLabelPadding)
axisLabelPadding
- the gap between the axis label and the tick labels and the axis label and the edge of the
chart (or next axis)public int axisWidth(Graphics g, Axis axis)
public int titleHeight()
public int getXStart()
public int getXEnd()
public int getChartWidth()
public int getYStart()
For the y axis, the 'start' is the bottom of the chart region and therefore has a numeric value greater than or equal to the yEnd property
public int getYEnd()
For the y axis, the 'end' is at the top of the chart region
public int getChartHeight()
public double getYSum(ChartModel model)
model
- the model for which we wish to compute the sum of the y values
public int getTickLength()
public void setTickLength(int tickLength)
tickLength
- the new length for major tickspublic int getMinorTickLength()
public void setMinorTickLength(int minorTickLength)
minorTickLength
- the new length for minor tickspublic Color getTickColor()
public void setTickColor(Color tickColor)
tickColor
- the new tick colorpublic Color getLabelColor()
public void setLabelColor(Color labelColor)
labelColor
- the color to use for the labels of the axespublic void setXAxis(Axis axis)
axis
- the new x axispublic Axis getXAxis()
public void setYAxis(Axis newAxis)
newAxis
- the new y axispublic Chart addYAxis(Axis newAxis)
newAxis
- the new y axis
public Axis getYAxis()
public Axis getYAxis(int n)
n
- the index of the axis to return
public int getYAxisCount()
public void setTitle(String title)
title
- the new title of the chartpublic AbstractAnnotation getTitle()
public void setTitle(AbstractLabel title)
title
- the new title label for the chartpublic int getLazyRenderingThreshold()
public void setLazyRenderingThreshold(int lazyRenderingThreshold)
lazyRenderingThreshold
- the total number of points in all the loaded chart models before Chart starts using
lazy rendering. If this value is set to zero, then Chart automatically uses lazy
rendering.public com.jidesoft.chart.LazyRenderer<ChartModel> getLazyChartRenderer()
public void setLazyChartRenderer(com.jidesoft.chart.LazyRenderer<ChartModel> lazyChartRenderer)
lazyChartRenderer
- the lazy renderer of chartspublic void setLazyChartRenderer(com.jidesoft.chart.LazyRenderer<ChartModel> lazyChartRenderer, boolean autoRefresh)
public boolean isLazyRendering()
public void setModel(ChartModel model)
model
- the model to addpublic void setModel(ChartModel model, ChartStyle style)
model
- the model to addstyle
- the style of the modelpublic Chart addModel(ChartModel newModel)
The Chart instance should not already contain the supplied ChartModel.
newModel
- the ChartModel
being addedpublic Chart addModel(ChartModel model, boolean makeDirty)
model
- the model to add to the chartmakeDirty
- a boolean flag to indicate whether the chart should be marked as 'dirty' and in need of a repaintpublic Chart addModel(ChartModel model, ChartStyle style)
Note that storing
the style directly without making a separate call to setStyle
potentially saves a screen update, as
setStyle causes a repaint() itself.
model
- the new ChartModel to displaystyle
- the style of the added ChartModel
public Chart addModel(ChartModel model, Axis axis)
model
- the model to add to the Chartaxis
- the (y) axis to which the model is assigned
public Chart addModel(ChartModel model, Axis axis, ChartStyle style)
Note that storing the style directly without making a
separate call to setStyle
potentially saves a screen update, as setStyle causes a repaint()
itself.
model
- the model to add to the chartaxis
- the (y) axis to which the model is assignedstyle
- the style with which to paint the chart
public ChartModel getModel()
ChartModel
. Useful when we can safely assume that there is only one. Returns null
if there are no ChartModel
s.public ChartModel getModel(int i)
i
- - zero based index
ChartModel
public ChartModel getModel(String modelName)
modelName
- the name of the chart model to retrieve
public List<ChartModel> getModels()
public int modelCount()
public int pointCount()
public void setModelAxis(ChartModel model, Axis axis)
model
- the model whose axis we are settingaxis
- the (y) axis to associate with the modelpublic Axis getAxisForModel(ChartModel model)
public ListSelectionModel getSelectionsForModel(ChartModel model)
public void setSelectionsForModel(ChartModel chartModel, ListSelectionModel selectionModel)
public UserToPixelTransform getTransformForModel(ChartModel model)
public void setStyle(ChartModel model, ChartStyle style)
model
- the chart modelstyle
- the chart style to apply to the modelpublic void setStyle(ChartModel model, ChartStyle style, boolean makeDirty)
model
- the chart modelstyle
- the chart style to apply to the modelmakeDirty
- whether the component should become 'dirty' and therefore in need of a repaintpublic ChartStyle getStyle(ChartModel model)
model
- the chart model
NullPointerException
- if the supplied chart model is null or the name of the model is nullpublic void setHighlightStyle(Highlight highlight, ChartStyle style)
Highlight
highlight
- the highlight to which we are attaching a ChartStylestyle
- the ChartStyle associated with the Highlightpublic ChartStyle getHighlightStyle(Highlight h)
h
- the highlight of interest
public Chart clearHighlights()
public boolean containsModel(ChartModel model)
model
- the model of interest
public Chart removeModel(ChartModel model)
Removes the chart model from the chart.
Note that for this to work successfully, the hashCode() and equals() methods on the ChartModel class must be correctly implemented so if you notice your models are not being properly removed, this would be the first thing to check for.
model
- the model to removepublic Chart replaceModel(ChartModel oldModel, ChartModel newModel)
oldModel
- the old modelnewModel
- the new modelpublic Chart removeModels()
protected void paintComponent(Graphics g)
paintComponent
in class JComponent
public JToolTip createToolTip()
createToolTip
in class JComponent
public void paintYAxisTicks(Graphics g, Axis axis, Point midPoint, int xPixelCoord)
protected void paintHorizontalGrid(Graphics g, Axis axis, UserToPixelTransform transform)
protected void paintYAxisTicks(Graphics g, Axis axis, UserToPixelTransform transform, Point midPoint, int xPixelCoord)
protected boolean drawStringIfWithinBounds(Graphics g, String s, int x, int y)
g
- the Graphics
contexts
- the string to drawx
- the bottom left x coordinate of the drawn stringy
- the bottom left y coordinate of the drawn string
protected boolean drawRotatedStringIfWithinBounds(Graphics g, String s, int x, int y, double rotation)
g
- the Graphics context into which to draws
- the string to drawx
- the x coordinate of the centre of where the string should be drawny
- the y coordinate of the centre of where the string should be drawnrotation
- the rotation to use, in radians
public void drawXAxisTickLabel(Graphics g, Axis axis, String s, int x, int y)
g
- the Graphics context into which to drawaxis
- the Axis from which the tick comes. This is needed so we can find out the orientation and placement
for the texts
- the text string to drawx
- the x coordinate of the ticky
- the y coordinate of the tickprotected void paintYAxis(Graphics2D g, Axis axis, int xPosition)
g
- the Graphics contextaxis
- the y axis to paintxPosition
- the xPosition at which to paint the axisprotected void paintXAxis(Graphics2D g)
g
- the graphics contextprotected Color getTickColor(Axis axis)
axis
- the axis whose tick color is to be determined
protected Color getMinorTickColor(Axis axis)
axis
- the axis whose minor tick color is to be determined
protected void paintXAxisTicks(Graphics2D g, Tick[] ticks)
protected void paintXAxisGridLines(Graphics2D g, Tick[] ticks)
protected void paintAxes(Graphics2D g)
g
- the Graphics context onto which the axis will be painted The axis width needs to be calculated as the
width of a tick plus the width of a tick labelprotected void paintYAxisLabels(Graphics2D g)
g
- the Graphics context onto which the axis will be painted The axis width needs to be calculated as the
width of a tick plus the width of a tick labelprotected void drawYAxisTickLabel(Graphics g, Axis yAxis, String s, int x, int y)
public PointSelection nearestPoint(Point hitPoint, ChartModel model)
hitPoint
- the pixel point of interestmodel
- the ChartModel of interest
public ChartModel nearestModel(Point p)
public boolean isUserPointViewable(Point2D userPoint, ChartModel model)
public boolean isPixelPointViewable(int x, int y)
public Pair<Chartable,Double> nearestPoint(Point2D realPoint, ChartModel model)
nearestPoint(Point, ChartModel)
instead.
realPoint
- the position of the point of interest in user coordinatesmodel
- the ChartModel of interest
public static double distanceSq(Point2D point, Chartable chartable)
public static double distance(Point2D point, Chartable chartable)
public Point calculatePixelPoint(Point2D userPoint)
public Point2D calculatePixelPoint2D(Point2D userPoint)
public Point calculatePixelPoint(Point2D userPoint, Axis axis)
userPoint
- the point in user coordinatesaxis
- the y axis used for the y value
public Point2D calculatePixelPoint2D(Point2D userPoint, Axis axis)
userPoint
- the point in user coordinatesaxis
- the y axis used for the y value
public Point calculatePixelPoint(Point2D userPoint, UserToPixelTransform transform)
getTransformForAxis()
or getTransformForModel(ChartModel model)
.
userPoint
- the point in user coordinatestransform
- the transform used for the calculation. You do not create these, but retrieve them using the
supplied methods (see above).
public Point2D calculatePixelPoint2D(Point2D userPoint, UserToPixelTransform transform)
public Point2D calculateUserPoint(Point p)
p
. TODO: We
probably need a version of this method that accepts an axis, and uses the conversion appropriate for that axis.
p
- the point in pixel coordinates
public double convertYToPrimary(double userY, Axis yAxis)
userY
- the point scaled on the supplied y axisyAxis
- the y axis used for the supplied user point
public double convertPrimaryToY(double primaryY, Axis yAxis)
primaryY
- the value on the primary y axisyAxis
- the axis to which we need to convert the value
protected void paintModels(Graphics2D g, Graphics2D shadowGraphics, Shape clipBounds, Shape chartAreaClip)
public UserToPixelTransform getTransformForAxis(Axis yAxis)
yAxis
- the y axis for which we are retrieving the transform
protected void paintAnnotations(Graphics2D g)
public double getAnimationPosition()
Animatable
getAnimationPosition
in interface Animatable
public void setAnimationPosition(double position)
setAnimationPosition
in interface Animatable
public boolean isAnimateOnShow()
AnimatedChart
FALSE
the animation
will only run when startAnimation() is called.
isAnimateOnShow
in interface AnimatedChart
public void setAnimateOnShow(boolean animateOnShow)
setAnimateOnShow
in interface AnimatedChart
animateOnShow
- If TRUE
the chart will start animating on first drawpublic void startAnimation()
startAnimation
in interface AnimatedChart
public void stopAnimation()
stopAnimation
in interface AnimatedChart
public int interpolateXForAnimation(int inputX, ChartModel model)
inputX
- a pixel x coordinatemodel
- the chart model that uses the x coordinate
public int interpolateYForAnimation(int inputY, ChartModel model)
inputY
- a pixel y coordinatemodel
- the chart model that uses the y coordinate
|
JIDE 3.5.15 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |