patch for bug #36198 - more to follow on Monday.
[jalview.git] / src / jalview / io / AnnotationFile.java
index 00b7ead..ce1afc2 100755 (executable)
@@ -125,7 +125,7 @@ public class AnnotationFile
           refSeq = row.sequenceRef;\r
           text.append("\nSEQUENCE_REF\t" + refSeq.getName() + "\n");\r
         }\r
-        boolean hasGlyphs = false, hasLabels = false, hasValues = false, hasText = false;\r
+        boolean hasGlyphs = row.hasIcons, hasLabels = row.hasText, hasValues = row.hasScore, hasText = false;\r
         // lookahead to check what the annotation row object actually contains.\r
         for (int j = 0; row.annotations != null\r
                 && j < row.annotations.length\r
@@ -210,7 +210,7 @@ public class AnnotationFile
           if (row.annotations[j] != null)\r
           {\r
             comma = "";\r
-            if (hasGlyphs && row.annotations[j].secondaryStructure != ' ')\r
+            if (row.annotations[j].secondaryStructure != ' ') // could be also hasGlyphs || ... \r
             {\r
 \r
               text.append(comma + row.annotations[j].secondaryStructure);\r
@@ -748,7 +748,7 @@ public class AnnotationFile
         }\r
       }\r
 \r
-      if (hasSymbols && (token.equals("H") || token.equals("E")))\r
+      if (hasSymbols && (token.equals("H") || token.equals("E") || token.equals(" ")))\r
       {\r
         // Either this character represents a helix or sheet\r
         // or an integer which can be displayed\r