returns color.white if residueBoxColour is null
authoramwaterhouse <Andrew Waterhouse>
Fri, 19 Nov 2004 17:21:14 +0000 (17:21 +0000)
committeramwaterhouse <Andrew Waterhouse>
Fri, 19 Nov 2004 17:21:14 +0000 (17:21 +0000)
src/jalview/gui/SequenceRenderer.java

index 7a52bcc..0c1bfdc 100755 (executable)
@@ -10,11 +10,14 @@ public class SequenceRenderer implements RendererI
 {\r
   FontMetrics fm;\r
 \r
-  public Color getResidueBoxColour(ColourSchemeI cs, SequenceI seq, int i) {\r
+  public Color getResidueBoxColour(ColourSchemeI cs, SequenceI seq, int i)\r
+  {\r
+   Color c = Color.white;\r
+    try{\r
+       c = cs.findColour(seq, seq.getSequence(i, i + 1), i, null);\r
+    }catch(Exception ex){}\r
 \r
-    Color c  = cs.findColour(seq, seq.getSequence(i, i + 1), i, null);\r
     return c;\r
-\r
   }\r
 \r
 \r