Give selection counter priority in editor footer (#2155)

This commit is contained in:
Veronica Berglyd Olsen
2025-01-03 23:42:41 +01:00
parent 97fc64fcae
commit fad162c6c1
+2 -1
View File
@@ -1251,7 +1251,8 @@ class GuiDocEditor(QPlainTextEdit):
self._nwItem.setCharCount(cCount)
self._nwItem.setWordCount(wCount)
self._nwItem.setParaCount(pCount)
if needsRefresh:
if needsRefresh and not self.textCursor().hasSelection():
# Selection counter should take precedence (#2155)
self._nwItem.notifyToRefresh()
self.docFooter.updateWordCount(wCount, False)
return