summaryrefslogtreecommitdiffstats
path: root/kate/data/css.xml
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2014-03-03 00:41:25 +0900
committerSlávek Banko <slavek.banko@axis.cz>2015-12-23 02:22:40 +0100
commit18c445cb5b6270fa017d464d87d2690309d3ff29 (patch)
tree404b628197e19bdc868715e080f4ee5070dc9284 /kate/data/css.xml
parent17517c35528d3081ab128bbac26f631e4bf44ea4 (diff)
downloadtdelibs-18c445cb5b6270fa017d464d87d2690309d3ff29.tar.gz
tdelibs-18c445cb5b6270fa017d464d87d2690309d3ff29.zip
Kate syntax highlighting files update - Feb 2014
(cherry picked from commit bb647dca1516a45ce18f2e040bd20528f588e2fe)
Diffstat (limited to 'kate/data/css.xml')
-rw-r--r--kate/data/css.xml93
1 files changed, 91 insertions, 2 deletions
diff --git a/kate/data/css.xml b/kate/data/css.xml
index d2c651681..6f274bb50 100644
--- a/kate/data/css.xml
+++ b/kate/data/css.xml
@@ -13,9 +13,12 @@ Changelog:
- Version 2.03, by Milian Wolff:
- Make it spelling aware
+- Version 2.08, Joseph Wenninger:
+- CSS3 media queries
+
-->
-<language name="CSS" version="2.08" kateversion="2.5" section="Markup" extensions="*.css" indenter="cstyle" mimetype="text/css" author="Wilbert Berendsen (wilbert@kde.nl)" license="LGPL">
+<language name="CSS" version="2.08" kateversion="2.4" section="Markup" extensions="*.css" indenter="cstyle" mimetype="text/css" author="Wilbert Berendsen (wilbert@kde.nl)" license="LGPL">
<highlighting>
<list name="properties">
@@ -622,10 +625,52 @@ Changelog:
<item> print </item>
<item> projection </item>
<item> screen </item>
+ <item> speech </item>
<item> tty </item>
<item> tv </item>
</list>
+ <list name="mediatypes_op">
+ <item> not </item>
+ <item> only </item>
+ </list>
+
+ <list name="media_features">
+ <item> width </item>
+ <item> min-width </item>
+ <item> max-width</item>
+ <item> height </item>
+ <item> min-height </item>
+ <item> max-height </item>
+ <item> device-width </item>
+ <item> min-device-width </item>
+ <item> max-device-width </item>
+ <item> device-height </item>
+ <item> min-device-height </item>
+ <item> max-device-height </item>
+ <item> orientation </item>
+ <item> aspect-ratio </item>
+ <item> min-aspect-ratio </item>
+ <item> max-aspect-ratio </item>
+ <item> device-aspect-ratio </item>
+ <item> min-device-aspect-ratio </item>
+ <item> max-device-aspect-ratio </item>
+ <item> color </item>
+ <item> min-color </item>
+ <item> max-color </item>
+ <item> color-index </item>
+ <item> min-color-index </item>
+ <item> max-color-index </item>
+ <item> monochrome </item>
+ <item> min-monochrome </item>
+ <item> max-monochrome </item>
+ <item> resolution </item>
+ <item> min-resolution </item>
+ <item> max-resolution </item>
+ <item> scan </item>
+ <item> grid </item>
+ </list>
+
<list name="pseudoclasses">
<item> hover </item>
<item> link </item>
@@ -704,11 +749,55 @@ Changelog:
<!-- other contexts -->
<context attribute="Normal Text" lineEndContext="#stay" name="Media">
<DetectChar attribute="Media" context="Media2" char="{" beginRegion="media" />
- <keyword attribute="Media" context="#stay" String="mediatypes" />
+ <DetectChar attribute="Media" context="MediaQueryExpression" char="(" />
+ <keyword attribute="Media" context="MediaQueries" String="mediatypes"/>
+ <keyword attribute="Media" context="MediaTypes" String="mediatypes_op" />
<DetectChar attribute="Media" context="#stay" char="," />
<IncludeRules context="FindComments" />
<RegExpr attribute="Error" context="#stay" String="\S+" />
</context>
+
+ <context attribute="Media" lineEndContext="#stay" name="MediaTypes">
+ <keyword attribute="Media" context="MediaQueries" String="mediatypes"/>
+ <DetectChar attribute="Media" context="#pop" char= "{" lookAhead="true"/>
+ <DetectChar attribute="Media" context="#pop" char= "," lookAhead="true"/>
+ <DetectSpaces/>
+ <IncludeRules context="FindComments"/>
+ <RegExpr attribute="Error" context="#stay" String="\S+"/>
+ </context>
+
+ <context attribute="Media" lineEndContext="#stay" name="MediaQueries">
+ <RegExpr attribute="Media" context="MediaQueryExpression" String="\s+and\s+\("/>
+ <DetectChar attribute="Media" context="#pop" char= "{" lookAhead="true"/>
+ <DetectChar attribute="Media" context="#pop" char= "," lookAhead="true"/>
+ <DetectSpaces/>
+ <IncludeRules context="FindComments"/>
+ <RegExpr attribute="Error" context="#stay" String="\S+"/>
+ </context>
+
+ <context attribute="Media" lineEndContext="#stay" name="MediaQueryExpression">
+ <DetectSpaces/>
+ <keyword attribute="Media" context="MQEE" String="media_features"/>
+ <IncludeRules context="FindComments"/>
+ <RegExpr attribute="Error" context="#stay" String="\S+"/>
+ </context>
+
+ <context attribute="Media" lineEndContext="#stay" name="MQEE" fallthrough="true" fallthroughContext="#pop">
+ <DetectSpaces/>
+ <IncludeRules context="FindComments"/>
+ <DetectChar attribute="Media" context="MQEV" char=":"/>
+ <RegExpr attribute="Media" context="#pop" String="\)\s+and\s+\("/>
+ <DetectChar attribute="Media" context="#pop#pop" char=")"/>
+ </context>
+
+ <context attribute="Media" lineEndContext="#stay" name="MQEV">
+ <!-- this should be seperate for different features, for now it is all the same -->
+ <RegExpr attribute="Value" context="#pop" String="[1-9][0-9.]*\s*/\s*[1-9][0-9.]*" />
+ <RegExpr attribute="Value" context="#pop" String="[0-9.]+(em|ex|ch|rem|vw|vh|vm|px|in|cm|mm|pt|pc|deg|rad|grad|turn|ms|s|Hz|kHz|dpi|dpcm)\b" />
+ <RegExpr attribute="Value" context="#pop" String="[0-9.]+[%]?" />
+ <RegExpr attribute="Value" context="#pop" String="(portrait|landscape)" />
+ <RegExpr attribute="Error" context="#stay" String=".*"/>
+ </context>
<context attribute="Normal Text" lineEndContext="#stay" name="Media2">
<DetectChar attribute="Media" context="#pop#pop" char="}" endRegion="media" />