From 708f7afb01170d036b0707871d6254b4576b5017 Mon Sep 17 00:00:00 2001 From: Kyo Nagashima Date: Sat, 15 Apr 2017 11:57:19 +0900 Subject: [PATCH] Prefer CSS spec --- after/syntax/css/fill-stroke-3.vim | 8 +++-- after/syntax/css/svg2.vim | 5 +-- test/test.css | 52 +++++++++++++++--------------- test/test.html | 52 +++++++++++++++--------------- 4 files changed, 58 insertions(+), 59 deletions(-) diff --git a/after/syntax/css/fill-stroke-3.vim b/after/syntax/css/fill-stroke-3.vim index d315150..f5d9faf 100644 --- a/after/syntax/css/fill-stroke-3.vim +++ b/after/syntax/css/fill-stroke-3.vim @@ -1,3 +1,5 @@ -syn match cssFontProp contained "\<\(fill\|stroke\)-\(break\|color\|image\|origin\|position\|size\|repeat\)\>" -syn match cssFontProp contained "\" -syn keyword cssFontAttr contained stupid compress dashes gaps +syn match cssFontProp contained "\<\(fill\|stroke\)\(-\(break\|color\|image\|origin\|position\|size\|repeat\|opacity\)\)\=\>" +syn match cssFontProp contained "\" +syn match cssFontProp contained "\" +syn keyword cssFontAttr contained butt arcs stupid compress dashes gaps +syn match cssFontAttr contained "\" diff --git a/after/syntax/css/svg2.vim b/after/syntax/css/svg2.vim index 4a605f6..84a40a0 100644 --- a/after/syntax/css/svg2.vim +++ b/after/syntax/css/svg2.vim @@ -2,19 +2,16 @@ syn keyword cssTagName animate animateMotion animateTransform circle clipPath cu syn keyword cssFontProp contained cx cy d r rx ry x y syn match cssFontProp contained "\" -syn match cssFontProp contained "\" syn match cssFontProp contained "\" syn match cssFontProp contained "\" syn match cssFontProp contained "\" syn match cssFontProp contained "\" syn match cssFontProp contained "\" syn match cssFontProp contained "\" -syn match cssFontProp contained "\" syn match cssFontProp contained "\" syn match cssFontProp contained "\" -syn keyword cssFontAttr contained arcs butt crispEdges geometricPrecision optimizeQuality painted stroke viewport visibleFill visiblePainted visibleStroke -syn match cssFontAttr contained "\" +syn keyword cssFontAttr contained crispEdges geometricPrecision optimizeQuality painted stroke viewport visibleFill visiblePainted visibleStroke syn match cssFontAttr contained "\" syn match cssFontAttr contained "\" syn match cssFontAttr contained "\" diff --git a/test/test.css b/test/test.css index e385dca..a16db24 100644 --- a/test/test.css +++ b/test/test.css @@ -224,15 +224,24 @@ } .fill-stroke-3 { - fill-break: stupid; - fill-color: compress; - fill-image: dashes; - fill-origin: gaps; - fill-position: auto; - fill-size: auto; + fill-rule: butt; + fill-break: arcs; + fill-color: stupid; + fill-image: compress; + fill-origin: dashes; + fill-position: gaps; + fill-size: bounding-box; fill-repeat: auto; + fill: auto; + fill-opacity: auto; + stroke-width: auto; stroke-align: auto; + stroke-linecap: auto; + stroke-linejoin: auto; + stroke-miterlimit: auto; stroke-break: auto; + stroke-dasharray: auto; + stroke-dashoffset: auto; stroke-dash-corner: auto; stroke-dash-justify: auto; stroke-color: auto; @@ -241,6 +250,8 @@ stroke-position: auto; stroke-size: auto; stroke-repeat: auto; + stroke: auto; + stroke-opacity: auto; } .filter-effects-1 { @@ -874,18 +885,15 @@ tspan, unknown, use, view { - color-interpolation: arcs; - color-rendering: butt; - cx: crispEdges; - cy: geometricPrecision; - d: optimizeQuality; - fill-opacity: painted; - fill-rule: stroke; - fill: viewport; + color-interpolation: crispEdges; + color-rendering: geometricPrecision; + cx: optimizeQuality; + cy: painted; + d: visiblePainted; image-rendering: visibleFill; - marker-end: visiblePainted; - marker-mid: visibleStroke; - marker-start: bounding-box; + marker-end: stroke; + marker-mid: viewport; + marker-start: visibleStroke; pointer-events: context-fill; r: context-stroke; rx: fixed-position; @@ -895,15 +903,7 @@ view { solid-opacity: non-scaling-size; stop-color: non-rotation; stop-opacity: child(1); - stroke-dasharray: icc-color(foo); - stroke-dashoffset: auto; - stroke-linecap: auto; - stroke-linejoin: auto; - stroke-miterlimit: auto; - stroke-opacity: auto; - stroke-width: auto; - stroke: auto; - text-anchor: auto; + text-anchor: icc-color(foo); vector-effect: auto; x: auto; y: auto; diff --git a/test/test.html b/test/test.html index d6fa25f..269533e 100644 --- a/test/test.html +++ b/test/test.html @@ -253,15 +253,24 @@