| 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 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 127 [RaisesException] ImageData createImageData(ImageData imagedata); | 127 [RaisesException] ImageData createImageData(ImageData imagedata); |
| 128 [RaisesException] ImageData createImageData(long sw, long sh); | 128 [RaisesException] ImageData createImageData(long sw, long sh); |
| 129 [RaisesException] ImageData getImageData(long sx, long sy, long sw, long sh)
; | 129 [RaisesException] ImageData getImageData(long sx, long sy, long sw, long sh)
; |
| 130 [RaisesException] void putImageData(ImageData imagedata, long dx, long dy); | 130 [RaisesException] void putImageData(ImageData imagedata, long dx, long dy); |
| 131 [RaisesException] void putImageData(ImageData imagedata, long dx, long dy, l
ong dirtyX, long dirtyY, long dirtyWidth, long dirtyHeight); | 131 [RaisesException] void putImageData(ImageData imagedata, long dx, long dy, l
ong dirtyX, long dirtyY, long dirtyWidth, long dirtyHeight); |
| 132 | 132 |
| 133 // Context state | 133 // Context state |
| 134 // Should be merged with WebGL counterpart in CanvasRenderingContext, once n
o-longer experimental | 134 // Should be merged with WebGL counterpart in CanvasRenderingContext, once n
o-longer experimental |
| 135 [RuntimeEnabled=ExperimentalCanvasFeatures] boolean isContextLost(); | 135 [RuntimeEnabled=ExperimentalCanvasFeatures] boolean isContextLost(); |
| 136 | 136 |
| 137 [MeasureAs=GetCanvas2DContextAttributes] CanvasRenderingContext2DSettings ge
tContextAttributes(); | 137 [RuntimeEnabled=ExperimentalCanvasFeatures, MeasureAs=GetCanvas2DContextAttr
ibutes] CanvasRenderingContext2DSettings getContextAttributes(); |
| 138 | 138 |
| 139 // FIXME: factor out to CanvasDrawingStyles | 139 // FIXME: factor out to CanvasDrawingStyles |
| 140 // line caps/joins | 140 // line caps/joins |
| 141 attribute unrestricted double lineWidth; // (default 1) | 141 attribute unrestricted double lineWidth; // (default 1) |
| 142 attribute DOMString lineCap; // "butt", "round", "square" (default "butt") | 142 attribute DOMString lineCap; // "butt", "round", "square" (default "butt") |
| 143 attribute DOMString lineJoin; // "round", "bevel", "miter" (default "miter") | 143 attribute DOMString lineJoin; // "round", "bevel", "miter" (default "miter") |
| 144 attribute unrestricted double miterLimit; // (default 10) | 144 attribute unrestricted double miterLimit; // (default 10) |
| 145 | 145 |
| 146 // dashed lines | 146 // dashed lines |
| 147 void setLineDash(sequence<unrestricted double> dash); | 147 void setLineDash(sequence<unrestricted double> dash); |
| 148 sequence<unrestricted double> getLineDash(); | 148 sequence<unrestricted double> getLineDash(); |
| 149 attribute unrestricted double lineDashOffset; | 149 attribute unrestricted double lineDashOffset; |
| 150 | 150 |
| 151 // text | 151 // text |
| 152 attribute DOMString font; // (default 10px sans-serif) | 152 attribute DOMString font; // (default 10px sans-serif) |
| 153 attribute DOMString textAlign; // "start", "end", "left", "right", "center"
(default: "start") | 153 attribute DOMString textAlign; // "start", "end", "left", "right", "center"
(default: "start") |
| 154 attribute DOMString textBaseline; // "top", "hanging", "middle", "alphabetic
", "ideographic", "bottom" (default: "alphabetic") | 154 attribute DOMString textBaseline; // "top", "hanging", "middle", "alphabetic
", "ideographic", "bottom" (default: "alphabetic") |
| 155 [RuntimeEnabled=ExperimentalCanvasFeatures] attribute DOMString direction; /
/ "inherit", "rtl", "ltr" (default: "inherit") | 155 [RuntimeEnabled=ExperimentalCanvasFeatures] attribute DOMString direction; /
/ "inherit", "rtl", "ltr" (default: "inherit") |
| 156 | 156 |
| 157 }; | 157 }; |
| 158 | 158 |
| 159 CanvasRenderingContext2D implements CanvasPathMethods; | 159 CanvasRenderingContext2D implements CanvasPathMethods; |
| OLD | NEW |