headerAlignment.put( "X-align" + selectedNode.getId(), true );
position = new Vector2D( minPosScreen.getX() + ( maxPosScreen.getX() - minPosScreen.getX() ) / 2.0f, 14 );
key = "X" + hops;
if( !drawnHeadings.containsKey( key ) )
{
Text t = new Text( "Dist " + hops, position, new Vector3D( 1, 1, 1 ), fillColor, 12, true, true, true, false, false, false,
true );
t.draw( g2d, pb, minXPercent, maxXPercent, minYPercent, maxYPercent, minX, maxX, minY, maxY, nodeWidth, height, overview );
drawnHeadings.put( key, 1 );
}
else
{
drawnHeadings.put( key, drawnHeadings.get( key ) + 1 );
}
}
else
{
headerAlignment.put( "Y-align" + selectedNode.getId(), true );
position = new Vector2D( 35, minPosScreen.getY() + ( maxPosScreen.getY() - minPosScreen.getY() ) / 2.0f );
key = "Y" + hops;
if( !drawnHeadings.containsKey( key ) )
{
Text t = new Text( "Dist " + hops, position, new Vector3D( 1, 1, 1 ), fillColor, 12, true, true, true, false, false, false,
true );
t.draw( g2d, pb, minXPercent, maxXPercent, minYPercent, maxYPercent, minX, maxX, minY, maxY, nodeWidth, height, overview );
drawnHeadings.put( key, 1 );
}
else
{
drawnHeadings.put( key, drawnHeadings.get( key ) + 1 );
}
}
}
else
{
position = new Vector2D( 70 * hops, 14 );
key = "Align" + hops;
if( !drawnHeadings.containsKey( key ) )
{
Text t = new Text( "Dist " + hops, position, new Vector3D( 1, 1, 1 ), fillColor, 12, true, true, true, false, false, false, true );
t.draw( g2d, pb, minXPercent, maxXPercent, minYPercent, maxYPercent, minX, maxX, minY, maxY, nodeWidth, height, overview );
drawnHeadings.put( key, 1 );
}
else
{
drawnHeadings.put( key, drawnHeadings.get( key ) + 1 );
}
}
position.setY( position.getY() + ( drawnHeadings.get( key ) * 20 ) );
if( drawNumberOfNodesInBox )
{
Text t = new Text( nodes.size() + " nodes", position, new Vector3D( 1, 1, 1 ), fillColor, 12, true, true, true, false, false, false,
true );
t.draw( g2d, pb, minXPercent, maxXPercent, minYPercent, maxYPercent, minX, maxX, minY, maxY, nodeWidth, height, overview );
}
return 1;
}