Merge branch 'develop' into features/JAL-2446NCList
[jalview.git] / src / jalview / schemes / AnnotationColourGradient.java
index 220d3ab..c28ea5f 100755 (executable)
@@ -188,15 +188,16 @@ public class AnnotationColourGradient extends FollowerColourScheme
         seqannot = new IdentityHashMap<SequenceI, AlignmentAnnotation>();
       }
       // resolve the context containing all the annotation for the sequence
-      AnnotatedCollectionI alcontext = alignment instanceof AlignmentI ? alignment
+      AnnotatedCollectionI alcontext = alignment instanceof AlignmentI
+              ? alignment
               : alignment.getContext();
       boolean f = true, rna = false;
-      for (AlignmentAnnotation alan : alcontext.findAnnotation(annotation
-              .getCalcId()))
+      for (AlignmentAnnotation alan : alcontext
+              .findAnnotation(annotation.getCalcId()))
       {
         if (alan.sequenceRef != null
-                && (alan.label != null && annotation != null && alan.label
-                        .equals(annotation.label)))
+                && (alan.label != null && annotation != null
+                        && alan.label.equals(annotation.label)))
         {
           if (!rna && alan.isRNA())
           {
@@ -252,8 +253,8 @@ public class AnnotationColourGradient extends FollowerColourScheme
 
   public Color getMaxColour()
   {
-    return new Color(redMin + redRange, greenMin + greenRange, blueMin
-            + blueRange);
+    return new Color(redMin + redRange, greenMin + greenRange,
+            blueMin + blueRange);
   }
 
   /**
@@ -287,8 +288,9 @@ public class AnnotationColourGradient extends FollowerColourScheme
     /*
      * locate the annotation we are configured to colour by
      */
-    AlignmentAnnotation ann = (seqAssociated && seqannot != null ? seqannot
-            .get(seq) : this.annotation);
+    AlignmentAnnotation ann = (seqAssociated && seqannot != null
+            ? seqannot.get(seq)
+            : this.annotation);
 
     /*
      * if gap or no annotation at position, no colour (White)
@@ -316,8 +318,10 @@ public class AnnotationColourGradient extends FollowerColourScheme
      */
     if (annotationThreshold != null)
     {
-      if ((aboveAnnotationThreshold == ABOVE_THRESHOLD && aj.value < annotationThreshold.value)
-              || (aboveAnnotationThreshold == BELOW_THRESHOLD && aj.value > annotationThreshold.value))
+      if ((aboveAnnotationThreshold == ABOVE_THRESHOLD
+              && aj.value < annotationThreshold.value)
+              || (aboveAnnotationThreshold == BELOW_THRESHOLD
+                      && aj.value > annotationThreshold.value))
       {
         return Color.white;
       }
@@ -354,8 +358,10 @@ public class AnnotationColourGradient extends FollowerColourScheme
           }
           else
           {
-            result = ann.annotations[j].secondaryStructure == 'H' ? AnnotationRenderer.HELIX_COLOUR
-                    : ann.annotations[j].secondaryStructure == 'E' ? AnnotationRenderer.SHEET_COLOUR
+            result = ann.annotations[j].secondaryStructure == 'H'
+                    ? AnnotationRenderer.HELIX_COLOUR
+                    : ann.annotations[j].secondaryStructure == 'E'
+                            ? AnnotationRenderer.SHEET_COLOUR
                             : AnnotationRenderer.STEM_COLOUR;
           }
         }