protected override void DrawTicks(
Graphics g,
Point physicalMin,
Point physicalMax,
out object labelOffset,
out object boundingBox)
{
Point tLabelOffset;
Rectangle tBoundingBox;
labelOffset = this.getDefaultLabelOffset( physicalMin, physicalMax );
boundingBox = null;
int start = (int)Math.Ceiling( this.WorldMin / Math.PI );
int end = (int)Math.Floor( this.WorldMax / Math.PI );
// sanity checking.
if ( end - start < 0 || end - start > 30 )
{
return;
}
for (int i=start; i<=end; ++i)
{
string label = i.ToString() + "Pi";
if (i == 0)
label = "0";
else if (i == 1)
label = "Pi";
this.DrawTick( g, i*Math.PI, this.LargeTickSize,
label,
new Point(0,0),
physicalMin, physicalMax,
out tLabelOffset, out tBoundingBox );
Axis.UpdateOffsetAndBounds(
ref labelOffset, ref boundingBox,
tLabelOffset, tBoundingBox );
}
}