remove gaps size range
authoramwaterhouse <Andrew Waterhouse>
Thu, 26 Oct 2006 09:40:35 +0000 (09:40 +0000)
committeramwaterhouse <Andrew Waterhouse>
Thu, 26 Oct 2006 09:40:35 +0000 (09:40 +0000)
src/jalview/gui/AlignFrame.java

index 4687b3c..b2dc4ca 100755 (executable)
@@ -106,6 +106,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener
   {
     viewport = ap.av;
     alignPanel = ap;
+    alignPanel.alignFrame = this;
     addAlignmentPanel(ap);
     init();
   }
@@ -824,10 +825,10 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener
    */
   void updateEditMenuBar()
   {
+
     if (historyList.size() > 0)
     {
       undoMenuItem.setEnabled(true);
-
       CommandI command = (CommandI) historyList.peek();
       undoMenuItem.setText("Undo " + command.getDescription());
     }
@@ -1512,7 +1513,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener
    */
   public void removeGappedColumnMenuItem_actionPerformed(ActionEvent e)
   {
-    int start = 0, end = viewport.alignment.getWidth();
+    int start = 0, end = viewport.alignment.getWidth()-1;
 
     SequenceI[] seqs;
     if (viewport.getSelectionGroup() != null)
@@ -1551,7 +1552,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener
    */
   public void removeAllGapsMenuItem_actionPerformed(ActionEvent e)
   {
-    int start = 0, end = viewport.alignment.getWidth();
+    int start = 0, end = viewport.alignment.getWidth()-1;
 
     SequenceI[] seqs;
     if (viewport.getSelectionGroup() != null)