You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 2, 2023. It is now read-only.
Rainer Simon edited this page Jul 12, 2013
·
3 revisions
valnodePainter= (nodes: Seq[Node2D], g2d: Graphics2D) => {
nodes.foreach(n2d => {
// For the sake of the demo, just use the number of links as sizevalsize= n2d.node.links.size
// Use the group value to pick a color from the palette
g2d.setColor(ColorPalette.getColor(n2d.node.group))
// Paint a node with an outline
g2d.fill(newEllipse2D.Double(n2d.x - size /2, n2d.y - size /2, size, size))
g2d.setStroke(newBasicStroke(2));
g2d.setColor(Color.WHITE)
g2d.draw(newEllipse2D.Double(n2d.x - size /2, n2d.y - size /2, size, size))
})
})