From: James Procter Date: Tue, 17 Oct 2023 09:53:13 +0000 (+0100) Subject: JAL-4089 selected columns are reported in absolute column numbers, not visible columns X-Git-Tag: Release_2_11_4_0~136^2 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=55895fe0142a04bd24d3166314a48b3282314a34;p=jalview.git JAL-4089 selected columns are reported in absolute column numbers, not visible columns --- diff --git a/src/jalview/datamodel/ColumnSelection.java b/src/jalview/datamodel/ColumnSelection.java index 4a38ec0..b427739 100644 --- a/src/jalview/datamodel/ColumnSelection.java +++ b/src/jalview/datamodel/ColumnSelection.java @@ -340,10 +340,12 @@ public class ColumnSelection /** * Returns a read-only view of the (possibly empty) list of selected columns + * (base 1) *

- * The list contains no duplicates but is not necessarily ordered. It also may - * include columns hidden from the current view. To modify (for example sort) - * the list, you should first make a copy. + * The list contains no duplicates but is not necessarily ordered. Columns are + * reported in alignment coordinates (base 1), so may also include columns + * hidden from the current view. To modify (for example sort) the list, you + * should first make a copy. *

* The list is not thread-safe: iterating over it could result in * ConcurrentModificationException if it is modified by another thread. diff --git a/src/jalview/structures/models/AAStructureBindingModel.java b/src/jalview/structures/models/AAStructureBindingModel.java index 4b11494..dcedafa 100644 --- a/src/jalview/structures/models/AAStructureBindingModel.java +++ b/src/jalview/structures/models/AAStructureBindingModel.java @@ -884,14 +884,7 @@ public abstract class AAStructureBindingModel { for (int s : cs.getSelected()) { - if (hiddenCols == null) - { matched.set(s); - } - else - { - matched.set(hiddenCols.visibleToAbsoluteColumn(s)); - } } } else