Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[giow] (0) Provide a convenience method to reset the transform to the…
… identity transform.

Affected topics: Canvas

git-svn-id: http://svn.whatwg.org/webapps@7036 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Mar 27, 2012
1 parent a496b3d commit 507d0b8
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 0 deletions.
12 changes: 12 additions & 0 deletions complete.html
Expand Up @@ -34897,6 +34897,7 @@ <h5 id=2dcontext><span class=secno>4.8.11.1 </span>The 2D context</h5>
void <a href=#dom-context-2d-translate title=dom-context-2d-translate>translate</a>(double x, double y);
void <a href=#dom-context-2d-transform title=dom-context-2d-transform>transform</a>(double a, double b, double c, double d, double e, double f);
void <a href=#dom-context-2d-settransform title=dom-context-2d-setTransform>setTransform</a>(double a, double b, double c, double d, double e, double f);
void <a href=#dom-context-2d-resettransform title=dom-context-2d-resetTransform>resetTransform</a>();
<!--
// v7 we've also received requests (though not many so far) for:
void skew(...); // is this common enough that one can't just use setTransform()?
Expand Down Expand Up @@ -36848,6 +36849,14 @@ <h6 id=transformations><span class=secno>4.8.11.1.7 </span><dfn title=dom-contex

</dd>

<dt><var title="">context</var> . <code title=dom-context-2d-resetTransform><a href=#dom-context-2d-resettransform>resetTransform</a></code>()</dt>

<dd>

<p>Changes the transformation matrix to the identity transform.</p>

</dd>

</dl><div class=impl>

<p>The <dfn id=dom-context-2d-currenttransform title=dom-context-2d-currentTransform><code>currentTransform</code></dfn>,
Expand Down Expand Up @@ -36907,6 +36916,9 @@ <h6 id=transformations><span class=secno>4.8.11.1.7 </span><dfn title=dom-contex
transform to the identity matrix, and then invoke the <code><a href=#dom-context-2d-transform title=dom-context-2d-transform>transform</a>(<var title="">a</var>, <var title="">b</var>, <var title="">c</var>, <var title="">d</var>, <var title="">e</var>,
<var title="">f</var>)</code> method with the same arguments.</p>

<p>The <dfn id=dom-context-2d-resettransform title=dom-context-2d-resetTransform><code>resetTransform()</code></dfn>
method must reset the current transform to the identity matrix.</p>

</div>


Expand Down
12 changes: 12 additions & 0 deletions index
Expand Up @@ -34897,6 +34897,7 @@ dictionary <dfn id=trackeventinit>TrackEventInit</dfn> : <a href=#eventinit>Even
void <a href=#dom-context-2d-translate title=dom-context-2d-translate>translate</a>(double x, double y);
void <a href=#dom-context-2d-transform title=dom-context-2d-transform>transform</a>(double a, double b, double c, double d, double e, double f);
void <a href=#dom-context-2d-settransform title=dom-context-2d-setTransform>setTransform</a>(double a, double b, double c, double d, double e, double f);
void <a href=#dom-context-2d-resettransform title=dom-context-2d-resetTransform>resetTransform</a>();
<!--
// v7 we've also received requests (though not many so far) for:
void skew(...); // is this common enough that one can't just use setTransform()?
Expand Down Expand Up @@ -36848,6 +36849,14 @@ try {

</dd>

<dt><var title="">context</var> . <code title=dom-context-2d-resetTransform><a href=#dom-context-2d-resettransform>resetTransform</a></code>()</dt>

<dd>

<p>Changes the transformation matrix to the identity transform.</p>

</dd>

</dl><div class=impl>

<p>The <dfn id=dom-context-2d-currenttransform title=dom-context-2d-currentTransform><code>currentTransform</code></dfn>,
Expand Down Expand Up @@ -36907,6 +36916,9 @@ try {
transform to the identity matrix, and then invoke the <code><a href=#dom-context-2d-transform title=dom-context-2d-transform>transform</a>(<var title="">a</var>, <var title="">b</var>, <var title="">c</var>, <var title="">d</var>, <var title="">e</var>,
<var title="">f</var>)</code> method with the same arguments.</p>

<p>The <dfn id=dom-context-2d-resettransform title=dom-context-2d-resetTransform><code>resetTransform()</code></dfn>
method must reset the current transform to the identity matrix.</p>

</div>


Expand Down
13 changes: 13 additions & 0 deletions source
Expand Up @@ -40579,6 +40579,7 @@ dictionary <dfn>TrackEventInit</dfn> : <span>EventInit</span> {
void <span title="dom-context-2d-translate">translate</span>(double x, double y);
void <span title="dom-context-2d-transform">transform</span>(double a, double b, double c, double d, double e, double f);
void <span title="dom-context-2d-setTransform">setTransform</span>(double a, double b, double c, double d, double e, double f);
void <span title="dom-context-2d-resetTransform">resetTransform</span>();
<!--
// v7 we've also received requests (though not many so far) for:
void skew(...); // is this common enough that one can't just use setTransform()?
Expand Down Expand Up @@ -42874,6 +42875,14 @@ try {

</dd>

<dt><var title="">context</var> . <code title="dom-context-2d-resetTransform">resetTransform</code>()</dt>

<dd>

<p>Changes the transformation matrix to the identity transform.</p>

</dd>

</dl>

<div class="impl">
Expand Down Expand Up @@ -42969,6 +42978,10 @@ try {
title="">c</var>, <var title="">d</var>, <var title="">e</var>,
<var title="">f</var>)</code> method with the same arguments.</p>

<p>The <dfn
title="dom-context-2d-resetTransform"><code>resetTransform()</code></dfn>
method must reset the current transform to the identity matrix.</p>

</div>


Expand Down

0 comments on commit 507d0b8

Please sign in to comment.