Map darkColors = new HashMap();
Set paintedNodes = new HashSet();
void paintLinkMap(Graphics2D g, Map linkMap) {
paintedNodes.clear();
Point2D center = getCenter();
if(linkMap == null) {
return;
}
g.setColor(linkColor);
Util.setAntialias(g, true);
// paint links
for(Iterator it = linkMap.keySet().iterator(); it.hasNext(); ) {
Link link = (Link)it.next();
Color c1 = fillColor;
Color c2 = lineColor;
if(link instanceof DefaultLink) {
DefaultLink dl = (DefaultLink)link;
c1 = dl.getColor();
c2 = (Color)darkColors.get(c1);
if(c2 == null) {
c2 = Util.rgbInterpolate(c1, Color.black, .5);
darkColors.put(c1, c2);
}
}
if(link.getType() < 0) {
c2 = null;
}
paintLink(g, link, c1, c2, true);
}
// paint link mirror image
if(fadestate != STATE_FADE) {
Composite oldComp = g.getComposite();
AffineTransform oldTrans = g.getTransform();
g.scale(1.0, -.5);
g.translate(center.getY()*.5, -3.1*center.getY());
g.shear(-0.5, 0);
g.setComposite(alphaSome);
int n = 0;
int n2 = 0;
Color c1 = Util.rgbInterpolate(bottomColor, Color.black, .1);