- switch (lastSS)\r
- {\r
- case 'H':\r
- g.setColor(HELIX_COLOUR);\r
-\r
- int sCol = (lastSSX / av.charWidth) + startRes;\r
- int x1 = lastSSX;\r
- int x2 = x;\r
-\r
- if(row.annotations[sCol-1]==null ||\r
- row.annotations[sCol-1].secondaryStructure!='H')\r
- {\r
- g.fillArc(lastSSX, y+4+iconOffset, av.charWidth, 8, 90,180) ;\r
- x1 += av.charWidth/2;\r
- }\r
-\r
- if(row.annotations[column]==null ||\r
- row.annotations[column].secondaryStructure!='H')\r
- {\r
- g.fillArc(x-av.charWidth, y+4+iconOffset, av.charWidth, 8, 270,180);\r
- x2 -= av.charWidth/2;\r
- }\r
-\r
- g.fillRect(x1, y+4+iconOffset, x2-x1, 8);\r
-\r
- break;\r
-\r
- case 'E':\r
- g.setColor(SHEET_COLOUR);\r
-\r
- if (row.annotations[endRes] !=null\r
- && row.annotations[endRes].secondaryStructure != 'E')\r
- {\r
- g.fillRect(lastSSX, y + 4 + iconOffset,\r
- x - lastSSX - 4, 7);\r
- g.fillPolygon(new int[]\r
- {x - 4, x - 4, x},\r
- new int[]\r
- {\r
- y + iconOffset, y + 14 + iconOffset,\r
- y + 7 + iconOffset\r
- }, 3);\r
- }\r
- else\r
- g.fillRect(lastSSX, y + 4 + iconOffset,\r
- x - lastSSX, 7);\r
-\r
- break;\r
-\r
-\r
- default:\r
- g.setColor(Color.ORANGE);\r
- if(!av.wrapAlignment || endRes==av.endRes)\r
- g.fillRect(lastSSX, y + 6 + iconOffset, x - lastSSX, 2);\r
-\r
- break;\r
- }\r
+ g.fillRect(lastSSX, y + 4 + iconOffset,\r
+ (x * av.charWidth) - lastSSX - 4, 7);\r
+ g.fillPolygon(new int[]\r
+ { (x * av.charWidth) - 4,\r
+ (x * av.charWidth) - 4,\r
+ (x * av.charWidth)},\r
+ new int[]\r
+ {\r
+ y + iconOffset, y + 14 + iconOffset,\r
+ y + 7 + iconOffset\r
+ }, 3);\r