Skip to content

Commit

Permalink
[giow] (2) Change a number of DOM attributes that historically have b…
Browse files Browse the repository at this point in the history
…een 'long' to 'unsigned long' to make the spec self-consistent about how the corresponding content attributes are parsed. (Browsers are very inconsistent about this today.)

git-svn-id: http://svn.whatwg.org/webapps@3400 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Jul 14, 2009
1 parent ebcdb32 commit 698f823
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 38 deletions.
37 changes: 18 additions & 19 deletions index
Expand Up @@ -5140,8 +5140,8 @@ a.<a href=#dom-uda-protocol title=dom-uda-protocol>protocol</a> = 'https'; // ch
absent, then the default value must be returned instead, or 0 if
there is no default value. On setting, the given value must be
converted to the shortest possible string representing the number as
a <a href=#valid-integer>valid integer</a> in base ten and then that string must
be used as the new content attribute value.</p>
a <a href=#valid-integer>valid integer</a> and then that string must be used as
the new content attribute value.</p>

<p>If a reflecting DOM attribute is an <em>unsigned</em> integer
type (<code>unsigned long</code>) then, on getting, the content
Expand All @@ -5153,8 +5153,8 @@ a.<a href=#dom-uda-protocol title=dom-uda-protocol>protocol</a> = 'https'; // ch
value must be returned instead, or 0 if there is no default
value. On setting, the given value must be converted to the shortest
possible string representing the number as a <a href=#valid-non-negative-integer>valid
non-negative integer</a> in base ten and then that string must be
used as the new content attribute value.</p>
non-negative integer</a> and then that string must be used as the
new content attribute value.</p>

<p>If a reflecting DOM attribute is an unsigned integer type
(<code>unsigned long</code>) that is <dfn id=limited-to-only-positive-non-zero-numbers>limited to only positive
Expand All @@ -5169,9 +5169,8 @@ a.<a href=#dom-uda-protocol title=dom-uda-protocol>protocol</a> = 'https'; // ch
value. On setting, if the value is zero, the user agent must fire an
<code><a href=#index_size_err>INDEX_SIZE_ERR</a></code> exception. Otherwise, the given value
must be converted to the shortest possible string representing the
number as a <a href=#valid-non-negative-integer>valid non-negative integer</a> in base ten and
then that string must be used as the new content attribute
value.</p>
number as a <a href=#valid-non-negative-integer>valid non-negative integer</a> and then that
string must be used as the new content attribute value.</p>

<p>If a reflecting DOM attribute is a floating point number type
(<code>float</code>) and it doesn't fall into one of the earlier
Expand Down Expand Up @@ -27178,8 +27177,8 @@ the cell that corresponds to the values of the two dice.
interface:</p>

<pre class=idl>interface <dfn id=htmltablecellelement>HTMLTableCellElement</dfn> : <a href=#htmlelement>HTMLElement</a> {
attribute long <a href=#dom-tdth-colspan title=dom-tdth-colSpan>colSpan</a>;
attribute long <a href=#dom-tdth-rowspan title=dom-tdth-rowSpan>rowSpan</a>;
attribute unsigned long <a href=#dom-tdth-colspan title=dom-tdth-colSpan>colSpan</a>;
attribute unsigned long <a href=#dom-tdth-rowspan title=dom-tdth-rowSpan>rowSpan</a>;
attribute DOMString <a href=#dom-tdth-headers title=dom-tdth-headers>headers</a>;
readonly attribute long <a href=#dom-tdth-cellindex title=dom-tdth-cellIndex>cellIndex</a>;
};</pre>
Expand Down Expand Up @@ -28895,7 +28894,7 @@ interface <dfn id=htmlformelement>HTMLFormElement</dfn> : <a href=#htmlelement>H
attribute boolean <a href=#dom-input-indeterminate title=dom-input-indeterminate>indeterminate</a>;
readonly attribute <a href=#htmlelement>HTMLElement</a> <a href=#dom-input-list title=dom-input-list>list</a>;
attribute DOMString <a href=#dom-input-max title=dom-input-max>max</a>;
attribute long <a href=#dom-input-maxlength title=dom-input-maxLength>maxLength</a>;
attribute unsigned long <a href=#dom-input-maxlength title=dom-input-maxLength>maxLength</a>;
attribute DOMString <a href=#dom-input-min title=dom-input-min>min</a>;
attribute boolean <a href=#dom-input-multiple title=dom-input-multiple>multiple</a>;
attribute DOMString <a href=#dom-fe-name title=dom-fe-name>name</a>;
Expand Down Expand Up @@ -33698,7 +33697,7 @@ interface <dfn id=htmlselectelement>HTMLSelectElement</dfn> : <a href=#htmleleme
readonly attribute <a href=#htmlformelement>HTMLFormElement</a> <a href=#dom-fae-form title=dom-fae-form>form</a>;
attribute boolean <a href=#dom-select-multiple title=dom-select-multiple>multiple</a>;
attribute DOMString <a href=#dom-fe-name title=dom-fe-name>name</a>;
attribute long <a href=#dom-select-size title=dom-select-size>size</a>;
attribute unsigned long <a href=#dom-select-size title=dom-select-size>size</a>;

