From fe12e997357fbee12ef95a3b9955634f37e4e2f4 Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" <1619840+vkbo@users.noreply.github.com> Date: Sun, 20 Oct 2019 14:23:27 +0200 Subject: [PATCH] Fixed a bug where unicode characters were not included in the spell check regex --- nw/gui/dochighlight.py | 1 + 1 file changed, 1 insertion(+) diff --git a/nw/gui/dochighlight.py b/nw/gui/dochighlight.py index f4c8e1f2..39efb3b6 100644 --- a/nw/gui/dochighlight.py +++ b/nw/gui/dochighlight.py @@ -185,6 +185,7 @@ class GuiDocHighlighter(QSyntaxHighlighter): # Build a QRegExp for each pattern and for the spell checker self.rules = [(QRegularExpression(a),b) for (a,b) in self.hRules] self.spellRx = QRegularExpression(r"\b[^\s]+\b") + self.spellRx.setPatternOptions(QRegularExpression.UseUnicodePropertiesOption) return True