W3C home > Mailing lists > Public > public-html-commits@w3.org > August 2010

html5/spec Overview.html,1.4206,1.4207

From: Ian Hickson via cvs-syncmail <cvsmail@w3.org>
Date: Wed, 11 Aug 2010 20:26:41 +0000
To: public-html-commits@w3.org
Message-Id: <E1OjHsn-0007k0-N2@lionel-hutz.w3.org>
Update of /sources/public/html5/spec
In directory hutz:/tmp/cvs-serv29731

Modified Files:
	Overview.html 
Log Message:
allow context arguemtns on getContext (whatwg r5281)

Index: Overview.html
===================================================================
RCS file: /sources/public/html5/spec/Overview.html,v
retrieving revision 1.4206
retrieving revision 1.4207
diff -u -d -r1.4206 -r1.4207
--- Overview.html	11 Aug 2010 03:49:57 -0000	1.4206
+++ Overview.html	11 Aug 2010 20:26:37 -0000	1.4207
@@ -22881,7 +22881,7 @@
 
   DOMString <a href="#dom-canvas-todataurl" title="dom-canvas-toDataURL">toDataURL</a>(in optional DOMString type, in any... args);
 
-  object <a href="#dom-canvas-getcontext" title="dom-canvas-getContext">getContext</a>(in DOMString contextId);
+  object <a href="#dom-canvas-getcontext" title="dom-canvas-getContext">getContext</a>(in DOMString contextId, in any... args);
 };</pre>
    </dd>
   </dl><p>The <code><a href="#the-canvas-element">canvas</a></code> element provides scripts with a
@@ -22964,12 +22964,13 @@
   context.fillRect(0,100,50,50);
   canvas.width = canvas.width; // clears the canvas
   context.fillRect(100,0,50,50); // only this square remains</pre>
-  </div><hr><dl class="domintro"><dt><var title="">context</var> = <var title="">canvas</var> . <code title="dom-canvas-getContext"><a href="#dom-canvas-getcontext">getContext</a></code>(<var title="">contextId</var>)</dt>
+  </div><hr><dl class="domintro"><dt><var title="">context</var> = <var title="">canvas</var> . <code title="dom-canvas-getContext"><a href="#dom-canvas-getcontext">getContext</a></code>(<var title="">contextId</var> [, ... ])</dt>
 
    <dd>
 
     <p>Returns an object that exposes an API for drawing on the
-    canvas. The argument specifies the desired API.</p>
+    canvas. The first argument specifies the desired API. Subsequent
+    arguments are handled by that API.</p>
 
 
     <p>The list of defined contexts is given on the <a href="http://wiki.whatwg.org/wiki/CanvasContexts">WHATWG Wiki
@@ -22989,12 +22990,12 @@
   that element. When created, a <code><a href="#the-canvas-element">canvas</a></code> element must not
   have a <a href="#primary-context">primary context</a>.</p>
 
-  <p>The <dfn id="dom-canvas-getcontext" title="dom-canvas-getContext"><code>getContext(<var title="">contextId</var>)</code></dfn> method of the
-  <code><a href="#the-canvas-element">canvas</a></code> element, when invoked, must run the following
-  steps:</p>
+  <p>The <dfn id="dom-canvas-getcontext" title="dom-canvas-getContext"><code>getContext(<var title="">contextId</var>, <var title="">args...</var>)</code></dfn>
+  method of the <code><a href="#the-canvas-element">canvas</a></code> element, when invoked, must run
+  the following steps:</p>
 
-  <ol><li><p>Let <var title="">contextId</var> be the argument to the
-   method.</li>
+  <ol><li><p>Let <var title="">contextId</var> be the first argument to
+   the method.</li>
 
    <li><p>If <var title="">contextId</var> is not the name of a
    context supported by the user agent, return null and abort these
@@ -23011,7 +23012,8 @@
 
    <li><p>If the <code title="dom-canvas-getContext"><a href="#dom-canvas-getcontext">getContext()</a></code> method has
    already been invoked on this element for the same <var title="">contextId</var>, return the same object as was returned
-   that time, and abort these steps.</li>
+   that time, and abort these steps. The additional arguments are
+   ignored.</li>
 
    <li><p><dfn id="getcontext-return" title="getContext-return">Return a new object for <var title="">contextId</var></dfn>, as defined by the specification
    given for <var title="">contextId</var>'s entry in the <a href="http://wiki.whatwg.org/wiki/CanvasContexts">WHATWG Wiki
Received on Wednesday, 11 August 2010 20:26:43 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:10:01 UTC