| 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 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 | 62 |
| 63 void clearRect(float x, float y, float width, float height); | 63 void clearRect(float x, float y, float width, float height); |
| 64 void fillRect(float x, float y, float width, float height); | 64 void fillRect(float x, float y, float width, float height); |
| 65 | 65 |
| 66 void beginPath(); | 66 void beginPath(); |
| 67 | 67 |
| 68 attribute Path2D currentPath; | 68 attribute Path2D currentPath; |
| 69 | 69 |
| 70 // FIXME: Simplify these using optional CanvasWindingRule once crbug.com/339
000 gets fixed. | 70 // FIXME: Simplify these using optional CanvasWindingRule once crbug.com/339
000 gets fixed. |
| 71 void fill(); | 71 void fill(); |
| 72 [RuntimeEnabled=Path2D, RaisesException] void fill(Path2D? path); | 72 [RuntimeEnabled=Path2D, StrictTypeChecking] void fill(Path2D path); |
| 73 void fill(CanvasWindingRule winding); | 73 [StrictTypeChecking] void fill(CanvasWindingRule winding); |
| 74 [RuntimeEnabled=Path2D, RaisesException] void fill(Path2D? path, CanvasWindi
ngRule winding); | 74 [RuntimeEnabled=Path2D, StrictTypeChecking] void fill(Path2D path, CanvasWin
dingRule winding); |
| 75 void stroke(); | 75 void stroke(); |
| 76 [RuntimeEnabled=Path2D, RaisesException] void stroke(Path2D? path); | 76 [RuntimeEnabled=Path2D, StrictTypeChecking] void stroke(Path2D path); |
| 77 // FIXME: Simplify these using optional CanvasWindingRule once crbug.com/339
000 gets fixed. | 77 // FIXME: Simplify these using optional CanvasWindingRule once crbug.com/339
000 gets fixed. |
| 78 void clip(); | 78 void clip(); |
| 79 [RuntimeEnabled=Path2D, RaisesException] void clip(Path2D? path); | 79 [RuntimeEnabled=Path2D, StrictTypeChecking] void clip(Path2D path); |
| 80 void clip(CanvasWindingRule winding); | 80 [StrictTypeChecking] void clip(CanvasWindingRule winding); |
| 81 [RuntimeEnabled=Path2D, RaisesException] void clip(Path2D? path, CanvasWindi
ngRule winding); | 81 [RuntimeEnabled=Path2D, StrictTypeChecking] void clip(Path2D path, CanvasWin
dingRule winding); |
| 82 | 82 |
| 83 // FIXME: Simplify these using optional CanvasWindingRule once crbug.com/339
000 gets fixed. | 83 // FIXME: Simplify these using optional CanvasWindingRule once crbug.com/339
000 gets fixed. |
| 84 boolean isPointInPath(float x, float y); | 84 boolean isPointInPath(float x, float y); |
| 85 [RuntimeEnabled=Path2D, RaisesException] boolean isPointInPath(Path2D? path,
float x, float y); | 85 [RuntimeEnabled=Path2D, StrictTypeChecking] boolean isPointInPath(Path2D pat
h, float x, float y); |
| 86 boolean isPointInPath(float x, float y, CanvasWindingRule winding); | 86 [StrictTypeChecking] boolean isPointInPath(float x, float y, CanvasWindingRu
le winding); |
| 87 [RuntimeEnabled=Path2D, RaisesException] boolean isPointInPath(Path2D? path,
float x, float y, CanvasWindingRule winding); | 87 [RuntimeEnabled=Path2D, StrictTypeChecking] boolean isPointInPath(Path2D pat
h, float x, float y, CanvasWindingRule winding); |
| 88 boolean isPointInStroke(float x, float y); | 88 boolean isPointInStroke(float x, float y); |
| 89 [RuntimeEnabled=Path2D, RaisesException] boolean isPointInStroke(Path2D? pat
h, float x, float y); | 89 [RuntimeEnabled=Path2D, StrictTypeChecking] boolean isPointInStroke(Path2D p
ath, float x, float y); |
| 90 | 90 |
| 91 [RuntimeEnabled=ExperimentalCanvasFeatures] void scrollPathIntoView(); | 91 [RuntimeEnabled=ExperimentalCanvasFeatures] void scrollPathIntoView(); |
| 92 [RuntimeEnabled=ExperimentalCanvasFeatures, RaisesException] void scrollPath
IntoView(Path2D? path); | 92 [RuntimeEnabled=ExperimentalCanvasFeatures, StrictTypeChecking] void scrollP
athIntoView(Path2D path); |
| 93 | 93 |
| 94 // text | 94 // text |
| 95 attribute DOMString font; | 95 attribute DOMString font; |
| 96 attribute DOMString textAlign; | 96 attribute DOMString textAlign; |
| 97 attribute DOMString textBaseline; | 97 attribute DOMString textBaseline; |
| 98 | 98 |
| 99 TextMetrics measureText(DOMString text); | 99 TextMetrics measureText(DOMString text); |
| 100 | 100 |
| 101 // Context state | 101 // Context state |
| 102 // Should be merged with WebGL counterpart in CanvasRenderingContext, once n
o-longer experimental | 102 // Should be merged with WebGL counterpart in CanvasRenderingContext, once n
o-longer experimental |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 171 [RuntimeEnabled=ExperimentalCanvasFeatures] void drawFocusIfNeeded(Element e
lement); | 171 [RuntimeEnabled=ExperimentalCanvasFeatures] void drawFocusIfNeeded(Element e
lement); |
| 172 [RuntimeEnabled=ExperimentalCanvasFeatures] boolean drawCustomFocusRing(Elem
ent element); | 172 [RuntimeEnabled=ExperimentalCanvasFeatures] boolean drawCustomFocusRing(Elem
ent element); |
| 173 | 173 |
| 174 [ImplementedAs=imageSmoothingEnabled, MeasureAs=PrefixedImageSmoothingEnable
d] attribute boolean webkitImageSmoothingEnabled; | 174 [ImplementedAs=imageSmoothingEnabled, MeasureAs=PrefixedImageSmoothingEnable
d] attribute boolean webkitImageSmoothingEnabled; |
| 175 [MeasureAs=UnprefixedImageSmoothingEnabled] attribute boolean imageSmoothing
Enabled; | 175 [MeasureAs=UnprefixedImageSmoothingEnabled] attribute boolean imageSmoothing
Enabled; |
| 176 | 176 |
| 177 Canvas2DContextAttributes getContextAttributes(); | 177 Canvas2DContextAttributes getContextAttributes(); |
| 178 }; | 178 }; |
| 179 | 179 |
| 180 CanvasRenderingContext2D implements CanvasPathMethods; | 180 CanvasRenderingContext2D implements CanvasPathMethods; |
| OLD | NEW |