Alignment of node labels modified
authoramwaterhouse <Andrew Waterhouse>
Mon, 19 Sep 2005 12:49:39 +0000 (12:49 +0000)
committeramwaterhouse <Andrew Waterhouse>
Mon, 19 Sep 2005 12:49:39 +0000 (12:49 +0000)
src/jalview/gui/TreeCanvas.java

index 7b74078..9524544 100755 (executable)
@@ -195,7 +195,7 @@ public class TreeCanvas extends JPanel implements MouseListener, Runnable,
 \r
             if (showDistances && (node.dist > 0))\r
             {\r
-                nodeLabel = new Format("%5.2f").form(node.dist);\r
+                nodeLabel = new Format("%5.2f").form(node.dist).trim();\r
             }\r
 \r
             if (showBootstrap)\r
@@ -210,7 +210,7 @@ public class TreeCanvas extends JPanel implements MouseListener, Runnable,
 \r
             if (!nodeLabel.equals(""))\r
             {\r
-                g.drawString(nodeLabel, xstart, ypos - 10);\r
+                g.drawString(nodeLabel, xstart+2, ypos - 2);\r
             }\r
 \r
             String name = (markPlaceholders && node.isPlaceholder())\r
@@ -273,8 +273,8 @@ public class TreeCanvas extends JPanel implements MouseListener, Runnable,
 \r
             if (showDistances && (node.dist > 0))\r
             {\r
-                g.drawString(new Format("%5.2f").form(node.dist), xstart,\r
-                    ypos - 5);\r
+                g.drawString(new Format("%5.2f").form(node.dist).trim(), xstart+2,\r
+                    ypos - 2);\r
             }\r
         }\r
     }\r