
Implement setLineDash() and getLineDash() in CanvasPathDrawingStyles, which write/read from the CanvasState object. This doesn't implement the actual drawing of a dashed line, but at least sites using the Chart.js library no longer fail with an exception. Unfortunately the Painter classes don't support dashed/dotted lines based on segments yet.
15 lines
659 B
Text
15 lines
659 B
Text
// https://html.spec.whatwg.org/multipage/canvas.html#canvaslinecap
|
|
enum CanvasLineCap { "butt", "round", "square" };
|
|
enum CanvasLineJoin { "round", "bevel", "miter" };
|
|
|
|
// https://html.spec.whatwg.org/multipage/canvas.html#canvaspathdrawingstyles
|
|
interface mixin CanvasPathDrawingStyles {
|
|
attribute unrestricted double lineWidth;
|
|
[FIXME] attribute CanvasLineCap lineCap;
|
|
[FIXME] attribute CanvasLineJoin lineJoin;
|
|
[FIXME] attribute unrestricted double miterLimit;
|
|
|
|
undefined setLineDash(sequence<unrestricted double> segments);
|
|
sequence<unrestricted double> getLineDash();
|
|
[FIXME] attribute unrestricted double lineDashOffset;
|
|
};
|