https://bugs.kde.org/show_bug.cgi?id=383922

--- Comment #7 from nfx...@gmail.com ---
Messing with it some more, it actually seems merely SpellCheckUnderline is
broken. Using WaveUnderline (and even DotLine) seems to make it work. So
something like this restores spell check rendering:

--- a/src/spellcheck/ontheflycheck.cpp
+++ b/src/spellcheck/ontheflycheck.cpp
@@ -608,7 +608,7 @@ void KateOnTheFlyChecker::misspelling(const QString &word,
i
nt start)                                                                      
                                    rangeStart + translatedEnd));
     movingRange->setFeedback(this);
     KTextEditor::Attribute *attribute = new KTextEditor::Attribute();
-    attribute->setUnderlineStyle(QTextCharFormat::SpellCheckUnderline);
+    attribute->setUnderlineStyle(QTextCharFormat::WaveUnderline);
    
attribute->setUnderlineColor(KateRendererConfig::global()->spellingMistakeL
ineColor());                                                                    


This looks like it's probably a really dumb Qt bug. A quick look at the Qt repo
seems to confirm this and that it was fixed:

88e6f8cff2974c46b1262f3a1a61e1440c664e0c

    Fix implementation of spell check underline styles

    The QTextCharFormat documentation said that the used style is based on
    QStyle::SH_SpellCheckUnderlineStyle style hint, however in fact the
    implementation (drawTextItemDecoration in qpainter.cpp) uses
    themeHint(QPlatformTheme::SpellCheckUnderlineStyle) instead since Qt 5
    (see commit 1f9ae50457a3750f).

    (...)

It looks like the fix might actually be in Qt 5.10 or Qt 5.9.3, which Debian
has been too incompetent to update to so far. (My version seems to be 5.9.2 in
unstable, and 5.10 with lots of broken packages in experimental.)

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to