diff --git a/src/graphtea/graph/graph/Edge.java b/src/graphtea/graph/graph/Edge.java index 0e910b6f..24f92137 100755 --- a/src/graphtea/graph/graph/Edge.java +++ b/src/graphtea/graph/graph/Edge.java @@ -345,12 +345,11 @@ public String getLabel() { private void updateText() { String _label; - if (!isShowWeight()) + if (!isShowWeight()) { _label = label; - else if (isShowWeight()) + } else { _label = String.valueOf(super.getWeight()); - else - _label = label + "," + super.getWeight(); + } this.text = _label; repaintView(); } diff --git a/src/graphtea/graph/graph/GraphModel.java b/src/graphtea/graph/graph/GraphModel.java index af7a21d5..6599fc6c 100755 --- a/src/graphtea/graph/graph/GraphModel.java +++ b/src/graphtea/graph/graph/GraphModel.java @@ -32,7 +32,7 @@ public class GraphModel extends ListGraph implements StorableOnExi private Font font = new Font(Font.SANS_SERIF, Font.PLAIN, 14); @UserModifiableProperty(displayName = "Show Edge Labels") - public static boolean showEdgeWeights = false; + public static boolean showEdgeWeights = true; @UserModifiableProperty(displayName = "Show Vertex Labels") public static boolean vertexLabelsEnabled = true; private boolean drawVertexLabels = vertexLabelsEnabled;