readonly attribute DOMString <a href=#dom-select-type title=dom-select-type>type</a>;

Expand Down Expand Up @@ -34343,7 +34342,7 @@ interface <dfn id=htmloptionelement>HTMLOptionElement</dfn> : <a href=#htmleleme
attribute unsigned long <a href=#dom-textarea-cols title=dom-textarea-cols>cols</a>;
attribute boolean <a href=#dom-fe-disabled title=dom-fe-disabled>disabled</a>;
readonly attribute <a href=#htmlformelement>HTMLFormElement</a> <a href=#dom-fae-form title=dom-fae-form>form</a>;
attribute long <a href=#dom-textarea-maxlength title=dom-textarea-maxLength>maxLength</a>;
attribute unsigned long <a href=#dom-textarea-maxlength title=dom-textarea-maxLength>maxLength</a>;
attribute DOMString <a href=#dom-fe-name title=dom-fe-name>name</a>;
attribute DOMString <a href=#dom-textarea-placeholder title=dom-textarea-placeholder>placeholder</a>;
attribute boolean <a href=#dom-textarea-readonly title=dom-textarea-readOnly>readOnly</a>;
Expand Down Expand Up @@ -70292,10 +70291,10 @@ time:empty { binding: <i title="">time</i>; }</pre>
attribute DOMString <a href=#dom-applet-code title=dom-applet-code>code</a>;
attribute DOMString <a href=#dom-applet-codebase title=dom-applet-codeBase>codeBase</a>;
attribute DOMString <a href=#dom-applet-height title=dom-applet-height>height</a>;
attribute long <a href=#dom-applet-hspace title=dom-applet-hspace>hspace</a>;
attribute unsigned long <a href=#dom-applet-hspace title=dom-applet-hspace>hspace</a>;
attribute DOMString <a href=#dom-applet-name title=dom-applet-name>name</a>;
attribute DOMString <a href=#dom-applet-object title=dom-applet-object>object</a>;
attribute long <a href=#dom-applet-vspace title=dom-applet-vspace>vspace</a>;
attribute unsigned long <a href=#dom-applet-vspace title=dom-applet-vspace>vspace</a>;
attribute DOMString <a href=#dom-applet-width title=dom-applet-width>width</a>;
};</pre>

Expand Down Expand Up @@ -70892,9 +70891,9 @@ time:empty { binding: <i title="">time</i>; }</pre>
attribute DOMString <a href=#dom-img-name title=dom-img-name>name</a>;
attribute DOMString <a href=#dom-img-align title=dom-img-align>align</a>;
attribute DOMString <a href=#dom-img-border title=dom-img-border>border</a>;
attribute long <a href=#dom-img-hspace title=dom-img-hspace>hspace</a>;
attribute unsigned long <a href=#dom-img-hspace title=dom-img-hspace>hspace</a>;
attribute DOMString <a href=#dom-img-longdesc title=dom-img-longDesc>longDesc</a>;
attribute long <a href=#dom-img-vspace title=dom-img-vspace>vspace</a>;
attribute unsigned <a href=#dom-img-vspace title=dom-img-vspace>vspace</a>;
};</pre>

<p>The <dfn id=dom-img-name title=dom-img-name><code>name</code></dfn>, <dfn id=dom-img-align title=dom-img-align><code>align</code></dfn>, <dfn id=dom-img-border title=dom-img-border><code>border</code></dfn>, <dfn id=dom-img-hspace title=dom-img-hspace><code>hspace</code></dfn>, and <dfn id=dom-img-vspace title=dom-img-vspace><code>vspace</code></dfn> DOM attributes of
Expand Down Expand Up @@ -70970,9 +70969,9 @@ time:empty { binding: <i title="">time</i>; }</pre>
attribute DOMString <a href=#dom-object-codebase title=dom-object-codeBase>codeBase</a>;
attribute DOMString <a href=#dom-object-codetype title=dom-object-codeType>codeType</a>;
attribute boolean <a href=#dom-object-declare title=dom-object-declare>declare</a>;
attribute long <a href=#dom-object-hspace title=dom-object-hspace>hspace</a>;
attribute unsigned long <a href=#dom-object-hspace title=dom-object-hspace>hspace</a>;
attribute DOMString <a href=#dom-object-standby title=dom-object-standby>standby</a>;
attribute long <a href=#dom-object-vspace title=dom-object-vspace>vspace</a>;
attribute unsigned long <a href=#dom-object-vspace title=dom-object-vspace>vspace</a>;
};</pre>

