HTML Standard Tracker

Filter

File a bug

SVNBugCommentTime (UTC)
2276<input type=image>2008-10-03 23:26
@@ -28046,20 +28046,23 @@ function AddCloud(data, x, y) { ... }</pre>
   <code class="no-backref" title="attr-input-maxlength">maxlength</code>,
   <code class="no-backref" title="attr-fs-method">method</code>,
   <code class="no-backref" title="attr-input-min">min</code>,
   <code class="no-backref" title="attr-input-pattern">pattern</code>,
   <code class="no-backref" title="attr-input-readonly">readonly</code>,
   <code class="no-backref" title="attr-input-size">size</code>,
   <code class="no-backref" title="attr-input-src">src</code>,
   <code class="no-backref" title="attr-input-step">step</code>, and
   <code class="no-backref" title="attr-fs-target">target</code>.</p>
 
+  <p>The element's <code title="attr-input-value">value</code>
+  attribute must be omitted.</p>
+
   <p>The following DOM attributes and methods do not apply to the element:
   <code class="no-backref" title="dom-input-checked">checked</code>,
   <code class="no-backref" title="dom-input-list">list</code>,
   <code class="no-backref" title="dom-input-selectedOption">selectedOption</code>,
   <code class="no-backref" title="dom-input-value">value</code>,
   <code class="no-backref" title="dom-input-valueAsDate">valueAsDate</code> and
   <code class="no-backref" title="dom-input-valueAsNumber">valueAsNumber</code> DOM attributes;
   <code class="no-backref" title="dom-input-stepDown">stepDown()</code> and
   <code class="no-backref" title="dom-input-stepUp">stepUp()</code> methods.</p>
 
@@ -28128,30 +28131,198 @@ function AddCloud(data, x, y) { ... }</pre>
 
 
 
   <h6><dfn title="attr-input-type-image">Image Button</dfn> state</h6>
 
   <p>When an <code>input</code> element's <code
   title="attr-input-type">type</code> attribute is in the <span
   title="attr-input-type-image">Image Button</span> state, the rules
   in this section apply.</p>
 
-  <p>The element's <code title="attr-input-value">value</code>
-  attribute must be omitted.</p>
+  <p>The <code>input</code> element represents either an image from
+  which a user can select a coordinate and submit the form, or
+  alternatively a button from which the user can submit the form.</p>
 
