CanvasRenderingContext2D.idl [plain text]
[
CustomIsReachable,
JSGenerateToJSObject,
JSCustomMarkFunction,
CallTracingCallback=recordCanvasAction,
] interface CanvasRenderingContext2D {
readonly attribute HTMLCanvasElement canvas;
[ImplementedAs=setGlobalAlpha] void setAlpha(optional unrestricted float alpha = NaN);
[ImplementedAs=setGlobalCompositeOperation] void setCompositeOperation(optional DOMString compositeOperation = "undefined");
void drawImageFromRect(HTMLImageElement image,
optional unrestricted float sx = 0, optional unrestricted float sy = 0, optional unrestricted float sw = 0, optional unrestricted float sh = 0,
optional unrestricted float dx = 0, optional unrestricted float dy = 0, optional unrestricted float dw = 0, optional unrestricted float dh = 0,
optional DOMString compositeOperation = "");
void setStrokeColor(DOMString color, optional unrestricted float alpha);
void setStrokeColor(unrestricted float grayLevel, optional float alpha = 1);
void setStrokeColor(unrestricted float r, unrestricted float g, unrestricted float b, unrestricted float a);
void setStrokeColor(unrestricted float c, unrestricted float m, unrestricted float y, unrestricted float k, unrestricted float a);
void setFillColor(DOMString color, optional unrestricted float alpha);
void setFillColor(unrestricted float grayLevel, optional unrestricted float alpha = 1);
void setFillColor(unrestricted float r, unrestricted float g, unrestricted float b, unrestricted float a);
void setFillColor(unrestricted float c, unrestricted float m, unrestricted float y, unrestricted float k, unrestricted float a);
readonly attribute float webkitBackingStorePixelRatio;
[ImplementedAs=imageSmoothingEnabled] attribute boolean webkitImageSmoothingEnabled;
void setLineWidth(optional unrestricted float width = NaN);
void setLineCap(optional DOMString cap = "undefined"); void setLineJoin(optional DOMString join = "undefined"); void setMiterLimit(optional unrestricted float limit = NaN);
attribute sequence<unrestricted float> webkitLineDash;
[ImplementedAs=lineDashOffset] attribute unrestricted float webkitLineDashOffset;
void setShadow(unrestricted float width, unrestricted float height, unrestricted float blur, optional DOMString color, optional unrestricted float alpha);
void setShadow(unrestricted float width, unrestricted float height, unrestricted float blur, unrestricted float grayLevel, optional unrestricted float alpha = 1);
void setShadow(unrestricted float width, unrestricted float height, unrestricted float blur, unrestricted float r, unrestricted float g, unrestricted float b, unrestricted float a);
void setShadow(float width, unrestricted float height, unrestricted float blur, unrestricted float c, unrestricted float m, unrestricted float y, unrestricted float k, unrestricted float a);
void clearShadow();
[EnabledAtRuntime=InspectorAdditions] void setPath(Path2D path);
[EnabledAtRuntime=InspectorAdditions, NewObject] Path2D getPath();
};
CanvasRenderingContext2D implements CanvasState;
CanvasRenderingContext2D implements CanvasTransform;
CanvasRenderingContext2D implements CanvasCompositing;
CanvasRenderingContext2D implements CanvasImageSmoothing;
CanvasRenderingContext2D implements CanvasFillStrokeStyles;
CanvasRenderingContext2D implements CanvasShadowStyles;
CanvasRenderingContext2D implements CanvasFilters;
CanvasRenderingContext2D implements CanvasRect;
CanvasRenderingContext2D implements CanvasDrawPath;
CanvasRenderingContext2D implements CanvasUserInterface;
CanvasRenderingContext2D implements CanvasText;
CanvasRenderingContext2D implements CanvasDrawImage;
CanvasRenderingContext2D implements CanvasImageData;
CanvasRenderingContext2D implements CanvasPathDrawingStyles;
CanvasRenderingContext2D implements CanvasTextDrawingStyles;
CanvasRenderingContext2D implements CanvasPath;