From: amwaterhouse Date: Tue, 30 Aug 2005 10:34:25 +0000 (+0000) Subject: Dont set clip if its not null X-Git-Tag: Release_2_05b~87 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=3c17b49e571fc1274009671435ac47f51efab112;p=jalview.git Dont set clip if its not null --- diff --git a/src/jalview/appletgui/SeqCanvas.java b/src/jalview/appletgui/SeqCanvas.java index 3202fc4..f0c27a3 100755 --- a/src/jalview/appletgui/SeqCanvas.java +++ b/src/jalview/appletgui/SeqCanvas.java @@ -242,7 +242,7 @@ public class SeqCanvas if (av.getWrapAlignment()) { - drawWrappedPanel(gg, getSize().width, getSize().height, av.startRes); + drawWrappedPanel(gg, imgWidth, imgHeight, av.startRes); } else { @@ -339,24 +339,13 @@ public class SeqCanvas drawNorthScale(g, startRes, endx, ypos); } - // When printing we have an extra clipped region, - // the Printable page which we need to account for here - Shape clip = g.getClip(); - if (clip == null) - { - g.setClip(0, 0, cWidth * av.charWidth, canvasHeight); - } - else - { - g.setClip(0, - (int) clip.getBounds().y, - cWidth * av.charWidth, - (int) clip.getBounds().height - ); - } + + if(g.getClip()==null) + g.setClip(0, 0, cWidth * av.charWidth, canvasHeight); + drawPanel(g, startRes, endx, 0, al.getHeight(), startRes, 0, ypos); - g.setClip(clip); + g.setClip(null); g.translate( -LABEL_WEST, 0); ypos += cHeight;