<p>The <dfn id=dom-object-align title=dom-object-align><code>align</code></dfn>, <dfn id=dom-object-archive title=dom-object-archive><code>archive</code></dfn>, <dfn id=dom-object-border title=dom-object-border><code>border</code></dfn>, <dfn id=dom-object-code title=dom-object-code><code>code</code></dfn>, <dfn id=dom-object-declare title=dom-object-declare><code>declare</code></dfn>, <dfn id=dom-object-hspace title=dom-object-hspace><code>hspace</code></dfn>, <dfn id=dom-object-standby title=dom-object-standby><code>standby</code></dfn>, and <dfn id=dom-object-vspace title=dom-object-vspace><code>vspace</code></dfn> DOM attributes
Expand Down Expand Up @@ -71021,7 +71020,7 @@ time:empty { binding: <i title="">time</i>; }</pre>
<a href=#reflect>reflect</a> the element's <code title=attr-param-valuetype><a href=#attr-param-valuetype>valuetype</a></code> content attribute.</p>

<hr><pre class=idl>[Supplemental] interface <a href=#htmlpreelement>HTMLPreElement</a> {
attribute long <a href=#dom-pre-width title=dom-pre-width>width</a>;
attribute unsigned long <a href=#dom-pre-width title=dom-pre-width>width</a>;
};</pre>

<p>The <dfn id=dom-pre-width title=dom-pre-width><code>width</code></dfn> DOM
Expand Down
37 changes: 18 additions & 19 deletions source
Expand Up @@ -4845,8 +4845,8 @@ a.<span title="dom-uda-protocol">protocol</span> = 'https'; // change just the s
absent, then the default value must be returned instead, or 0 if
there is no default value. On setting, the given value must be
converted to the shortest possible string representing the number as
a <span>valid integer</span> in base ten and then that string must
be used as the new content attribute value.</p>
a <span>valid integer</span> and then that string must be used as
the new content attribute value.</p>

<p>If a reflecting DOM attribute is an <em>unsigned</em> integer
type (<code>unsigned long</code>) then, on getting, the content
Expand All @@ -4858,8 +4858,8 @@ a.<span title="dom-uda-protocol">protocol</span> = 'https'; // change just the s
value must be returned instead, or 0 if there is no default
value. On setting, the given value must be converted to the shortest
possible string representing the number as a <span>valid
non-negative integer</span> in base ten and then that string must be
used as the new content attribute value.</p>
non-negative integer</span> and then that string must be used as the
new content attribute value.</p>

<p>If a reflecting DOM attribute is an unsigned integer type
(<code>unsigned long</code>) that is <dfn>limited to only positive
Expand All @@ -4874,9 +4874,8 @@ a.<span title="dom-uda-protocol">protocol</span> = 'https'; // change just the s
value. On setting, if the value is zero, the user agent must fire an
<code>INDEX_SIZE_ERR</code> exception. Otherwise, the given value
must be converted to the shortest possible string representing the
number as a <span>valid non-negative integer</span> in base ten and
then that string must be used as the new content attribute
value.</p>
number as a <span>valid non-negative integer</span> and then that
string must be used as the new content attribute value.</p>

<p>If a reflecting DOM attribute is a floating point number type
(<code>float</code>) and it doesn't fall into one of the earlier
Expand Down Expand Up @@ -29951,8 +29950,8 @@ the cell that corresponds to the values of the two dice.
interface:</p>

