final double dTopThreshold = bo.getTop( ); double dEnd = scBase.getEnd( ); final double dEndShift = Math.floor( scBase.getEndShift( ) ); if ( dEnd - dEndShift > dTopThreshold ) { dEnd = dEnd - dEndShift; final double dStart = scBase.getStart( ); scBase.computeTicks( ids, oaxBase.getLabel( ), oaxBase.getLabelPosition( ), VERTICAL, dStart, dEnd, false, null );
if ( isRightToLeft( ) ) { double dBottomThreshold = bo.getTop( ) + bo.getHeight( ); double dEnd = scBase.getEnd( ); final double dEndShift = Math.floor( scBase.getEndShift( ) ); if ( dEnd + dEndShift < dBottomThreshold ) { dEnd += dEndShift; final double dStart = scBase.getStart( ); scBase.computeTicks( ids, oaxBase.getLabel( ), oaxBase.getLabelPosition( ), VERTICAL, dStart, dEnd, false, null ); } } else { double dTopThreshold = bo.getTop( ); double dEnd = scBase.getEnd( ); final double dEndShift = Math.floor( scBase.getEndShift( ) ); if ( dEnd - dEndShift > dTopThreshold ) { dEnd = dEnd - dEndShift; final double dStart = scBase.getStart( ); scBase.computeTicks( ids, oaxBase.getLabel( ), oaxBase.getLabelPosition( ), VERTICAL, dStart, dEnd, false, null ); }
	private final void growBaseAxis( AllAxes aax, Bounds bo )			throws ChartException	{		// if (true) return;		OneAxis oaxBase = aax.getPrimaryBase( );		OneAxis oaxOrthogonal = aax.getPrimaryOrthogonal( );		AutoScale scBase = oaxBase.getScale( );		if ( !aax.areAxesSwapped( ) ) // STANDARD ORIENTATION		{			// IF PRIMARY ORTHOGONAL AXIS IS NOT ON THE RIGHT			if ( aax.getOverlayCount( ) > 0					&& oaxOrthogonal.getIntersectionValue( ).getType( ) != IConstants.MAX )			{				// IF ANY OVERLAY ORTHOGONAL AXES ARE ON THE RIGHT				if ( aax.anyOverlayPositionedAt( IConstants.MAX ) )				{					scBase.computeAxisStartEndShifts( ids,							oaxBase.getLabel( ),							HORIZONTAL,							oaxBase.getLabelPosition( ),							aax );					final double dRightThreshold = bo.getLeft( )							+ bo.getWidth( );					double dEnd = scBase.getEnd( );					final double dEndShift = scBase.getEndShift( );					if ( dEnd + dEndShift < dRightThreshold )					{						dEnd += dEndShift;						scBase.computeTicks( ids,								oaxBase.getLabel( ),								oaxBase.getLabelPosition( ),								HORIZONTAL,								scBase.getStart( ),								dEnd,								false,								null );					}				}			}			// IF PRIMARY ORTHOGONAL AXIS IS NOT ON THE LEFT			else if ( aax.getOverlayCount( ) > 0					&& oaxOrthogonal.getIntersectionValue( ).getType( ) != IConstants.MIN )			{				// IF ANY OVERLAY ORTHOGONAL AXES ARE ON THE LEFT				if ( aax.anyOverlayPositionedAt( IConstants.MIN ) )				{					scBase.computeAxisStartEndShifts( ids,							oaxBase.getLabel( ),							HORIZONTAL,							oaxBase.getLabelPosition( ),							aax );					final double dLeftThreshold = bo.getLeft( );					double dStart = scBase.getStart( );					final double dEndShift = scBase.getEndShift( );					final double dStartShift = scBase.getStartShift( );					if ( dStart - dStartShift > dLeftThreshold )					{						dStart -= dStartShift;						final double dEnd = scBase.getEnd( ) + dEndShift;						scBase.computeTicks( ids,								oaxBase.getLabel( ),								oaxBase.getLabelPosition( ),								HORIZONTAL,								dStart,								dEnd,								false,								null );					}				}			}		}		else		{			// IF PRIMARY ORTHOGONAL AXIS IS NOT AT THE TOP			if ( aax.getOverlayCount( ) > 0					&& oaxOrthogonal.getIntersectionValue( ).getType( ) != IConstants.MAX )			{				// IF ANY OVERLAY ORTHOGONAL AXES ARE AT THE TOP				if ( aax.anyOverlayPositionedAt( IConstants.MAX ) )				{					scBase.computeAxisStartEndShifts( ids,							oaxBase.getLabel( ),							VERTICAL,							oaxBase.getLabelPosition( ),							aax );					final double dTopThreshold = bo.getTop( );					double dEnd = scBase.getEnd( );					final double dEndShift = Math.floor( scBase.getEndShift( ) );					if ( dEnd - dEndShift > dTopThreshold )					{						dEnd = dEnd - dEndShift;						final double dStart = scBase.getStart( );						scBase.computeTicks( ids,								oaxBase.getLabel( ),								oaxBase.getLabelPosition( ),								VERTICAL,								dStart,								dEnd,								false,								null );					}				}			}			// IF PRIMARY ORTHOGONAL AXIS IS NOT AT THE BOTTOM			else if ( aax.getOverlayCount( ) > 0					&& oaxOrthogonal.getIntersectionValue( ).getType( ) != IConstants.MIN )			{				// IF ANY OVERLAY ORTHOGONAL AXES IS AT THE BOTTOM				if ( aax.anyOverlayPositionedAt( IConstants.MIN ) )				{					scBase.computeAxisStartEndShifts( ids,							oaxBase.getLabel( ),							VERTICAL,							oaxBase.getLabelPosition( ),							aax );					final double dBottomThreshold = bo.getTop( )							+ bo.getHeight( );					double dStart = scBase.getStart( );					final double dEndShift = scBase.getEndShift( );					final double dStartShift = scBase.getStartShift( );					if ( dStart + dStartShift < dBottomThreshold )					{						dStart += dStartShift;						final double dEnd = scBase.getEnd( ) - dEndShift;						scBase.computeTicks( ids,								oaxBase.getLabel( ),								oaxBase.getLabelPosition( ),								VERTICAL,								dStart,								dEnd,								false,								null );					}				}			}		}	}