From abb4c1cc7383a54df59066186eb282588bb884e8 Mon Sep 17 00:00:00 2001 From: gmungoc Date: Tue, 4 Jul 2017 09:12:49 +0100 Subject: [PATCH] JAL-147 call method that sets visible width when drawing wrapped panel --- src/jalview/appletgui/SeqCanvas.java | 2 +- src/jalview/gui/SeqCanvas.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/jalview/appletgui/SeqCanvas.java b/src/jalview/appletgui/SeqCanvas.java index e996622..fa44e1e 100755 --- a/src/jalview/appletgui/SeqCanvas.java +++ b/src/jalview/appletgui/SeqCanvas.java @@ -441,7 +441,7 @@ public class SeqCanvas extends Panel implements ViewportListenerI av.setWrappedWidth(cWidth); - av.getRanges().setEndRes(av.getRanges().getStartRes() + cWidth - 1); + av.getRanges().setViewportStartAndWidth(startRes, cWidth); int endx; int ypos = hgap; diff --git a/src/jalview/gui/SeqCanvas.java b/src/jalview/gui/SeqCanvas.java index 5cfa8c0..d4b8f77 100755 --- a/src/jalview/gui/SeqCanvas.java +++ b/src/jalview/gui/SeqCanvas.java @@ -516,7 +516,7 @@ public class SeqCanvas extends JComponent implements ViewportListenerI av.setWrappedWidth(cWidth); - av.getRanges().setEndRes(av.getRanges().getStartRes() + cWidth - 1); + av.getRanges().setViewportStartAndWidth(startRes, cWidth); int endx; int ypos = hgap; -- 1.7.10.2