X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fappletgui%2FIdCanvas.java;h=d72e91f72c9f70007e9e3bc1feba4dbe7dc02f2e;hb=4eb1ed22600411fe5b6e9ac93084b45429ccfad6;hp=5204094d21079cb859ad0e8597ce1d0968920a31;hpb=685909b39c1c85ff304ecea9763925de75b2cf77;p=jalview.git diff --git a/src/jalview/appletgui/IdCanvas.java b/src/jalview/appletgui/IdCanvas.java index 5204094..d72e91f 100755 --- a/src/jalview/appletgui/IdCanvas.java +++ b/src/jalview/appletgui/IdCanvas.java @@ -57,8 +57,7 @@ public class IdCanvas extends Panel } public void drawIdString(Graphics gg, boolean hiddenRows, SequenceI s, - int i, int starty, - int ypos) + int i, int starty, int ypos) { int charHeight = av.getCharHeight(); @@ -139,11 +138,13 @@ public class IdCanvas extends Panel repaint(); } + @Override public void update(Graphics g) { paint(g); } + @Override public void paint(Graphics g) { if (getSize().height < 0 || getSize().width < 0) @@ -187,6 +188,7 @@ public class IdCanvas extends Panel * local copy of av.getCharHeight set at top of drawIds */ private int avcharHeight; + void drawIds(int starty, int endy) { // hardwired italic IDs in applet currently @@ -356,19 +358,17 @@ public class IdCanvas extends Panel gg.setColor(Color.blue); if (below) { - gg.fillPolygon(new int[] - { getSize().width - avcharHeight, getSize().width - avcharHeight, - getSize().width }, new int[] - { (i - starty) * avcharHeight + yoffset, + gg.fillPolygon(new int[] { getSize().width - avcharHeight, + getSize().width - avcharHeight, getSize().width }, new int[] { + (i - starty) * avcharHeight + yoffset, (i - starty) * avcharHeight + yoffset + avcharHeight / 4, (i - starty) * avcharHeight + yoffset }, 3); } if (above) { - gg.fillPolygon(new int[] - { getSize().width - avcharHeight, getSize().width - avcharHeight, - getSize().width }, new int[] - { (i - starty + 1) * avcharHeight + yoffset, + gg.fillPolygon(new int[] { getSize().width - avcharHeight, + getSize().width - avcharHeight, getSize().width }, new int[] { + (i - starty + 1) * avcharHeight + yoffset, (i - starty + 1) * avcharHeight + yoffset - avcharHeight / 4, (i - starty + 1) * avcharHeight + yoffset }, 3); @@ -380,7 +380,7 @@ public class IdCanvas extends Panel Font bold = new Font(av.getFont().getName(), Font.BOLD, av.getFont() .getSize()); - if (av.isHiddenRepSequence(seq)) + if (av.isReferenceSeq(seq) || av.isHiddenRepSequence(seq)) { gg.setFont(bold); return true;