Remove definition of 'color' property and an example of its use.
authorCameron McCormack <cam@mcc.id.au>
Sun, 27 May 2012 12:29:37 +1000
changeset 167 467d465f148c
parent 166 60e29b32e047
child 168 c7fd9e21f66d
Remove definition of 'color' property and an example of its use.
master/color.html
master/refs.html
master/style/default_svg.css
--- a/master/color.html	Sat May 26 16:49:38 2012 -0700
+++ b/master/color.html	Sun May 27 12:29:37 2012 +1000
@@ -62,63 +62,56 @@
 Note that, in this specification, color interpolation occurs in an RGB color space even if an
 ICC-based color specification is provided (see <a>'color-interpolation'</a>).</p>
 
-<h2 id="ColorProperty">The <span class="property">'color'</span> property</h2>
-
-<p>The <a>'color'</a> property is used to provide a potential indirect value
-(<span class="prop-value">currentColor</span>) for the <a>'fill'</a>,
-<a>'stroke'</a>, <a>'stop-color'</a>, <a>'flood-color'</a> and
-<a>'lighting-color'</a> properties.</p>
+<div class="ready-for-wg-review">
+<h2 id="ColorProperty">The effect of the <span class="property">'color'</span> property</h2>
 
-    <div class="propdef">
-      <dl>
-        <dt><span class="propdef-title property">'color'</span></dt>
-        <dd>
-          <table summary="color property" class="propinfo"
-          cellspacing="0" cellpadding="0">
-            <tr valign="baseline">
-              <td><em>Value:</em>&nbsp;&nbsp;</td>
-              <td><a
-              href="types.html#DataTypeColor">&lt;color&gt;</a> |
-              <a class="noxref"
-              href="http://www.w3.org/TR/2008/REC-CSS2-20080411/cascade.html#value-def-inherit">
-              <span
-              class="value-inst-inherit noxref">inherit</span></a></td>
-            </tr>
-            <tr valign="baseline">
-              <td><em>Initial:</em>&nbsp;&nbsp;</td>
-              <td>depends on user agent</td>
-            </tr>
-            <tr valign="baseline">
-              <td><em>Applies to:</em>&nbsp;&nbsp;</td>
-              <td>elements to which properties <a>'fill'</a>, <a>'stroke'</a>,
-              <a>'stop-color'</a>, <a>'flood-color'</a> and <a>'lighting-color'</a>
-              apply</td>
-            </tr>
-            <tr valign="baseline">
-              <td><em>Inherited:</em>&nbsp;&nbsp;</td>
-              <td>yes</td>
-            </tr>
-            <tr valign="baseline">
-              <td><em>Percentages:</em>&nbsp;&nbsp;</td>
-              <td>N/A</td>
-            </tr>
-            <tr valign="baseline">
-              <td><em>Media:</em>&nbsp;&nbsp;</td>
-              <td>visual</td>
-            </tr>
-            <tr valign="baseline">
-              <td><em><a
-              href="animate.html#Animatable">Animatable</a>:</em>&nbsp;&nbsp;</td>
-              <td>yes</td>
-            </tr>
-          </table>
-        </dd>
-      </dl>
+<p class="note">See the CSS Color Module Level 3 specification for the
+definition of <a>'color'</a>.
+[<a href="refs.html#ref-CSS3COLOR">CSS3COLOR</a>]</p>
+
+<p>The <a>'color'</a> property is used to provide a potential indirect value,
+<span class="prop-value">currentColor</span>, for the <a>'fill'</a>,
+<a>'stroke'</a>, <a>'solid-color'</a>, <a>'stop-color'</a>, <a>'flood-color'</a> and
+<a>'lighting-color'</a> properties.  The property has no other effect
+on SVG elements.</p>
+
+<div class="example">
+  <p>The following example shows how the inherited value of the
+  <a>'color'</a> property from an HTML document can be used to
+  set the color of SVG text in an inline SVG fragment.</p>
+
+  <pre><![CDATA[
+<!DOCTYPE html>
+<style>
+body { color: #468; font: 16px sans-serif }
+svg { border: 1px solid #888; background-color: #eee }
+</style>
+<p>Please see the diagram below:</p>
+<svg width="200" height="100">
+  <g fill="currentColor">
+    <text x="70" y="55" text-anchor="end">START</text>
+    <text x="130" y="55">STOP</text>
+    <path d="M 85,45 h 25 v -5 l 10,10 -10,10 v -5 h -25 z"/>
+  </g>
+</svg>
+]]></pre>
+
+  <div class="figure">
+    <div class="bordered" style="color: #468; font: 16px sans-serif; display: inline-block; text-align: left; padding: 32px 128px 32px 32px">
+      <p style="margin-top: 0; margin-bottom: 1em">Please see the diagram below:</p>
+      <svg xmlns="http://www.w3.org/2000/svg" width="200" height="100" style="border: 1px solid #888; background-color: #eee">
+        <g fill="currentColor">
+          <text x="70" y="55" text-anchor="end">START</text>
+          <text x="130" y="55">STOP</text>
+          <path d="M 85,45 h 25 v -5 l 10,10 -10,10 v -5 h -25 z"/>
+        </g>
+      </svg>
     </div>
-
-<p>Except for any additional information provided in this
-specification, the <a href="http://www.w3.org/TR/2008/REC-CSS2-20080411/colors.html#propdef-color">normative definition of the property</a>
-is in CSS2 ([<a href="refs.html#ref-CSS2">CSS2</a>], section 14.1).</p>
+    <p class="caption">The text and arrow in the SVG fragment are filled
+    with the same color as the inherited <a>'color'</a> property.</p>
+  </div>
+</div>
+</div>
 
 <h2 id="ColorProfileDescriptions">Color profile descriptions</h2>
 
--- a/master/refs.html	Sat May 26 16:49:38 2012 -0700
+++ b/master/refs.html	Sun May 27 12:29:37 2012 +1000
@@ -68,6 +68,15 @@
   </dd>
 
 <dl class="references ready-for-wg-review">
+  <dt id="ref-CSS3COLOR" class="normref">[CSS3COLOR]</dt>
+  <dd>
+    <cite class="w3crec"><a href="http://www.w3.org/TR/2011/REC-css3-color-20110607/">CSS Color Module Level 3</a></cite>,
+    T. Çelik, C. Lilley, L. D. Baron, eds.
+    <br/>This edition of CSS3 Color is http://www.w3.org/TR/2011/REC-css3-color-20110607/.
+    <br/>The <a href="http://www.w3.org/TR/css3-color/">latest edition of CSS3 Color</a> is available at
+    http://www.w3.org/TR/css3-color/.
+  </dd>
+
   <dt id="ref-CSS3UI" class="normref">[CSS3UI]</dt>
   <dd>
     <cite class="w3cwd"><a href="http://www.w3.org/TR/2012/WD-css3-ui-20120117/">CSS Basic User Interface Module Level 3 (CSS3 UI)</a></cite>,
--- a/master/style/default_svg.css	Sat May 26 16:49:38 2012 -0700
+++ b/master/style/default_svg.css	Sun May 27 12:29:37 2012 +1000
@@ -245,7 +245,7 @@
 }
 
 /* A border to be used around images. */
-img.bordered { border: 1px solid #888; background-color: white }
+.bordered { border: 1px solid #888; background-color: white }
 
 dl.attrdef-list dl { margin-top: 1em }
 dl.attrdef-list > dt { font-weight: normal }