You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The <dfn dfn-type=constructor dfn-for=DOMMatrixReadOnly><code>DOMMatrixReadOnly(<var>numberSequence</var>)</code></dfn> constructor, when invoked, must run the following steps:
642
-
643
-
<dl class=switch>
644
-
<dt>If <var>numberSequence</var> has 6 elements</dt>
645
-
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrixReadOnly}} with the sequence <var>numberSequence</var>.</dd>
646
-
<dt>If <var>numberSequence</var> has 16 elements</dt>
647
-
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrixReadOnly}} with the sequence <var>numberSequence</var>.</dd>
648
-
<dt>Otherwise</dt>
649
-
<dd>Throw a <code>TypeError</code> exception.</dd>
The <dfn dfn-type=constructor dfn-for=DOMMatrix><code>DOMMatrix(<var>numberSequence</var>)</code></dfn> constructor, when invoked, must run the following steps:
644
+
The <dfn dfn-type=constructor dfn-for=DOMMatrixReadOnly><code>DOMMatrixReadOnly(<var>numberSequence</var>)</code></dfn> and
645
+
the <dfn dfn-type=constructor dfn-for=DOMMatrix><code>DOMMatrix(<var>numberSequence</var>)</code></dfn> constructors, when invoked, must run the following steps:
656
646
657
647
<dl class=switch>
658
648
<dt>If <var>numberSequence</var> has 6 elements</dt>
659
-
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrix}} with the sequence <var>numberSequence</var>.</dd>
649
+
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with the sequence <var>numberSequence</var>.</dd>
660
650
<dt>If <var>numberSequence</var> has 16 elements</dt>
661
-
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrix}} with the sequence <var>numberSequence</var>.</dd>
651
+
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with the sequence <var>numberSequence</var>.</dd>
662
652
<dt>Otherwise</dt>
663
653
<dd>Throw a <code>TypeError</code> exception.</dd>
664
654
</dl>
665
655
666
-
The <dfn dfn-for=DOMMatrix id=dom-dommatrix-frommatrix><code>fromMatrix(<var>other</var>)</code></dfn> static method on {{DOMMatrix}} must follow these steps:
656
+
The <dfn dfn-for=DOMMatrixReadOnly id=dom-dommatrixreadonly-frommatrix><code>fromMatrix(<var>other</var>)</code></dfn> static method on {{DOMMatrixReadOnly}} and
657
+
the <dfn dfn-for=DOMMatrix id=dom-dommatrix-frommatrix><code>fromMatrix(<var>other</var>)</code></dfn> static method on {{DOMMatrix}} must follow these steps:
667
658
668
659
<ol>
669
660
<li><a>Validate and fixup</a><var>other</var>.</li>
670
661
671
662
<li>
672
663
<dl class=switch>
673
664
<dt>If the {{DOMMatrixInit/is2D}} dictionary member of <var>other</var> is <code>true</code></dt>
674
-
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrix}} with a sequence of numbers, the values being the 6 elements {{DOMMatrixInit/m11}}, {{DOMMatrixInit/m12}}, {{DOMMatrixInit/m21}}, {{DOMMatrixInit/m22}}, {{DOMMatrixInit/m41}} and {{DOMMatrixInit/m42}} of <var>other</var> in the given order.</dd>
665
+
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with a sequence of numbers, the values being the 6 elements {{DOMMatrixInit/m11}}, {{DOMMatrixInit/m12}}, {{DOMMatrixInit/m21}}, {{DOMMatrixInit/m22}}, {{DOMMatrixInit/m41}} and {{DOMMatrixInit/m42}} of <var>other</var> in the given order.</dd>
675
666
<dt>Otherwise</dt>
676
-
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrix}} with a sequence of numbers, the values being the 16 elements {{DOMMatrixInit/m11}}, {{DOMMatrixInit/m12}}, {{DOMMatrixInit/m13}}, ..., {{DOMMatrixInit/m44}} of <var>other</var> in the given order.</dd>
667
+
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with a sequence of numbers, the values being the 16 elements {{DOMMatrixInit/m11}}, {{DOMMatrixInit/m12}}, {{DOMMatrixInit/m13}}, ..., {{DOMMatrixInit/m44}} of <var>other</var> in the given order.</dd>
677
668
</dl>
678
669
</li>
679
670
</ol>
680
671
681
-
The <dfn dfn-for=DOMMatrix><code>fromString(<var>transformList</var>)</code></dfn> static method on {{DOMMatrix}} must follow these steps:
672
+
The <dfn dfn-for=DOMMatrixReadOnly><code>fromString(<var>transformList</var>)</code></dfn> static method on {{DOMMatrixReadOnly}} and
673
+
the <dfn dfn-for=DOMMatrix><code>fromString(<var>transformList</var>)</code></dfn> static method on {{DOMMatrix}} must follow these steps:
682
674
683
675
<ol>
684
676
<li>Parse <var>transformList</var> by following the syntax description in “<a href=http://www.w3.org/TR/css-transforms-1/#svg-syntax>Syntax of the SVG ‘transform’ attribute</a>” [[!CSS3-TRANSFORMS]] to a <<transform-list>>. If parsing is not successful or any <<transform-function>> has <<length>> values without <a spec='css-values'>absolute length</a> units<!--For WD: <a spec='css-values-3'>absolute length units</a>-->, throw a {{SyntaxError}} exception.</li>
@@ -695,31 +687,33 @@ The <dfn dfn-for=DOMMatrix><code>fromString(<var>transformList</var>)</code></df
695
687
<li>
696
688
<dl class=switch>
697
689
<dt>If <var>2dTransform</var> is set to <code>true</code></dt>
698
-
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrix}} with a sequence of numbers, the values being the elements <var>m11</var>, <var>m12</var>, <var>21</var>, <var>m22</var>, <var>m41</var> and <var>m42</var> of <var>matrix</var> of <var>matrix</var>.</dd>
690
+
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with a sequence of numbers, the values being the elements <var>m11</var>, <var>m12</var>, <var>21</var>, <var>m22</var>, <var>m41</var> and <var>m42</var> of <var>matrix</var> of <var>matrix</var>.</dd>
699
691
<dt>If <var>2dTransform</var> is set to <code>false</code></dt>
700
-
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrix}} with a sequence of numbers, the values being the 16 elements of <var>matrix</var>.</dd>
692
+
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with a sequence of numbers, the values being the 16 elements of <var>matrix</var>.</dd>
701
693
</dl>
702
694
</li>
703
695
</ol>
704
696
705
-
The <dfn dfn-for=DOMMatrix><code>fromFloat32Array(<var>array32</var>)</code></dfn> static method on {{DOMMatrix}} must follow these steps:
697
+
The <dfn dfn-for=DOMMatrixReadOnly><code>fromFloat32Array(<var>array32</var>)</code></dfn> static method on {{DOMMatrixReadOnly}} and
698
+
the <dfn dfn-for=DOMMatrix><code>fromFloat32Array(<var>array32</var>)</code></dfn> static method on {{DOMMatrix}} must follow these steps:
706
699
707
700
<dl class=switch>
708
701
<dt>If <var>array32</var> has 6 elements</dt>
709
-
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrix}} with a sequence of numbers taking the values from <var>array32</var> in the provided order.</dd>
702
+
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with a sequence of numbers taking the values from <var>array32</var> in the provided order.</dd>
710
703
<dt>If <var>array32</var> has 16 elements</dt>
711
-
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrix}} with a sequence of numbers taking the values from <var>array32</var> in the provided order.</dd>
704
+
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with a sequence of numbers taking the values from <var>array32</var> in the provided order.</dd>
712
705
<dt>Otherwise</dt>
713
706
<dd>Throw a <code>TypeError</code> exception.</dd>
714
707
</dl>
715
708
716
-
The <dfn dfn-for=DOMMatrix><code>fromFloat64Array(<var>array64</var>)</code></dfn> static method on {{DOMMatrix}} must follow these steps:
709
+
The <dfn dfn-for=DOMMatrixReadOnly><code>fromFloat64Array(<var>array64</var>)</code></dfn> static method on {{DOMMatrixReadOnly}} and
710
+
the <dfn dfn-for=DOMMatrix><code>fromFloat64Array(<var>array64</var>)</code></dfn> static method on {{DOMMatrix}} must follow these steps:
717
711
718
712
<dl class=switch>
719
713
<dt>If <var>array64</var> has 6 elements</dt>
720
-
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrix}} with a sequence of numbers taking the values from <var>array64</var> in the provided order.</dd>
714
+
<dd>Return the result of invoking <a>create a 2d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with a sequence of numbers taking the values from <var>array64</var> in the provided order.</dd>
721
715
<dt>If <var>array32</var> has 16 elements</dt>
722
-
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrix}} with a sequence of numbers taking the values from <var>array64</var> in the provided order.</dd>
716
+
<dd>Return the result of invoking <a>create a 3d matrix</a> of type {{DOMMatrixReadOnly}} or {{DOMMatrix}} as appropriate, with a sequence of numbers taking the values from <var>array64</var> in the provided order.</dd>
723
717
<dt>Otherwise</dt>
724
718
<dd>Throw a <code>TypeError</code> exception.</dd>
0 commit comments