afreechart/src/main/java/org/afree/chart/axis/NumberAxis3D.java
/**
     * Draws the axis on a graphics device (such as the screen or a
     * printer).
     *
     * @param canvas  the graphics device.
     * @param cursor  the cursor.
     * @param plotArea  the area for drawing the axes and data.
     * @param dataArea  the area for drawing the data (a subset of the
     *                  plotArea).
     * @param edge  the axis location.
     * @param plotState  collects information about the plot (<code>null</code>
     *                   permitted).
     *
     * @return The updated cursor value.
     */
Draws the axis on a graphics device (such as the screen or a
printer).

@param canvas  the graphics device.
@param cursor  the cursor.
@param plotArea  the area for drawing the axes and data.
@param dataArea  the area for drawing the data (a subset of the
plotArea).
@param edge  the axis location.
@param plotState  collects information about the plot (null
permitted).

@return The updated cursor value.
Draws the axis on a graphics device ( such as the screen or a printer ) . @param canvas the graphics device . @param cursor the cursor . @param plotArea the area for drawing the axes and data . @param dataArea the area for drawing the data ( a subset of the plotArea ) . @param edge the axis location . @param plotState collects information about the plot ( null permitted ) . @return The updated cursor value .
public AxisState draw(Canvas canvas, double cursor, RectShape plotArea,
            RectShape dataArea, RectangleEdge edge,
            PlotRenderingInfo plotState) {
        if (!isVisible()) {
            AxisState state = new AxisState(cursor);
            List ticks = refreshTicks(canvas, state, dataArea, edge);
            state.setTicks(ticks);
            return state;
        }
        double xOffset = 0.0;
        double yOffset = 0.0;
        Plot plot = getPlot();
        if (plot instanceof CategoryPlot) {
            CategoryPlot cp = (CategoryPlot) plot;
            CategoryItemRenderer r = cp.getRenderer();
            if (r instanceof Effect3D) {
                Effect3D e3D = (Effect3D) r;
                xOffset = e3D.getXOffset();
                yOffset = e3D.getYOffset();
            }
        }
        double adjustedX = dataArea.getMinX();
        double adjustedY = dataArea.getMinY();
        double adjustedW = dataArea.getWidth() - xOffset;
        double adjustedH = dataArea.getHeight() - yOffset;
        if (edge == RectangleEdge.LEFT || edge == RectangleEdge.BOTTOM) {
            adjustedY += yOffset;
        }
        else if (edge == RectangleEdge.RIGHT || edge == RectangleEdge.TOP) {
            adjustedX += xOffset;
        }
        RectShape adjustedDataArea = new RectShape(adjustedX,
                adjustedY, adjustedW, adjustedH);
        AxisState info = drawTickMarksAndLabels(canvas, cursor, plotArea,
                adjustedDataArea, edge);
        info = drawLabel(getLabel(), canvas, plotArea, dataArea, edge, info);
        return info;
    }
public AxisState draw ( Canvas canvas , double cursor , RectShape plotArea , RectShape dataArea , RectangleEdge edge , PlotRenderingInfo plotState ) { if ( ! isVisible ( ) ) { AxisState state = new AxisState ( cursor ) ; List ticks = refreshTicks ( canvas , state , dataArea , edge ) ; state . setTicks ( ticks ) ; return state ; } double xOffset = 0.0 ; double yOffset = 0.0 ; Plot plot = getPlot ( ) ; if ( plot instanceof CategoryPlot ) { CategoryPlot cp = ( CategoryPlot ) plot ; CategoryItemRenderer r = cp . getRenderer ( ) ; if ( r instanceof Effect3D ) { Effect3D e3D = ( Effect3D ) r ; xOffset = e3D . getXOffset ( ) ; yOffset = e3D . getYOffset ( ) ; } } double adjustedX = dataArea . getMinX ( ) ; double adjustedY = dataArea . getMinY ( ) ; double adjustedW = dataArea . getWidth ( ) - xOffset ; double adjustedH = dataArea . getHeight ( ) - yOffset ; if ( edge == RectangleEdge . LEFT || edge == RectangleEdge . BOTTOM ) { adjustedY += yOffset ; } else if ( edge == RectangleEdge . RIGHT || edge == RectangleEdge . TOP ) { adjustedX += xOffset ; } RectShape adjustedDataArea = new RectShape ( adjustedX , adjustedY , adjustedW , adjustedH ) ; AxisState info = drawTickMarksAndLabels ( canvas , cursor , plotArea , adjustedDataArea , edge ) ; info = drawLabel ( getLabel ( ) , canvas , plotArea , dataArea , edge , info ) ; return info ; }
Draws the axis on a graphics device (such as the screen or a
 printer).
Draws the axis on a graphics device ( such as the screen or a printer ) .
// if the axis is not visible, don't draw it... // even though the axis is not visible, we need ticks for the // gridlines... // calculate the adjusted data area taking into account the 3D effect... // draw the tick marks and labels... // draw the axis label...