Wrong CSS highlighting for selector names that can also be value keywords

Bug #764577 reported by Holger Koch
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gtksourceview2 (Ubuntu)
New
Undecided
Unassigned

Bug Description

Using libgtksourceview2 2.26.0-2ubuntu1 with Ubuntu 10.04.

It seems as if gtk-source-view performs a mere search for strings without regard to context.
In the case of a selector name: if you choose a name that can also be a property value it will be highlighted as if it were a property value and not like any other arbitrary selector name. Examples:

span.class1 { padding: 0; } /* This is the regular highlighting of a selector */
pre.class2 { margin: 0; } /* The keyword 'pre' can also be a property value and thus is highlighted as such */
div.bottom { margin: 0; } /* The keyword 'bottom' can also be a property value and thus is highlighted as such */
div.hover { text-align: left; } /* The keyword 'hover' can also be a name for a pseudo-class */
div.lang { margin: 0; } /* The keyword 'lang' can also be an attribute of a selector */
div.white { padding:0; } /* The keyword 'white' can also be a color value */

Revision history for this message
Holger Koch (atarax) wrote :

Added a screenshot of the issue

Revision history for this message
Holger Koch (atarax) wrote :

This issue seems to be solved in libgtksourceview2 3.0. Thank you!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.