| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. | 2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 HTMLVideoElement or | 29 HTMLVideoElement or |
| 30 HTMLCanvasElement or | 30 HTMLCanvasElement or |
| 31 // CanvasRenderingContext2D or | 31 // CanvasRenderingContext2D or |
| 32 ImageBitmap) CanvasImageSource; | 32 ImageBitmap) CanvasImageSource; |
| 33 | 33 |
| 34 enum CanvasFillRule { "nonzero", "evenodd" }; | 34 enum CanvasFillRule { "nonzero", "evenodd" }; |
| 35 enum ImageSmoothingQuality {"low", "medium", "high"}; | 35 enum ImageSmoothingQuality {"low", "medium", "high"}; |
| 36 | 36 |
| 37 [ | 37 [ |
| 38 SetWrapperReferenceFrom=canvas, | 38 SetWrapperReferenceFrom=canvas, |
| 39 WillBeGarbageCollected, | 39 GarbageCollected, |
| 40 ] interface CanvasRenderingContext2D { | 40 ] interface CanvasRenderingContext2D { |
| 41 // back-reference to the canvas | 41 // back-reference to the canvas |
| 42 readonly attribute HTMLCanvasElement canvas; | 42 readonly attribute HTMLCanvasElement canvas; |
| 43 | 43 |
| 44 // state | 44 // state |
| 45 void save(); // push state on state stack | 45 void save(); // push state on state stack |
| 46 void restore(); // pop state stack and restore state | 46 void restore(); // pop state stack and restore state |
| 47 | 47 |
| 48 // transformations (default transform is the identity matrix) | 48 // transformations (default transform is the identity matrix) |
| 49 [RuntimeEnabled=ExperimentalCanvasFeatures] attribute SVGMatrix currentTrans
form; | 49 [RuntimeEnabled=ExperimentalCanvasFeatures] attribute SVGMatrix currentTrans
form; |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 | 142 |
| 143 // text | 143 // text |
| 144 attribute DOMString font; // (default 10px sans-serif) | 144 attribute DOMString font; // (default 10px sans-serif) |
| 145 attribute DOMString textAlign; // "start", "end", "left", "right", "center"
(default: "start") | 145 attribute DOMString textAlign; // "start", "end", "left", "right", "center"
(default: "start") |
| 146 attribute DOMString textBaseline; // "top", "hanging", "middle", "alphabetic
", "ideographic", "bottom" (default: "alphabetic") | 146 attribute DOMString textBaseline; // "top", "hanging", "middle", "alphabetic
", "ideographic", "bottom" (default: "alphabetic") |
| 147 [RuntimeEnabled=ExperimentalCanvasFeatures] attribute DOMString direction; /
/ "inherit", "rtl", "ltr" (default: "inherit") | 147 [RuntimeEnabled=ExperimentalCanvasFeatures] attribute DOMString direction; /
/ "inherit", "rtl", "ltr" (default: "inherit") |
| 148 | 148 |
| 149 }; | 149 }; |
| 150 | 150 |
| 151 CanvasRenderingContext2D implements CanvasPathMethods; | 151 CanvasRenderingContext2D implements CanvasPathMethods; |
| OLD | NEW |