<pre class="idl">interface <dfn>HTMLTableCellElement</dfn> : <span>HTMLElement</span> {
attribute long <span title="dom-tdth-colSpan">colSpan</span>;
attribute long <span title="dom-tdth-rowSpan">rowSpan</span>;
attribute unsigned long <span title="dom-tdth-colSpan">colSpan</span>;
attribute unsigned long <span title="dom-tdth-rowSpan">rowSpan</span>;
attribute DOMString <span title="dom-tdth-headers">headers</span>;
readonly attribute long <span title="dom-tdth-cellIndex">cellIndex</span>;
};</pre>
Expand Down Expand Up @@ -32050,7 +32049,7 @@ interface <dfn>HTMLFormElement</dfn> : <span>HTMLElement</span> {
attribute boolean <span title="dom-input-indeterminate">indeterminate</span>;
readonly attribute <span>HTMLElement</span> <span title="dom-input-list">list</span>;
attribute DOMString <span title="dom-input-max">max</span>;
attribute long <span title="dom-input-maxLength">maxLength</span>;
attribute unsigned long <span title="dom-input-maxLength">maxLength</span>;
attribute DOMString <span title="dom-input-min">min</span>;
attribute boolean <span title="dom-input-multiple">multiple</span>;
attribute DOMString <span title="dom-fe-name">name</span>;
Expand Down Expand Up @@ -37568,7 +37567,7 @@ interface <dfn>HTMLSelectElement</dfn> : <span>HTMLElement</span> {
readonly attribute <span>HTMLFormElement</span> <span title="dom-fae-form">form</span>;
attribute boolean <span title="dom-select-multiple">multiple</span>;
attribute DOMString <span title="dom-fe-name">name</span>;
attribute long <span title="dom-select-size">size</span>;
attribute unsigned long <span title="dom-select-size">size</span>;

readonly attribute DOMString <span title="dom-select-type">type</span>;

Expand Down Expand Up @@ -38362,7 +38361,7 @@ interface <dfn>HTMLOptionElement</dfn> : <span>HTMLElement</span> {
attribute unsigned long <span title="dom-textarea-cols">cols</span>;
attribute boolean <span title="dom-fe-disabled">disabled</span>;
readonly attribute <span>HTMLFormElement</span> <span title="dom-fae-form">form</span>;
attribute long <span title="dom-textarea-maxLength">maxLength</span>;
attribute unsigned long <span title="dom-textarea-maxLength">maxLength</span>;
attribute DOMString <span title="dom-fe-name">name</span>;
attribute DOMString <span title="dom-textarea-placeholder">placeholder</span>;
attribute boolean <span title="dom-textarea-readOnly">readOnly</span>;
Expand Down Expand Up @@ -82880,10 +82879,10 @@ time:empty { binding: <i title="">time</i>; }</pre>
attribute DOMString <span title="dom-applet-code">code</span>;
attribute DOMString <span title="dom-applet-codeBase">codeBase</span>;
attribute DOMString <span title="dom-applet-height">height</span>;
attribute long <span title="dom-applet-hspace">hspace</span>;
attribute unsigned long <span title="dom-applet-hspace">hspace</span>;
attribute DOMString <span title="dom-applet-name">name</span>;
attribute DOMString <span title="dom-applet-object">object</span>;
attribute long <span title="dom-applet-vspace">vspace</span>;
attribute unsigned long <span title="dom-applet-vspace">vspace</span>;
attribute DOMString <span title="dom-applet-width">width</span>;
};</pre>

Expand Down Expand Up @@ -83655,9 +83654,9 @@ time:empty { binding: <i title="">time</i>; }</pre>
attribute DOMString <span title="dom-img-name">name</span>;
attribute DOMString <span title="dom-img-align">align</span>;
attribute DOMString <span title="dom-img-border">border</span>;
attribute long <span title="dom-img-hspace">hspace</span>;
attribute unsigned long <span title="dom-img-hspace">hspace</span>;
attribute DOMString <span title="dom-img-longDesc">longDesc</span>;
attribute long <span title="dom-img-vspace">vspace</span>;
attribute unsigned <span title="dom-img-vspace">vspace</span>;
};</pre>

<p>The <dfn title="dom-img-name"><code>name</code></dfn>, <dfn
Expand Down Expand Up @@ -83753,9 +83752,9 @@ time:empty { binding: <i title="">time</i>; }</pre>
attribute DOMString <span title="dom-object-codeBase">codeBase</span>;
attribute DOMString <span title="dom-object-codeType">codeType</span>;
attribute boolean <span title="dom-object-declare">declare</span>;
attribute long <span title="dom-object-hspace">hspace</span>;
attribute unsigned long <span title="dom-object-hspace">hspace</span>;
attribute DOMString <span title="dom-object-standby">standby</span>;
attribute long <span title="dom-object-vspace">vspace</span>;
attribute unsigned long <span title="dom-object-vspace">vspace</span>;
};</pre>

<p>The <dfn title="dom-object-align"><code>align</code></dfn>, <dfn
Expand Down Expand Up @@ -83820,7 +83819,7 @@ time:empty { binding: <i title="">time</i>; }</pre>
<hr>

<pre class="idl">[Supplemental] interface <span>HTMLPreElement</span> {
attribute long <span title="dom-pre-width">width</span>;
attribute unsigned long <span title="dom-pre-width">width</span>;
};</pre>

<p>The <dfn title="dom-pre-width"><code>width</code></dfn> DOM
Expand Down

0 comments on commit 698f823

Please sign in to comment.