Bug 395079 - mediatype operator "prefers-reduced-motion" will break logical structure of highlighting
Summary: mediatype operator "prefers-reduced-motion" will break logical structure of h...
Status: RESOLVED FIXED
Alias: None
Product: frameworks-syntax-highlighting
Classification: Frameworks and Libraries
Component: syntax (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: NOR minor
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-06-06 10:07 UTC by Peter Möller
Modified: 2019-01-31 11:10 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
example css, showing the wrong highlighting (128 bytes, text/css)
2018-06-06 10:07 UTC, Peter Möller
Details
Screenshot of Editor, showing highlighted css code (11.98 KB, image/png)
2019-01-31 11:06 UTC, Peter Möller
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Möller 2018-06-06 10:07:56 UTC
Created attachment 113110 [details]
example css, showing the wrong highlighting

KATE Version 16.08.2

Maybe, the effect is already gone with newer versions ;-)

If You use mediatype blocks, that have an operator like "prefers-reduced-motion", then the tag is not recognised and the highlighting structure will fail from now on

Hint: As far as I know, it is an Apple-Only feature. But it would be nice, if this wouldn't break the structure for all of us.
Comment 1 Peter Möller 2018-06-10 11:22:26 UTC
Just an idea: Instead of adding such a tag to the rule, it might be the better approach that the structure of the mediatype statement is recognised (by regex?). Then the opening brace would help already to find the structure again, even if a tag is unknown ;-)
Comment 2 Dominik Haumann 2019-01-30 21:46:27 UTC
Can you please attach a screenshot with the broken version? In my version it looks fine.
Comment 3 Peter Möller 2019-01-31 11:06:53 UTC
Created attachment 117761 [details]
Screenshot of Editor, showing highlighted css code
Comment 4 Peter Möller 2019-01-31 11:07:15 UTC
Hi Dominik,

You're right. Don't know, which version solved this, but I may confirm it is gone in Kate V 17.12.3.

Will add a screenshot also.
Comment 5 Dominik Haumann 2019-01-31 11:10:40 UTC
For me it looks like this: https://i.imgur.com/mpat16I.png
There were several major updates in the CSS highlighting, so I assume it's fixed.