E84D [cssom] Editorial: Use clearer prose for how serialize comma-separate… · w3c/csswg-drafts@6d5aae4 · GitHub
Skip to content

Commit 6d5aae4

Browse files
author
Simon Pieters
committed
[cssom] Editorial: Use clearer prose for how serialize comma-separated things. https://www.w3.org/Bugs/Public/show_bug.cgi?id=16266
1 parent c7a0b62 commit 6d5aae4

2 files changed

Lines changed: 49 additions & 37 deletions

File tree

cssom/Overview.html

Lines changed: 27 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
<h1>CSS Object Model (CSSOM)</h1>
1717

1818

19-
<h2 class="no-num no-toc" id="w3c-doctype">Editor's Draft 21 August 2013</h2>
19+
<h2 class="no-num no-toc" id="w3c-doctype">Editor's Draft 23 August 2013</h2>
2020

2121
<dl>
2222

@@ -90,7 +90,7 @@ <h2 class="no-num no-toc" id="sotd">Status of This Document</h2>
9090
can be found in the
9191
<a href="http://www.w3.org/TR/">W3C technical reports index at http://www.w3.org/TR/.</a></em>
9292

93-
<p class="dontpublish">This is the 21 August 2013 Editor's Draft of CSSOM. Please send comments to
93+
<p class="dontpublish">This is the 23 August 2013 Editor's Draft of CSSOM. Please send comments to
9494
<a href="mailto:www-style@w3.org?subject=%5Bcssom%5D%20">www-style@w3.org</a>
9595
(<a href="http://lists.w3.org/Archives/Public/www-style/">archived</a>)
9696
with <samp>[cssom]</samp> at the start of the subject line.
@@ -2245,7 +2245,7 @@ <h4 id="the-cssstyledeclaration-interface"><span class="secno">6.5.1 </span>The
22452245
void <a href="#dom-cssstyledeclaration-setproperty" title="dom-CSSStyleDeclaration-setProperty">setProperty</a>(DOMString property, [TreatNullAs=EmptyString] DOMString value, <!--
22462246
-->[TreatNullAs=EmptyString] optional DOMString priority);
22472247
DOMString <a href="#dom-cssstyledeclaration-removeproperty" title="dom-CSSStyleDeclaration-removeProperty">removeProperty</a>(DOMString property);
2248-
readonly attribute <a href="#cssrule">CSSRule</a>? <a href="#dom-cssstyledeclaration-length" title="dom-CSSStyleDeclaration-length">parentRule</a>;
2248+
readonly attribute <a href="#cssrule">CSSRule</a>? <a href="#dom-cssstyledeclaration-parentrule" title="dom-CSSStyleDeclaration-parentRule">parentRule</a>;
22492249
attribute DOMString <a href="#dom-cssstyledeclaration-cssfloat" title="dom-CSSStyleDeclaration-cssFloat">cssFloat</a>;<!-- setProperty's value arg has [TreatNullAs=EmptyString] -->
22502250
};</pre>
22512251

@@ -2371,8 +2371,8 @@ <h4 id="the-cssstyledeclaration-interface"><span class="secno">6.5.1 </span>The
23712371
<li><p>Return <var>value</var>.
23722372
</ol>
23732373

2374-
<p>The <dfn id="dom-cssstyledeclaration-parentrule" title="dom-CSSStyleDeclaration-parentRule"><code>parentRule</code></dfn> attribute must return the <code><a href="#cssrule">CSSrule</a></code> object the
2375-
<code><a href="#cssstyledeclaration">CSSStyleDeclaration</a></code> is object is associated with or null if it is not associated with a <code><a href="#cssrule">CSSrule</a></code> object.</p>
2374+
<p>The <dfn id="dom-cssstyledeclaration-parentrule" title="dom-CSSStyleDeclaration-parentRule"><code>parentRule</code></dfn> attribute must return the <code><a href="#cssrule">CSSRule</a></code> object the
2375+
<code><a href="#cssstyledeclaration">CSSStyleDeclaration</a></code> is object is associated with or null if it is not associated with a <code><a href="#cssrule">CSSRule</a></code> object.</p>
23762376

23772377
<p>The <dfn id="dom-cssstyledeclaration-cssfloat" title="dom-CSSStyleDeclaration-cssFloat"><code>cssFloat</code></dfn>
23782378
attribute, on getting, must return the result of invoking
@@ -2617,18 +2617,18 @@ <h4 id="serializing-css-values"><span class="secno">6.6.2 </span>Serializing CSS
26172617

26182618
<dt>&lt;counter&gt;</dt>
26192619
<dd>
2620-
<p>The concatenation of:</p>
2620+
<p>The return value of the following algorithm:</p>
26212621
<ol>
2622-
<li><p>If &lt;counter&gt; has three CSS component values the string
2623-
"<code title="">counters(</code>".</li>
2624-
<li><p>If &lt;counter&gt; has two CSS component values the string
2625-
"<code title="">counter(</code>".</li>
2626-
<li><p>The result of
2627-
<a href="#serialize-a-comma-separated-list" title="serialize a comma-separated list">serializing</a> the
2628-
<a href="#serialize-a-css-component-value" title="serialize a CSS component value">serialized</a>
2629-
CSS component values belonging to &lt;counter&gt; as list while omitting
2630-
the last CSS component value if it is 'decimal'.</li>
2631-
<li><p>"<code title="">)</code>" (U+0029).</li>
2622+
<li><p>Let <var>s</var> be the empty string.
2623+
<li><p>If &lt;counter&gt; has three CSS component values append the string
2624+
"<code title="">counters(</code>" to <var>s</var>.</li>
2625+
<li><p>If &lt;counter&gt; has two CSS component values append the string
2626+
"<code title="">counter(</code>" to <var>s</var>.</li>
2627+
<li><p>Let <var>list</var> be a list of CSS component values belonging to &lt;counter&gt;, omitting the last CSS component value if it is 'decimal'.
2628+
<li><p>Let each item in <var>list</var> be the result of invoking <a href="#serialize-a-css-component-value">serialize a CSS component value</a> on that item.
2629+
<li><p>Append the result of invoking <a href="#serialize-a-comma-separated-list">serialize a comma-separated list</a> on <var>list</var> to <var>s</var>.
2630+
<li><p>Append "<code title="">)</code>" (U+0029) to <var>s</var>.</li>
2631+
<li><p>Return <var>s</var>.
26322632
</ol>
26332633
</dd>
26342634

