X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fgui%2FAnnotationPanel.java;h=abe92bbabb4f691f41ce4c7ee3ba8aba5a466c8a;hb=90ff735f876d7064f1f24925874fd7f41f94c7ac;hp=c9d65fab2b447c4e44963e114dab66f2348eafae;hpb=53507580ea0d347514d4f5e092a4d3d815609b9e;p=jalview.git diff --git a/src/jalview/gui/AnnotationPanel.java b/src/jalview/gui/AnnotationPanel.java index c9d65fa..abe92bb 100755 --- a/src/jalview/gui/AnnotationPanel.java +++ b/src/jalview/gui/AnnotationPanel.java @@ -670,7 +670,7 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI, } graphStretchY = evt.getY(); adjustPanelHeight(); - ap.paintAlignment(true); + ap.paintAlignment(false, false); } else { @@ -904,6 +904,8 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI, @Override public void paintComponent(Graphics g) { + super.paintComponent(g); + g.setColor(Color.white); g.fillRect(0, 0, getWidth(), getHeight()); @@ -992,10 +994,8 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI, int er = av.getRanges().getEndRes() + 1; int transX = 0; - long stime = System.currentTimeMillis(); gg.copyArea(0, 0, imgWidth, getHeight(), -horizontal * av.getCharWidth(), 0); - long mtime = System.currentTimeMillis(); if (horizontal > 0) // scrollbar pulled right, image to the left { @@ -1012,17 +1012,9 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI, drawComponent(gg, sr, er); gg.translate(-transX, 0); - long dtime = System.currentTimeMillis(); + fastPaint = true; repaint(); - long rtime = System.currentTimeMillis(); - if (debugRedraw) - { - System.err.println("Scroll:\t" + horizontal + "\tCopyArea:\t" - + (mtime - stime) + "\tDraw component:\t" + (dtime - mtime) - + "\tRepaint call:\t" + (rtime - dtime)); - } - } private volatile boolean lastImageGood = false;