add "useCurvedEdges" feature

[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9502]
This commit is contained in:
Udo Borkowski 2011-11-30 17:10:46 -08:00
parent ef57f44240
commit 1bc3997930
1 changed files with 2 additions and 2 deletions

View File

@ -138,7 +138,7 @@ public class TreeViewer extends JComponent {
// ---------------- PAINT -----------------------------------------------
private boolean useCurvedEdges = true;
private boolean useCurvedEdges = false;
public boolean getUseCurvedEdges() {
return useCurvedEdges;
@ -161,7 +161,7 @@ public class TreeViewer extends JComponent {
Rectangle2D.Double childBounds = getBoundsOfNode(child);
double x2 = childBounds.getCenterX();
double y2 = childBounds.getMinY();
if (useCurvedEdges) {
if (getUseCurvedEdges()) {
CubicCurve2D c = new CubicCurve2D.Double();
double ctrlx1 = x1;
double ctrly1 = (y1+y2)/2;