-  <p class="XXX">...</p>
+  <hr>
+
+  <p>The image is given by the <dfn
+  title="attr-input-src"><code>src</code></dfn> attribute. The <code
+  title="attr-input-src">src</code> attribute must be present, and
+  must contain a <span>valid URL</span> referencing a non-interactive,
+  optionally animated, image resource that is neither paged nor
+  scripted.</p>
+
+  <p>When any of the following events occur, the user agent must
+  <span>fetch</span> the resource specifed by the <code
+  title="attr-input-src">src</code> attribute's value, unless the user
+  agent cannot support images, or its support for images has been
+  disabled, or the user agent only fetches elements on demand:</p>
+  <!-- Note how this does NOT happen when the base URL changes. -->
+
+  <ul>
+
+   <li>The <code>input</code> element's <code
+   title="attr-input-type">type</code> attribute is first set to the
+   <span title="attr-input-type-image">Image Button</span> state
+   (possibly when the element is first created), and the <code
+   title="attr-input-src">src</code> attribute is present.</li>
+
+   <li>The <code>input</code> element's <code
+   title="attr-input-type">type</code> attribute is changed back to
+   the <span title="attr-input-type-image">Image Button</span> state,
+   and the <code title="attr-input-src">src</code> attribute is
+   present, and its value has changed since the last time the <code
+   title="attr-input-type">type</code> attribute was in the <span
+   title="attr-input-type-image">Image Button</span> state.</li>
+
+   <li>The <code>input</code> element's <code
+   title="attr-input-type">type</code> attribute is in the <span
+   title="attr-input-type-image">Image Button</span> state, and the
+   <code title="attr-input-src">src</code> attribute is set or
+   changed.</li> <!-- XXX define changed -->
+
+  </ul>
+
+  <p>Fetching the image must <span>delay the <code
+  title="event-load">load</code> event</span>.</p>
+
+  <p>If the image was successfully obtained, with no network errors,
+  and the image's type is a supported image type, and the image is a
+  valid image of that type, then the image is said to be
+  <i>available</i>. If this is true before the image is completely
+  downloaded, each <span title="concept-task">task</span> that is
+  <span title="queue a task">queued</span> by the <span>networking
+  task source</span> while the image is being <span
+  title="fetch">fetched</span> must update the presentation of the
+  image appropriately.</p>
+
+  <p>The user agents should apply the <span title="Content-Type
+  sniffing: image">image sniffing rules</span> to determine the type
+  of the image, with the image's <span title="Content-Type">associated
+  Content-Type headers</span> giving the <var title="">official
+  type</var>. If these rules are not applied, then the type of the
+  image must be the type given by the image's <span
+  title="Content-Type">associated Content-Type headers</span>.</p>
+
+  <p>User agents must not support non-image resources with the
+  <code>input</code> element. User agents must not run executable code
+  embedded in the image resource. User agents must only display the
+  first page of a multipage resource. User agents must not allow the
+  resource to act in an interactive fashion, but should honour any
+  animation in the resource.</p>
+
+  <p>The <span title="concept-task">task</span> that is <span
+  title="queue a task">queued</span> by the <span>networking task
+  source</span> once the resource has been <span
+  title="fetch">fetched</span>, must, if the download was successful
+  and the image is <i>available</i>, <span>queue a task</span> to
+  <span>fire a <code title="event-load">load</code> event</span> on
+  the <code>input</code> element; and otherwise, if the fetching
+  process fails without a response from the remote server, or
+  completes but the image is not a valid or supported image,
+  <span>queue a task</span> to <span>fire an <code
+  title="event-error">error</code> event</span> on the
+  <code>input</code> element.</p>
+
+  <hr>
+
+  <p>The <dfn title="attr-input-alt"><code>alt</code></dfn> attribute
+  provides the textual label for the alternative button for users and
+  user agents who cannot use the image. The <code
+  title="attr-input-alt">alt</code> attribute must also be present,
+  and must contain a non-empty string.</p>
+
+  <hr>
+
+  <p>If the <code title="attr-input-src">src</code> attribute is set,
+  and the image is <i>available</i> and the user agent is configured
+  to display that image, then: The element represents a control for
+  selecting a <span
+  title="concept-input-type-image-coordinate">coordinate</span> from
+  the image specified by the <code title="attr-input-src">src</code>
+  attribute; if the element is <i
+  title="concept-input-mutable">mutable</i>, the user should allow the
+  user to select this <span
+  title="concept-input-type-image-coordinate">coordinate</span>, at
+  which point the element's <span>form owner</span>, if any, must be
+  <span title="concept-form-submit">submitted</span> from the
+  <code>input</code> element.</p>
+
+  <p>Otherwise, the element represents a submit button whose label is
+  given by the value of the <code title="attr-input-alt">alt</code>
+  attribute; if the element is <i
+  title="concept-input-mutable">mutable</i>, the user should allow the
+  user to activate the button, at which point the the <span
+  title="concept-input-type-image-coordinate">selected
+  coordinate</span> must be set to (0,0) and the element's <span>form
+  owner</span>, if any, must be <span
+  title="concept-form-submit">submitted</span> from the
+  <code>input</code> element.</p>
+
+  <!-- XXX event timing; activation behavior -->
+
+  <p>The <dfn
+  title="concept-input-type-image-coordinate">selected
+  coordinate</dfn> must consist of an <var title="">x</var>-component
+  and a <var title="">y</var>-component. The <var
+  title="">x</var>-component must be greater than or equal to zero,
+  and less than or equal to the rendered width, in CSS pixels, of the
+  image. The <var title="">y</var>-component must be greater than or
+  equal to zero, and less than or equal to the rendered height, in CSS
+  pixels, of the image.</p>
+
+  <hr>
+
+  <p>The following common <code>input</code> element content
+  attributes and DOM attributes apply to the element:
+  <code title="attr-fs-action">action</code>,
+  <code title="attr-input-alt">alt</code>,
+  <code title="attr-fs-enctype">enctype</code>,
+  <code title="attr-fs-method">method</code>, 
+  <code title="attr-input-src">src</code>, and
+  <code title="attr-fs-target">target</code> content attributes;
+  <code title="dom-input-value">value</code> DOM attribute.</p>
+
+  <p>The <code title="dom-input-value">value</code> DOM attribute is
+  in mode <span title="dom-input-value-default">default</span>.</p>
+
+  <p>The following content attributes must not be specified and do not
+  apply to the element:
+  <code class="no-backref" title="attr-input-accept">accept</code>,
+  <code class="no-backref" title="attr-input-autocomplete">autocomplete</code>,
+  <code class="no-backref" title="attr-input-checked">checked</code>,
+  <code class="no-backref" title="attr-input-list">list</code>,
+  <code class="no-backref" title="attr-input-max">max</code>,
+  <code class="no-backref" title="attr-input-maxlength">maxlength</code>,
+  <code class="no-backref" title="attr-input-min">min</code>,
+  <code class="no-backref" title="attr-input-pattern">pattern</code>,
+  <code class="no-backref" title="attr-input-readonly">readonly</code>,
+  <code class="no-backref" title="attr-input-required">required</code>
+  <code class="no-backref" title="attr-input-size">size</code>, and
+  <code class="no-backref" title="attr-input-step">step</code>.</p>
 
