OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // https://drafts.css-houdini.org/css-paint-api/#paintrenderingcontext2d | 5 // https://drafts.css-houdini.org/css-paint-api/#paintrenderingcontext2d |
6 | 6 |
7 [ | 7 [ |
8 Exposed=PaintWorklet, | 8 Exposed=PaintWorklet, |
9 GarbageCollected, | |
10 RuntimeEnabled=CSSPaintAPI, | 9 RuntimeEnabled=CSSPaintAPI, |
11 ] interface PaintRenderingContext2D { | 10 ] interface PaintRenderingContext2D { |
12 // state | 11 // state |
13 void save(); // push state on state stack | 12 void save(); // push state on state stack |
14 void restore(); // pop state stack and restore state | 13 void restore(); // pop state stack and restore state |
15 | 14 |
16 // transformations (default transform is the identity matrix) | 15 // transformations (default transform is the identity matrix) |
17 [RuntimeEnabled=ExperimentalCanvasFeatures] attribute SVGMatrix currentTrans
form; | 16 [RuntimeEnabled=ExperimentalCanvasFeatures] attribute SVGMatrix currentTrans
form; |
18 void scale(unrestricted double x, unrestricted double y); | 17 void scale(unrestricted double x, unrestricted double y); |
19 void rotate(unrestricted double angle); | 18 void rotate(unrestricted double angle); |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 attribute DOMString lineCap; // "butt", "round", "square" (default "butt") | 72 attribute DOMString lineCap; // "butt", "round", "square" (default "butt") |
74 attribute DOMString lineJoin; // "round", "bevel", "miter" (default "miter") | 73 attribute DOMString lineJoin; // "round", "bevel", "miter" (default "miter") |
75 attribute unrestricted double miterLimit; // (default 10) | 74 attribute unrestricted double miterLimit; // (default 10) |
76 | 75 |
77 // dashed lines | 76 // dashed lines |
78 void setLineDash(sequence<unrestricted double> dash); | 77 void setLineDash(sequence<unrestricted double> dash); |
79 sequence<unrestricted double> getLineDash(); | 78 sequence<unrestricted double> getLineDash(); |
80 attribute unrestricted double lineDashOffset; | 79 attribute unrestricted double lineDashOffset; |
81 }; | 80 }; |
82 PaintRenderingContext2D implements CanvasPathMethods; | 81 PaintRenderingContext2D implements CanvasPathMethods; |
OLD | NEW |