[frameworks-syntax-highlighting] [Bug 383350] KSyntaxHighlighting::SyntaxHighlighter removes QTextBlock::userData() silently

2017-09-04 Thread Dominik Haumann
https://bugs.kde.org/show_bug.cgi?id=383350

Dominik Haumann  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |WORKSFORME

--- Comment #4 from Dominik Haumann  ---
Hi Szyk, after talking to Volker about this, the solution you can find in the
linked sources is the only way to go if you need your own custom QTextBlocks.
But give this works, there is no real bug, so we will close this as
works-for-me.

Kate will later use this approach as well.

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

[frameworks-syntax-highlighting] [Bug 383350] KSyntaxHighlighting::SyntaxHighlighter removes QTextBlock::userData() silently

2017-09-04 Thread Dominik Haumann
https://bugs.kde.org/show_bug.cgi?id=383350

Dominik Haumann  changed:

   What|Removed |Added

 CC||vkra...@kde.org

--- Comment #3 from Dominik Haumann  ---
There is one possible solution: Instead of using the ready-made
QSyntaxHighlighter based solution, you could implement your own
QSyntaxHighlighter-based solution.

This is e.g. done in this commit in the KDE PIM suite:
https://phabricator.kde.org/D7672
https://cgit.kde.org/kpimtextedit.git/commit/?id=c775ce3a438814f82cb1ba9c2c8671b9f5be08c4

Here, the class PlainTextSyntaxSpellCheckingHighlighter derives from
Sonnet::Highlighter AND KSyntaxHighlighting::AbstractHighlighter.

If you follow this same route, you will be able to do what you want.

@Volker: I think this is the only solution to this problem, right? If so, I
think we can close this bug report, correct?

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

[frameworks-syntax-highlighting] [Bug 383350] KSyntaxHighlighting::SyntaxHighlighter removes QTextBlock::userData() silently

2017-08-10 Thread Szyk Cech
https://bugs.kde.org/show_bug.cgi?id=383350

--- Comment #2 from Szyk Cech  ---
So: how is the recommended way to implement bookmarks? Should I dig in Kate
code? Maybe someone can explain it in few words. This will save me hours...

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

[frameworks-syntax-highlighting] [Bug 383350] KSyntaxHighlighting::SyntaxHighlighter removes QTextBlock::userData() silently

2017-08-10 Thread Dominik Haumann
https://bugs.kde.org/show_bug.cgi?id=383350

--- Comment #1 from Dominik Haumann  ---
Indeed, this is because the Syntax-highlighting framework uses the userData
itself to store the State and folding infos, see:
https://github.com/KDE/syntax-highlighting/blob/master/src/lib/syntaxhighlighter.cpp

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