-  <p class="XXX">... <dfn title="attr-input-alt"><code>alt</code></dfn></p>
+  <p>The element's <code title="attr-input-value">value</code>
+  attribute must be omitted.</p>
 
-  <p class="XXX">... <dfn title="attr-input-src"><code>src</code></dfn></p>
+  <p>The following DOM attributes and methods do not apply to the element:
+  <code class="no-backref" title="dom-input-checked">checked</code>,
+  <code class="no-backref" title="dom-input-list">list</code>,
+  <code class="no-backref" title="dom-input-selectedOption">selectedOption</code>,
+  <code class="no-backref" title="dom-input-valueAsDate">valueAsDate</code> and
+  <code class="no-backref" title="dom-input-valueAsNumber">valueAsNumber</code> DOM attributes;
+  <code class="no-backref" title="dom-input-stepDown">stepDown()</code> and
+  <code class="no-backref" title="dom-input-stepUp">stepUp()</code> methods.</p>
 
-  <p class="XXX">... image: <dfn title="concept-input-type-image-coordinate">selected coordinate</dfn></p>
+  <p class="note">Many aspects of this state's behavior are similar to
+  the behavior of the <code>img</code> element. Readers are encouraged
+  to read that section, where many of the same requirements are
+  described in more detail.</p>
 
 
 
   <h6><dfn title="attr-input-type-reset">Reset Button</dfn> state</h6>
 
   <p>When an <code>input</code> element's <code
   title="attr-input-type">type</code> attribute is in the <span
   title="attr-input-type-reset">Reset Button</span> state, the rules
   in this section apply.</p>
 
@@ -29687,24 +29858,25 @@ interface <dfn>HTMLOptionElement</dfn> : <span>HTMLElement</span> {
 
        <li><p>Let <var title="">name<sub title="">y</sub></var> be the
        string consisting of the concatenation of <var
        title="">name</var> and a single U+0079 LATIN SMALL LETTER Y
        (y) character.</p></li>
 
        <li><p>The <var title="">field</var> element is <var
        title="">submitter</var>, and before this algorithm was invoked
        the user <span
        title="concept-input-type-image-coordinate">indicated a
-       coordinate</span>. Let <var title="">x</var> be the x-component
-       of the coordindate selected by the user, and let <var
-       title="">y</var> be the y-component of the coordinate selected
-       by the user.</p></li>
+       coordinate</span>. Let <var title="">x</var> be the <var
+       title="">x</var>-component of the coordindate selected by the
+       user, and let <var title="">y</var> be the <var
+       title="">y</var>-component of the coordinate selected by the
+       user.</p></li>
 
        <li><p>Append an entry in the <var title="">form data set</var>
        with the name <var title="">name<sub title="">x</sub></var> and
        the value <var title="">x</var>.</p></li>
 
        <li><p>Append an entry in the <var title="">form data set</var>
        with the name <var title="">name<sub title="">y</sub></var> and
        the value <var title="">y</var>.</p></li>
 
        <li><p>Skip the remaining substeps for this element: if there

|