JAL-3088 check for validEnd when working out whether arrow should point to left when...
authorJames Procter <j.procter@dundee.ac.uk>
Mon, 4 Sep 2023 11:56:33 +0000 (12:56 +0100)
committerJames Procter <j.procter@dundee.ac.uk>
Mon, 4 Sep 2023 11:56:33 +0000 (12:56 +0100)
src/jalview/renderer/AnnotationRenderer.java

index 3f0c9fa..cba36d2 100644 (file)
@@ -185,7 +185,7 @@ public class AnnotationRenderer
             : row_annotations[column - 1].secondaryStructure;
 
     boolean diffupstream = sCol == 0 || row_annotations[sCol - 1] == null
-            || dc != row_annotations[sCol - 1].secondaryStructure;
+            || dc != row_annotations[sCol - 1].secondaryStructure || !validEnd;
     boolean diffdownstream = !validRes || !validEnd
             || row_annotations[column] == null
             || dc != row_annotations[column].secondaryStructure;
@@ -251,7 +251,7 @@ public class AnnotationRenderer
             : row_annotations[column - 1].displayCharacter;
 
     boolean diffupstream = sCol == 0 || row_annotations[sCol - 1] == null
-            || !dc.equals(row_annotations[sCol - 1].displayCharacter);
+            || !dc.equals(row_annotations[sCol - 1].displayCharacter) || !validEnd;
     boolean diffdownstream = !validRes || !validEnd
             || row_annotations[column] == null
             || !dc.equals(row_annotations[column].displayCharacter);