From 0fd0a770a96b63d7aede3af5f1e47c29a85595c6 Mon Sep 17 00:00:00 2001 From: cmzmasek Date: Mon, 12 Sep 2011 00:04:47 +0000 Subject: [PATCH] changed order --- .../src/org/forester/archaeopteryx/NodePanel.java | 25 ++++++++++---------- 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/forester/java/src/org/forester/archaeopteryx/NodePanel.java b/forester/java/src/org/forester/archaeopteryx/NodePanel.java index ebed530..7646342 100644 --- a/forester/java/src/org/forester/archaeopteryx/NodePanel.java +++ b/forester/java/src/org/forester/archaeopteryx/NodePanel.java @@ -226,18 +226,7 @@ class NodePanel extends JPanel implements TreeSelectionListener { addSubelement( category, CONFIDENCE, conf.asText().toString() ); } } - if ( ( phylogeny_node.getBranchData().getBranchWidth() != null ) - && ( phylogeny_node.getBranchData().getBranchWidth().getValue() != BranchWidth.BRANCH_WIDTH_DEFAULT_VALUE ) ) { - addSubelement( category, - NODE_BRANCH_WIDTH, - ForesterUtil.FORMATTER_3.format( phylogeny_node.getBranchData().getBranchWidth().getValue() ) ); - } - if ( ( phylogeny_node.getBranchData().getBranchColor() != null ) ) { - Color c = phylogeny_node.getBranchData().getBranchColor().getValue(); - addSubelement( category, - NODE_BRANCH_COLOR, - c.getRed() + ", " + c.getGreen() + ", "+ c.getBlue() ); - } + if ( !phylogeny_node.isExternal() ) { addSubelement( category, "Children", String.valueOf( phylogeny_node.getNumberOfDescendants() ) ); addSubelement( category, @@ -265,6 +254,18 @@ class NodePanel extends JPanel implements TreeSelectionListener { addSubelement( category, "Distance to root", String.valueOf( ForesterUtil.FORMATTER_6.format( d ) ) ); } } + if ( ( phylogeny_node.getBranchData().getBranchWidth() != null ) + && ( phylogeny_node.getBranchData().getBranchWidth().getValue() != BranchWidth.BRANCH_WIDTH_DEFAULT_VALUE ) ) { + addSubelement( category, + NODE_BRANCH_WIDTH, + ForesterUtil.FORMATTER_3.format( phylogeny_node.getBranchData().getBranchWidth().getValue() ) ); + } + if ( ( phylogeny_node.getBranchData().getBranchColor() != null ) ) { + Color c = phylogeny_node.getBranchData().getBranchColor().getValue(); + addSubelement( category, + NODE_BRANCH_COLOR, + c.getRed() + ", " + c.getGreen() + ", "+ c.getBlue() ); + } } private static void addBinaryCharacters( final DefaultMutableTreeNode top, -- 1.7.10.2