Point p = rr.getPoint( iPointToCheck );
Location p = rr.getPoint( iPointToCheck );
	final boolean[] checkTickLabelVisibility( IDisplayServer xs, Label la,			int iLabelLocation ) throws ChartException	{		boolean[] ba = new boolean[daTickCoordinates.length];		boolean vis = la.isSetVisible( ) && la.isVisible( );		Arrays.fill( ba, vis );		if ( !vis )		{			// all non-visible label, skip checking.			return ba;		}		if ( iType != TEXT && !bCategoryScale )		{			// Already auto scaled, just return all as true.			return ba;		}		final double dAngleInDegrees = la.getCaption( )				.getFont( )				.getRotation( );		double x = 0, y = 0;		int iPointToCheck = 0;		if ( iLabelLocation == ABOVE || iLabelLocation == BELOW )		{			iPointToCheck = ( dAngleInDegrees < 0 && dAngleInDegrees > -90 ) ? 3					: 0;		}		else if ( iLabelLocation == LEFT || iLabelLocation == RIGHT )		{			iPointToCheck = ( dAngleInDegrees < 0 && dAngleInDegrees > -90 ) ? 2					: 3;		}		double[] da = daTickCoordinates;		RotatedRectangle rrPrev = null, rrPrev2 = null, rr;		DataSetIterator dsi = getData( );		dsi.reset( );		final int iDateTimeUnit = ( iType == IConstants.DATE_TIME ) ? CDateTime.computeUnit( dsi )				: IConstants.UNDEFINED;		String sText = null;		dsi.reset( );		for ( int i = 0; i < da.length - 1; i++ )		{			if ( dsi.hasNext( ) )			{				sText = formatCategoryValue( iType, dsi.next( ), iDateTimeUnit );			}			else			{				sText = NULL_STRING;			}			if ( iLabelLocation == ABOVE || iLabelLocation == BELOW )			{				x = da[i];			}			else if ( iLabelLocation == LEFT || iLabelLocation == RIGHT )			{				y = da[i];			}			la.getCaption( ).setValue( sText );			try			{				rr = computePolygon( xs, iLabelLocation, la, x, y );			}			catch ( IllegalArgumentException uiex )			{				throw new ChartException( ChartEnginePlugin.ID,						ChartException.GENERATION,						uiex );			}			Point p = rr.getPoint( iPointToCheck );			if ( isAxisLabelStaggered( ) && i % 2 == 1 )			{				if ( i == 1 )				{					// Always show the first label.					ba[i] = true;					rrPrev2 = rr;				}				else				{					if ( rrPrev2.contains( p )							|| rrPrev2.getPoint( iPointToCheck ).equals( p )							|| rr.intersects( rrPrev2.getBounds2D( ) ) )					{						ba[i] = false;					}					else					{						ba[i] = true;						rrPrev2 = rr;					}				}			}			else			{				if ( i == 0 )				{					// Always show the first label.					ba[i] = true;					rrPrev = rr;				}				else				{					if ( rrPrev.contains( p )							|| rrPrev.getPoint( iPointToCheck ).equals( p )							|| rr.intersects( rrPrev.getBounds2D( ) ) )					{						ba[i] = false;					}					else					{						ba[i] = true;						rrPrev = rr;					}				}			}		}		return ba;	}