Skip to content
Permalink
Browse files
[] (0) Clarify DOMTokenList's case-sensitivity.
git-svn-id: http://svn.whatwg.org/webapps@3388 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Jul 13, 2009
1 parent ca598b3 commit d0a978b0e65435c82dda149f0aaaf826826e866b
Showing with 37 additions and 25 deletions.
  1. +18 −13 index
  2. +19 −12 source
31 index
@@ -67,7 +67,7 @@
<div class=head>
<p><a class=logo href=http://www.whatwg.org/ rel=home><img alt=WHATWG src=/images/logo></a></p>
<h1>HTML 5</h1>
<h2 class="no-num no-toc" id=draft-standard-&mdash;-date:-01-jan-1901>Draft Standard &mdash; 12 July 2009</h2>
<h2 class="no-num no-toc" id=draft-standard-&mdash;-date:-01-jan-1901>Draft Standard &mdash; 13 July 2009</h2>
<p>You can take part in this work. <a href=http://www.whatwg.org/mailing-list>Join the working group's discussion list.</a></p>
<p><strong>Web designers!</strong> We have a <a href=http://blog.whatwg.org/faq/>FAQ</a>, a <a href=http://forums.whatwg.org/>forum</a>, and a <a href=http://www.whatwg.org/mailing-list#help>help mailing list</a> for you!</p>
<!--<p class="impl"><strong>Implementors!</strong> We have a <a href="http://www.whatwg.org/mailing-list#implementors">mailing list</a> for you too!</p>-->
@@ -5775,6 +5775,10 @@ interface <dfn id=propertynodelist>PropertyNodeList</dfn> : <span>NodeList</span
preserves the underlying order for consistency between
implementations.</p>

<p class=note><code><a href=#domtokenlist-0>DOMTokenList</a></code> objects are always
<a href=#case-sensitive>case-sensitive</a>, even when the underlying string might
ordinarily be treated in a case-insensitive manner.</p>

