[html5] r8228 - [giow] (3) Clarify how to handle zero-width <img>s in drawImage(), and make zero [...]

whatwg at whatwg.org whatwg at whatwg.org
Wed Oct 16 15:49:21 PDT 2013


Author: ianh
Date: 2013-10-16 15:49:19 -0700 (Wed, 16 Oct 2013)
New Revision: 8228

Modified:
   complete.html
   index
   source
Log:
[giow] (3) Clarify how to handle zero-width <img>s in drawImage(), and make zero-width <canvas>es not throw.
Affected topics: Canvas

Modified: complete.html
===================================================================
--- complete.html	2013-10-16 22:43:22 UTC (rev 8227)
+++ complete.html	2013-10-16 22:49:19 UTC (rev 8228)
@@ -36126,9 +36126,13 @@
    argument is an <code><a href=#htmlvideoelement>HTMLVideoElement</a></code> object whose <code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> attribute is either <code title=dom-media-HAVE_NOTHING><a href=#dom-media-have_nothing>HAVE_NOTHING</a></code> or <code title=dom-media-HAVE_METADATA><a href=#dom-media-have_metadata>HAVE_METADATA</a></code>, then return <i>bad</i> and abort these
    steps.</li>
 
+   <li><p>If the <var title="">image</var> argument is an <code><a href=#htmlimageelement>HTMLImageElement</a></code> object with
+   an intrinsic width or intrinsic height (or both) equal to zero, then return <i>bad</i> and abort
+   these steps.</p> <!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/2567 -->
+
    <li><p>If the <var title="">image</var> argument is an <code><a href=#htmlcanvaselement>HTMLCanvasElement</a></code> object with
-   either a horizontal dimension or a vertical dimension equal to zero, then throw an
-   <code><a href=#invalidstateerror>InvalidStateError</a></code> exception, return <i>aborted</i>, and abort these steps.</p>
+   either a horizontal dimension or a vertical dimension equal to zero, then return <i>bad</i> and
+   abort these steps.</p>
 
    <li><p>Return <i>good</i>.</li>
 

Modified: index
===================================================================
--- index	2013-10-16 22:43:22 UTC (rev 8227)
+++ index	2013-10-16 22:49:19 UTC (rev 8228)
@@ -36126,9 +36126,13 @@
    argument is an <code><a href=#htmlvideoelement>HTMLVideoElement</a></code> object whose <code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> attribute is either <code title=dom-media-HAVE_NOTHING><a href=#dom-media-have_nothing>HAVE_NOTHING</a></code> or <code title=dom-media-HAVE_METADATA><a href=#dom-media-have_metadata>HAVE_METADATA</a></code>, then return <i>bad</i> and abort these
    steps.</li>
 
+   <li><p>If the <var title="">image</var> argument is an <code><a href=#htmlimageelement>HTMLImageElement</a></code> object with
+   an intrinsic width or intrinsic height (or both) equal to zero, then return <i>bad</i> and abort
+   these steps.</p> <!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/2567 -->
+
    <li><p>If the <var title="">image</var> argument is an <code><a href=#htmlcanvaselement>HTMLCanvasElement</a></code> object with
-   either a horizontal dimension or a vertical dimension equal to zero, then throw an
-   <code><a href=#invalidstateerror>InvalidStateError</a></code> exception, return <i>aborted</i>, and abort these steps.</p>
+   either a horizontal dimension or a vertical dimension equal to zero, then return <i>bad</i> and
+   abort these steps.</p>
 
    <li><p>Return <i>good</i>.</li>
 

Modified: source
===================================================================
--- source	2013-10-16 22:43:22 UTC (rev 8227)
+++ source	2013-10-16 22:49:19 UTC (rev 8228)
@@ -39289,9 +39289,13 @@
    title="dom-media-HAVE_METADATA">HAVE_METADATA</code>, then return <i>bad</i> and abort these
    steps.</p></li>
 
+   <li><p>If the <var title="">image</var> argument is an <code>HTMLImageElement</code> object with
+   an intrinsic width or intrinsic height (or both) equal to zero, then return <i>bad</i> and abort
+   these steps.</p> <!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/2567 -->
+
    <li><p>If the <var title="">image</var> argument is an <code>HTMLCanvasElement</code> object with
-   either a horizontal dimension or a vertical dimension equal to zero, then throw an
-   <code>InvalidStateError</code> exception, return <i>aborted</i>, and abort these steps.</p>
+   either a horizontal dimension or a vertical dimension equal to zero, then return <i>bad</i> and
+   abort these steps.</p>
 
    <li><p>Return <i>good</i>.</p></li>
 




More information about the Commit-Watchers mailing list