From 1389d6cb90f34bc58df11d453d3656dc9ff34bd0 Mon Sep 17 00:00:00 2001 From: gmungoc Date: Wed, 6 Jul 2016 16:34:32 +0100 Subject: [PATCH] JAL-2110 generic rather than specific check for gap character --- src/jalview/datamodel/Mapping.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/jalview/datamodel/Mapping.java b/src/jalview/datamodel/Mapping.java index a0a050f..1c196be 100644 --- a/src/jalview/datamodel/Mapping.java +++ b/src/jalview/datamodel/Mapping.java @@ -20,6 +20,7 @@ */ package jalview.datamodel; +import jalview.util.Comparison; import jalview.util.MapList; import java.util.Iterator; @@ -258,7 +259,8 @@ public class Mapping int truePos = sequencePos - (start - 1); while (alignedBases < truePos && alignedColumn < alignedSeq.length) { - if (alignedSeq[alignedColumn++] != gap) + char c = alignedSeq[alignedColumn++]; + if (c != gap && !Comparison.isGap(c)) { alignedBases++; } -- 1.7.10.2