From: Jim Procter Date: Wed, 26 Nov 2014 14:47:54 +0000 (+0000) Subject: JAL-1578 fix logic for showing score when no description present X-Git-Tag: Jalview_2_9~121^2~7^2~1 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;ds=sidebyside;h=813e55dd7e4637855940056d6559df4d03d4fae5;p=jalview.git JAL-1578 fix logic for showing score when no description present --- diff --git a/src/jalview/gui/AnnotationLabels.java b/src/jalview/gui/AnnotationLabels.java index 0a3423e..6e8417f 100755 --- a/src/jalview/gui/AnnotationLabels.java +++ b/src/jalview/gui/AnnotationLabels.java @@ -493,14 +493,14 @@ public class AnnotationLabels extends JPanel implements MouseListener, { // begin the tooltip's html fragment desc.append(""); + if (aa.hasScore()) + { + // TODO: limit precision of score to avoid noise from imprecise + // doubles + // (64.7 becomes 64.7+/some tiny value). + desc.append(" Score: " + aa.score); + } } - if (aa.hasScore()) - { - // TODO: limit precision of score to avoid noise from imprecise doubles - // (64.7 becomes 64.7+/some tiny value). - desc.append(" Score: " + aa.score); - } - if (desc.length() > 6) { desc.append(""); @@ -511,7 +511,6 @@ public class AnnotationLabels extends JPanel implements MouseListener, this.setToolTipText(null); } } - } /**