[gtksourceview/gnome-3-24] css.lang: Add SVG specific properties and values
- From: Sébastien Wilmet <swilmet src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtksourceview/gnome-3-24] css.lang: Add SVG specific properties and values
- Date: Tue, 27 Dec 2016 17:44:05 +0000 (UTC)
commit 30e5e55c8cffef115cf12d38abbe9dd466e7a300
Author: Tobias Schönberg <tobias47n9e gmail com>
Date: Fri Dec 23 17:57:14 2016 +0100
css.lang: Add SVG specific properties and values
Currently a few SVG specific properties and values are not
highlighted correctly.
This commit adds the properties and values in seperate
blocks. Some properties and values are already in the CSS1
or CSS3 blocks. A few SVG property values can be written
using camelCase or lowercase.
https://bugzilla.gnome.org/show_bug.cgi?id=776449
data/language-specs/css.lang | 63 ++++++++++++++++++++++++++++++++++++++++++
1 files changed, 63 insertions(+), 0 deletions(-)
---
diff --git a/data/language-specs/css.lang b/data/language-specs/css.lang
index eef1a6d..4abe480 100644
--- a/data/language-specs/css.lang
+++ b/data/language-specs/css.lang
@@ -249,6 +249,37 @@
<keyword>progressive</keyword>
</context>
+ <context id="svg-property-names" style-ref="keyword">
+ <suffix>(?=\s*:)</suffix>
+ <keyword>clip-path</keyword>
+ <keyword>clip-rule</keyword>
+ <keyword>color-interpolatation-filters</keyword>
+ <keyword>color-interpolatation</keyword>
+ <keyword>dominant-baseline</keyword>
+ <keyword>fill-rule</keyword>
+ <keyword>fill-opacity</keyword>
+ <keyword>fill</keyword>
+ <keyword>flood-color</keyword>
+ <keyword>flood-opacity</keyword>
+ <keyword>lighting-color</keyword>
+ <keyword>marker-end</keyword>
+ <keyword>marker-mid</keyword>
+ <keyword>marker-start</keyword>
+ <keyword>shape-rendering</keyword>
+ <keyword>stop-color</keyword>
+ <keyword>stop-opacity</keyword>
+ <keyword>stroke-dasharray</keyword>
+ <keyword>stroke-dashoffset</keyword>
+ <keyword>stroke-linecap</keyword>
+ <keyword>stroke-linejoin</keyword>
+ <keyword>stroke-miterlimit</keyword>
+ <keyword>stroke-opacity</keyword>
+ <keyword>stroke-width</keyword>
+ <keyword>stroke</keyword>
+ <keyword>text-anchor</keyword>
+ <keyword>text-rendering</keyword>
+ </context>
+
<context id="css3-property-names" style-ref="keyword">
<suffix>(?=\s*:)</suffix>
<keyword>align-content</keyword>
@@ -490,6 +521,36 @@
<keyword>z-index</keyword>
</context>
+ <context id="svg-property-values" style-ref="property-values">
+ <prefix>\s</prefix>
+ <suffix>($|(?=[;\s]))</suffix>
+ <keyword>alphabetic</keyword>
+ <keyword>bevel</keyword>
+ <keyword>butt</keyword>
+ <keyword>central</keyword>
+ <keyword>crisp(E|e)dges</keyword>
+ <keyword>evenodd</keyword>
+ <keyword>geometric(P|p)recision</keyword>
+ <keyword>hanging</keyword>
+ <keyword>ideographic</keyword>
+ <keyword>lr-tb</keyword>
+ <keyword>lr</keyword>
+ <keyword>mathematical</keyword>
+ <keyword>miter</keyword>
+ <keyword>no-change</keyword>
+ <keyword>nonzero</keyword>
+ <keyword>optimize(L|l)egibility</keyword>
+ <keyword>optimize(S|s)peed</keyword>
+ <keyword>reset-size</keyword>
+ <keyword>rl-tb</keyword>
+ <keyword>rl</keyword>
+ <keyword>tb-rl</keyword>
+ <keyword>tb</keyword>
+ <keyword>text-after-edge</keyword>
+ <keyword>text-before-edge</keyword>
+ <keyword>use-script</keyword>
+ </context>
+
<context id="css3-property-values" style-ref="property-values">
<prefix>\s</prefix>
<suffix>($|(?=[;\s]))</suffix>
@@ -868,8 +929,10 @@
<context ref="number"/>
<context ref="unicode-range"/>
<context ref="importance-modifier"/>
+ <context ref="svg-property-names"/>
<context ref="css3-property-names"/>
<context ref="property-names"/>
+ <context ref="svg-property-values"/>
<context ref="css3-property-values"/>
<context ref="property-values"/>
</include>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]