From: amwaterhouse Date: Mon, 23 Apr 2007 12:46:14 +0000 (+0000) Subject: Check for null displayCharacters X-Git-Tag: Release_2_3~188 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=4dac54360fdfecce521a1c63e75b4027219ac065;p=jalview.git Check for null displayCharacters --- diff --git a/src/jalview/datamodel/AlignmentAnnotation.java b/src/jalview/datamodel/AlignmentAnnotation.java index 81ea36f..16f8fb8 100755 --- a/src/jalview/datamodel/AlignmentAnnotation.java +++ b/src/jalview/datamodel/AlignmentAnnotation.java @@ -54,6 +54,8 @@ public class AlignmentAnnotation /** DOCUMENT ME!! */ public float graphMax; + public float score; + public GraphLine threshold; // Graphical hints and tips @@ -87,6 +89,7 @@ public class AlignmentAnnotation public static final int LINE_GRAPH = 2; + public static int getGraphValueFromString(String string) { if (string.equalsIgnoreCase("BAR_GRAPH")) @@ -138,9 +141,11 @@ public class AlignmentAnnotation hasIcons = true; } - if (annotations[i].displayCharacter!=null) - { - if (annotations[i].displayCharacter.length() == 1 + if(annotations[i].displayCharacter==null) + continue; + + + if (annotations[i].displayCharacter.length() == 1 && !annotations[i].displayCharacter.equals("H") && !annotations[i].displayCharacter.equals("E") && !annotations[i].displayCharacter.equals("-") @@ -160,8 +165,6 @@ public class AlignmentAnnotation else padGaps = false; } - } - if (nonSSLabel) { @@ -228,7 +231,9 @@ public class AlignmentAnnotation continue; } - if (drawValues && annotations[i].displayCharacter!=null && annotations[i].displayCharacter.length() > 1) + if (drawValues + && annotations[i].displayCharacter!=null + && annotations[i].displayCharacter.length() > 1) { drawValues = false; } @@ -310,8 +315,8 @@ public class AlignmentAnnotation } for (int i=0; ilength; - + } /**