From ceb2f521994902436ad8f1d6e3527bf849d047fe Mon Sep 17 00:00:00 2001 From: Damyan Ivanov Date: Sat, 13 Feb 2021 23:38:36 +0200 Subject: [PATCH] fix marking of unmatched part at the end of the test text --- .../java/net/ktnx/mobileledger/model/TemplateDetailsItem.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/net/ktnx/mobileledger/model/TemplateDetailsItem.java b/app/src/main/java/net/ktnx/mobileledger/model/TemplateDetailsItem.java index 7dfed898..0f9cfe49 100644 --- a/app/src/main/java/net/ktnx/mobileledger/model/TemplateDetailsItem.java +++ b/app/src/main/java/net/ktnx/mobileledger/model/TemplateDetailsItem.java @@ -658,7 +658,7 @@ abstract public class TemplateDetailsItem { ss.setSpan(notMatchedSpan(), 0, m.start(), Spanned.SPAN_INCLUSIVE_INCLUSIVE); if (m.end() < testText.length() - 1) - ss.setSpan(notMatchedSpan(), m.end(), testText.length() - 1, + ss.setSpan(notMatchedSpan(), m.end(), testText.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE); ss.setSpan(matchedSpan(), m.start(0), m.end(0), -- 2.39.5