<pre class=idl>[<a href=#dom-tokenlist-tostring title=dom-tokenlist-toString>Stringifies</a>] interface <dfn id=domtokenlist-0>DOMTokenList</dfn> {
readonly attribute unsigned long <a href=#dom-tokenlist-length title=dom-tokenlist-length>length</a>;
[IndexGetter] DOMString <a href=#dom-tokenlist-item title=dom-tokenlist-item>item</a>(in unsigned long index);
@@ -5792,7 +5796,7 @@ interface <dfn id=propertynodelist>PropertyNodeList</dfn> : <span>NodeList</span
<dt><var title="">element</var> = <var title="">tokenlist</var> . <code title=dom-tokenlist-item><a href=#dom-tokenlist-item>item</a></code>(<var title="">index</var>)</dt>
<dt><var title="">tokenlist</var>[<var title="">index</var>]</dt>
<dd>
<p>Returns the token with index <var title="">index</var>. The tokens are sorted alphabetically.</p>
<p>Returns the token with index <var title="">index</var>. The tokens are returned in the order they are found in the underlying string, with duplicates removed.</p>
<p>Returns null if <var title="">index</var> is out of range.</p>
</dd>

@@ -5853,9 +5857,10 @@ interface <dfn id=propertynodelist>PropertyNodeList</dfn> : <span>NodeList</span
underlying string on spaces</a> to get the list of tokens in the
object's underlying string.</li>

<li>If the token indicated by <var title="">token</var> is one of
the tokens in the object's underlying string then return true and
stop this algorithm.</li>
<li>If the token indicated by <var title="">token</var> is a
<a href=#case-sensitive>case-sensitive</a> match for one of the tokens in the
object's underlying string then return true and stop this
algorithm.</li>

<li>Otherwise, return false.</li>

@@ -5870,9 +5875,10 @@ interface <dfn id=propertynodelist>PropertyNodeList</dfn> : <span>NodeList</span
underlying string on spaces</a> to get the list of tokens in the
object's underlying string.</li>

<li>If the given <var title="">token</var> is already one of the
tokens in the <code><a href=#domtokenlist-0>DOMTokenList</a></code> object's underlying string
then stop the algorithm.</li>
<li>If the given <var title="">token</var> is a
<a href=#case-sensitive>case-sensitive</a> match for one of the tokens in the
<code><a href=#domtokenlist-0>DOMTokenList</a></code> object's underlying string then stop the
algorithm.</li>

<li>Otherwise, if the <code><a href=#domtokenlist-0>DOMTokenList</a></code> object's underlying
string is not the empty string and the last character of that
@@ -5904,11 +5910,10 @@ interface <dfn id=propertynodelist>PropertyNodeList</dfn> : <span>NodeList</span
underlying string on spaces</a> to get the list of tokens in the
object's underlying string.</li>

<li>If the given <var title="">token</var> is already one of the
tokens in the <code><a href=#domtokenlist-0>DOMTokenList</a></code> object's underlying string
then <a href=#remove-a-token-from-a-string title="remove a token from a string">remove the given
<var title="">token</var> from the underlying string</a>, and
stop the algorithm, returning false.</li>
<li>If the given <var title="">token</var> is a
<a href=#case-sensitive>case-sensitive</a> match for one of the tokens in the
<code><a href=#domtokenlist-0>DOMTokenList</a></code> object's underlying string then <a href=#remove-a-token-from-a-string title="remove a token from a string">remove the given <var title="">token</var> from the underlying string</a> and stop the
algorithm, returning false.</li>

<li>Otherwise, if the <code><a href=#domtokenlist-0>DOMTokenList</a></code> object's underlying
string is not the empty string and the last character of that
31 source
@@ -5613,6 +5613,10 @@ interface <dfn>PropertyNodeList</dfn> : <span>NodeList</span> {
preserves the underlying order for consistency between
implementations.</p>

<p class="note"><code>DOMTokenList</code> objects are always
<span>case-sensitive</span>, even when the underlying string might
ordinarily be treated in a case-insensitive manner.</p>

<pre class="idl">[<span title="dom-tokenlist-toString">Stringifies</span>] interface <dfn>DOMTokenList</dfn> {
readonly attribute unsigned long <span title="dom-tokenlist-length">length</span>;
[IndexGetter] DOMString <span title="dom-tokenlist-item">item</span>(in unsigned long index);
@@ -5632,7 +5636,7 @@ interface <dfn>PropertyNodeList</dfn> : <span>NodeList</span> {
<dt><var title="">element</var> = <var title="">tokenlist</var> . <code title="dom-tokenlist-item">item</code>(<var title="">index</var>)</dt>
<dt><var title="">tokenlist</var>[<var title="">index</var>]</dt>
<dd>
<p>Returns the token with index <var title="">index</var>. The tokens are sorted alphabetically.</p>
<p>Returns the token with index <var title="">index</var>. The tokens are returned in the order they are found in the underlying string, with duplicates removed.</p>
<p>Returns null if <var title="">index</var> is out of range.</p>
</dd>

@@ -5707,9 +5711,10 @@ interface <dfn>PropertyNodeList</dfn> : <span>NodeList</span> {
underlying string on spaces</span> to get the list of tokens in the
object's underlying string.</li>

<li>If the token indicated by <var title="">token</var> is one of
the tokens in the object's underlying string then return true and
stop this algorithm.</li>
<li>If the token indicated by <var title="">token</var> is a
<span>case-sensitive</span> match for one of the tokens in the
object's underlying string then return true and stop this
algorithm.</li>

<li>Otherwise, return false.</li>

@@ -5730,9 +5735,10 @@ interface <dfn>PropertyNodeList</dfn> : <span>NodeList</span> {
underlying string on spaces</span> to get the list of tokens in the
object's underlying string.</li>

<li>If the given <var title="">token</var> is already one of the
tokens in the <code>DOMTokenList</code> object's underlying string
then stop the algorithm.</li>
<li>If the given <var title="">token</var> is a
<span>case-sensitive</span> match for one of the tokens in the
<code>DOMTokenList</code> object's underlying string then stop the
algorithm.</li>

<li>Otherwise, if the <code>DOMTokenList</code> object's underlying
string is not the empty string and the last character of that
@@ -5776,11 +5782,12 @@ interface <dfn>PropertyNodeList</dfn> : <span>NodeList</span> {
underlying string on spaces</span> to get the list of tokens in the
object's underlying string.</li>

<li>If the given <var title="">token</var> is already one of the
tokens in the <code>DOMTokenList</code> object's underlying string
then <span title="remove a token from a string">remove the given
<var title="">token</var> from the underlying string</span>, and
stop the algorithm, returning false.</li>
<li>If the given <var title="">token</var> is a
<span>case-sensitive</span> match for one of the tokens in the
<code>DOMTokenList</code> object's underlying string then <span
title="remove a token from a string">remove the given <var
title="">token</var> from the underlying string</span> and stop the
algorithm, returning false.</li>

<li>Otherwise, if the <code>DOMTokenList</code> object's underlying
string is not the empty string and the last character of that

0 comments on commit d0a978b

Please sign in to comment.