com.ijchart.xychart.axis
Interface IAxis

All Known Implementing Classes:
AbstractAxis, AbstractNumberValueAxisWithType, AbstractValueAxis, BoxAndWhiskerValueAxis, CategoryAxis, CategoryAxis3D, DateValueAxis, ErrorValueAxis, GranttValueAxis, GroupCategoryAxis, GroupStackedNumberValueAxis, IntervalValueAxis, IntervalXNumberYBaseValueAxis, IntervalXYValueAxis, NumberValueAxis, NumberValueAxis3D, OHLCDateAxis, OHLCValueAxis, Stacked3DNumberValueAxis, StackedNumberValueAxis, StackedXYBarValueAxis, StackedXYValueAxis, StatisticalNumberValueAxis, SymbolValueAxis, WaterfallNumberValueAxis, WindValueAxis, XYNumberValueAxis, XYZNumberValueAxis, YIntervalValueAxis, ZNumberValueAxis

public interface IAxis

Title: IJChart

Description: a chart library for the Java(tm) platform.

Interface for draw axis on chart,all types of axis should implement this interface.

Copyright: Copyright (c) 2013

Company:

Version:
1.0
Author:
zhang feng min,shanghai china. Contract me by email.

Method Summary
 double calculateAxisSpace(java.awt.Graphics2D g2, java.awt.geom.Rectangle2D plotArea, java.awt.geom.Rectangle2D maxAxisArea, RectangleEdge edge)
           Calculation the width or height of painting coordinate axis.
 double draw(java.awt.Graphics2D g2, java.awt.geom.Rectangle2D plotArea, java.awt.geom.Rectangle2D axisArea, RectangleEdge edge, AxisShapeCollection shapeCollection, boolean alignEdge)
           Draw the X-axis or Y-axis on plot area(plotArea).All axis shape is stored in shapeCollection.
 double getFixedAxisSpace()
           Returns the fixed axis space.
 

Method Detail

draw

double draw(java.awt.Graphics2D g2,
            java.awt.geom.Rectangle2D plotArea,
            java.awt.geom.Rectangle2D axisArea,
            RectangleEdge edge,
            AxisShapeCollection shapeCollection,
            boolean alignEdge)
Draw the X-axis or Y-axis on plot area(plotArea).All axis shape is stored in shapeCollection.

Parameters:
g2 - Graphics2D The graphics device (null not permitted).
plotArea - Rectangle2D The area within which the plot should be drawn.
axisArea - Rectangle2D The empty chart area.
edge - RectangleEdge The axis position.
shapeCollection - AxisShapeCollection Collects information about the axis (null permitted).
alignEdge - boolean Controls whether or not translate shapes when the draw area less than the axis area.
Returns:
double Drawing the actual coordinates axis width or height.

calculateAxisSpace

double calculateAxisSpace(java.awt.Graphics2D g2,
                          java.awt.geom.Rectangle2D plotArea,
                          java.awt.geom.Rectangle2D maxAxisArea,
                          RectangleEdge edge)
Calculation the width or height of painting coordinate axis.

Parameters:
g2 - Graphics2D The graphics device (null not permitted).
plotArea - Rectangle2D The area within which the plot should be drawn.
maxAxisArea - Rectangle2D The maximum area within which the axis should be drawn.
edge - RectangleEdge The axis position.
Returns:
double The width or height.

getFixedAxisSpace

double getFixedAxisSpace()
Returns the fixed axis space.

Returns:
double The fixed axis space (maybe null).