From 3d2554c478e12c745b1270edd21daeef03de636c Mon Sep 17 00:00:00 2001 From: amwaterhouse Date: Fri, 8 Apr 2005 15:01:52 +0000 Subject: [PATCH] bug adding null sequence to selection fixed --- src/jalview/gui/SeqPanel.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/jalview/gui/SeqPanel.java b/src/jalview/gui/SeqPanel.java index 3595fe6..3bfc7db 100755 --- a/src/jalview/gui/SeqPanel.java +++ b/src/jalview/gui/SeqPanel.java @@ -175,8 +175,6 @@ public class SeqPanel extends JPanel y %= chunkHeight; seq = y / av.getCharHeight() + av.getStartSeq(); - // chunkHeight = (da.getHeight() + 2)*charHeight; - // startx += chunkWidth; } else { @@ -513,6 +511,10 @@ public class SeqPanel extends JPanel if(stretchGroup==null) return; + if(res>av.alignment.getWidth()-2) + res = av.alignment.getWidth()-2; + + if(stretchGroup.getEndRes()==res) // Edit end res position of selected group changeEndRes = true; @@ -560,6 +562,7 @@ public class SeqPanel extends JPanel } else { + if(seq!=null) stretchGroup.addSequence(seq); stretchGroup.addSequence(nextSeq); } -- 1.7.10.2