@@ -2677,11 +2677,17 @@ <h4 id="serializing-css-values"><span class="secno">6.6.2 </span>Serializing CSS
26772677
&lt;number&gt; followed by the literal string "<code title="">dpcm</code>".</dd>
26782678

26792679
<dt>&lt;shape&gt;</dt>
2680-
<dd><p>The string "<code title="">rect(</code>", followed by the result
2681-
of <a href="#serialize-a-comma-separated-list" title="serialize a comma-separated list">serializing</a> the
2682-
<a href="#serialize-a-css-component-value" title="serialize a CSS component value">serialized</a>
2683-
CSS component values belonging to &lt;shape&gt; as list, followed by
2684-
"<code title="">)</code>" (U+0029).</dd>
2680+
<dd>
2681+
<p>The return value of the following algorithm:
2682+
<ol>
2683+
<li><p>Let <var>s</var> be the string "<code title="">rect(</code>".
2684+
<li><p>Let <var>list</var> be a list of the CSS component values belonging to &lt;shape&gt;.
2685+
<li><p>Let each item in <var>list</var> be the result of invoking <a href="#serialize-a-css-component-value">serialize a CSS component value</a> of that item.
2686+
<li><p>Append the result of invoking <a href="#serialize-a-comma-separated-list">serialize a comma-separated list</a> on <var>list</var> to <var>s</var>.
2687+
<li><p>Append "<code title="">)</code>" (U+0029) to <var>s</var>.
2688+
<li><p>Return <var>s</var>.
2689+
</ol>
2690+
</dd>
26852691

26862692
<dt>&lt;string&gt;</dt>
26872693
<dt>&lt;family-name&gt;</dt>

cssom/Overview.src.html

Lines changed: 22 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2538,18 +2538,18 @@ <h4>Serializing CSS Values</h4>
25382538

25392539
<dt>&lt;counter></dt>
25402540
<dd>
2541-
<p>The concatenation of:</p>
2541+
<p>The return value of the following algorithm:</p>
25422542
<ol>
2543-
<li><p>If &lt;counter> has three CSS component values the string
2544-
"<code title>counters(</code>".</p></li>
2545-
<li><p>If &lt;counter> has two CSS component values the string
2546-
"<code title>counter(</code>".</p></li>
2547-
<li><p>The result of
2548-
<span title="serialize a comma-separated list">serializing</span> the
2549-
<span title="serialize a CSS component value">serialized</span>
2550-
CSS component values belonging to &lt;counter> as list while omitting
2551-
the last CSS component value if it is 'decimal'.</p></li>
2552-
<li><p>"<code title>)</code>" (U+0029).</p></li>
2543+
<li><p>Let <var>s</var> be the empty string.
2544+
<li><p>If &lt;counter> has three CSS component values append the string
2545+
"<code title>counters(</code>" to <var>s</var>.</p></li>
2546+
<li><p>If &lt;counter> has two CSS component values append the string
2547+
"<code title>counter(</code>" to <var>s</var>.</p></li>
2548+
<li><p>Let <var>list</var> be a list of CSS component values belonging to &lt;counter>, omitting the last CSS component value if it is 'decimal'.
2549+
<li><p>Let each item in <var>list</var> be the result of invoking <span>serialize a CSS component value</span> on that item.
2550+
<li><p>Append the result of invoking <span>serialize a comma-separated list</span> on <var>list</var> to <var>s</var>.
2551+
<li><p>Append "<code title>)</code>" (U+0029) to <var>s</var>.</p></li>
2552+
<li><p>Return <var>s</var>.
25532553
</ol>
25542554
</dd>
25552555

@@ -2598,11 +2598,17 @@ <h4>Serializing CSS Values</h4>
25982598
&lt;number> followed by the literal string "<code title>dpcm</code>".</dd>
25992599

26002600
<dt>&lt;shape></dt>
2601-
<dd><p>The string "<code title>rect(</code>", followed by the result
2602-
of <span title="serialize a comma-separated list">serializing</span> the
2603-
<span title="serialize a CSS component value">serialized</span>
2604-
CSS component values belonging to &lt;shape> as list, followed by
2605-
"<code title>)</code>" (U+0029).</p></dd>
2601+
<dd>
2602+
<p>The return value of the following algorithm:
2603+
<ol>
2604+
<li><p>Let <var>s</var> be the string "<code title>rect(</code>".
2605+
<li><p>Let <var>list</var> be a list of the CSS component values belonging to &lt;shape>.
2606+
<li><p>Let each item in <var>list</var> be the result of invoking <span>serialize a CSS component value</span> of that item.
2607+
<li><p>Append the result of invoking <span>serialize a comma-separated list</span> on <var>list</var> to <var>s</var>.
2608+
<li><p>Append "<code title>)</code>" (U+0029) to <var>s</var>.
2609+
<li><p>Return <var> 5687 s</var>.
2610+
</ol>
2611+
</dd>
26062612

26072613
<dt>&lt;string></dt>
26082614
<dt>&lt;family-name></dt>

0 commit comments

Comments
 (0)