Merge pull request #40 from tom93/fix-search-leading-spaces

Fix search pos on file with leading whitespace
This commit is contained in:
Naveen Singh
2024-03-13 18:29:49 +05:30
committed by GitHub

View File

@@ -316,7 +316,7 @@ class ReadTextActivity : SimpleActivity() {
binding.readTextView.text?.clearBackgroundSpans()
if (text.isNotBlank() && text.length > 1) {
searchMatches = binding.readTextView.value.searchMatches(text)
searchMatches = binding.readTextView.text.toString().searchMatches(text)
binding.readTextView.highlightText(text, getProperPrimaryColor())
}