- // int threshold = 80;\r
-\r
- while (i <= end && i < length)\r
- {\r
- if(inCurrentSequenceGroup(i))\r
- {\r
- color = getResidueBoxColour(currentSequenceGroup.cs, seq, i);\r
- }\r
- else\r
- color = getResidueBoxColour(av.getGlobalColourScheme(), seq, i);\r
-\r
- // Hashtable hash = (Hashtable)freq.elementAt(i-start);\r
- // String s = (String)hash.get("maxResidue");\r
- // int count = ((Integer)hash.get("maxCount")).intValue();\r
- // int max = ((Integer)hash.get("size")).intValue();\r
- // int nongap = ((Integer)hash.get("nongap")).intValue();\r
- // float frac = (float)(count*1.0/(1.0*nongap));\r
-\r
- //System.out.println("Frac/count/nongap " + frac + " " + count + " " + nongap);\r
- /* if (!seq.getSequence().substring(i,i+1).equals(s) ||\r
- s.equals("-") ||\r
- s.equals(".") ||\r
- s.equals(" "))\r
- {\r
- c = Color.white;\r
- } else {\r
- if (frac > 0.9) {\r
- c = Color.red;\r
- } else if (frac > 0.8) {\r
- c = Color.orange;\r
- } else if (frac > 0.7) {\r
- c = Color.pink;\r
- } else if (frac > 0.5) {\r
- c = Color.yellow;\r
- } else if (frac> 0.3) {\r
- c = Color.lightGray;\r
- }\r
- }*/\r
-\r
- if (color != currentColor || color != null)\r
- {\r
- g.fillRect(x1+width*(curStart-start),y1,curWidth,height);\r
-\r
- currentColor = color;\r
- g.setColor(color);\r
-\r
- curStart = i;\r
- curWidth = width;\r
- }\r
- else\r
- curWidth += width;\r
-\r
- i++;\r
- }\r
- g.fillRect(x1+width*(curStart-start),y1,curWidth,height);\r
- }\r
-\r
- public void drawText(Graphics g, SequenceI seq,int start, int end, int x1, int y1, int width, int height)\r
- {\r
- int pady = height/5;\r
- int charOffset=0;\r
- g.setColor(Color.black);\r
-\r
- char s;\r
- // Need to find the sequence position here.\r
- for (int i = start; i <= end; i++)\r
+ /**\r
+ * DOCUMENT ME!\r
+ *\r
+ * @param seq DOCUMENT ME!\r
+ * @param start DOCUMENT ME!\r
+ * @param end DOCUMENT ME!\r
+ * @param x1 DOCUMENT ME!\r
+ * @param y1 DOCUMENT ME!\r
+ * @param width DOCUMENT ME!\r
+ * @param height DOCUMENT ME!\r
+ */\r
+ public void drawText(SequenceI seq, int start, int end, int x1, int y1,\r
+ int width, int height)\r