From 92e13307a132894d5133db15bb127afa872cdc45 Mon Sep 17 00:00:00 2001 From: gmungoc Date: Mon, 10 Sep 2018 11:29:11 +0100 Subject: [PATCH] JAL-3097 adjust viewport width on hiding columns --- src/jalview/gui/AlignFrame.java | 2 ++ src/jalview/gui/ScalePanel.java | 3 +++ 2 files changed, 5 insertions(+) diff --git a/src/jalview/gui/AlignFrame.java b/src/jalview/gui/AlignFrame.java index 9de9e3b..a620d5a 100644 --- a/src/jalview/gui/AlignFrame.java +++ b/src/jalview/gui/AlignFrame.java @@ -3035,6 +3035,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener, viewport.expandColSelection(sg, false); viewport.hideAllSelectedSeqs(); viewport.hideSelectedColumns(); + alignPanel.updateLayout(); alignPanel.paintAlignment(true, true); viewport.sendSelection(); } @@ -3059,6 +3060,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener, public void hideSelColumns_actionPerformed(ActionEvent e) { viewport.hideSelectedColumns(); + alignPanel.updateLayout(); alignPanel.paintAlignment(true, true); viewport.sendSelection(); } diff --git a/src/jalview/gui/ScalePanel.java b/src/jalview/gui/ScalePanel.java index 5601c7a..d214db6 100755 --- a/src/jalview/gui/ScalePanel.java +++ b/src/jalview/gui/ScalePanel.java @@ -174,6 +174,7 @@ public class ScalePanel extends JPanel { av.showColumn(hiddenRange[0]); reveal = null; + ap.updateLayout(); ap.paintAlignment(true, true); av.sendSelection(); } @@ -190,6 +191,7 @@ public class ScalePanel extends JPanel { av.showAllHiddenColumns(); reveal = null; + ap.updateLayout(); ap.paintAlignment(true, true); av.sendSelection(); } @@ -214,6 +216,7 @@ public class ScalePanel extends JPanel av.setSelectionGroup(null); } + ap.updateLayout(); ap.paintAlignment(true, true); av.sendSelection(); } -- 1.7.10.2