[whatwg] Canvas 2d: proposal to add path(DOMString)

Charles Pritchard chuck at jumis.com
Fri Jul 29 13:44:07 PDT 2011

Having spoken to several developers, I think that we're clear to add a 
new method to the canvas 2d api;
though there is some question about how it should be added.

The method would take a DOMString using SVG path semantics.

I'm not certain which route is better:
ctx.fillPath('M ..z'), ctx.strokePath('M...z');

This usually takes ~80 lines of JavaScript to support,
we're eager to see it added to native implementations.

All browser vendors have SVG support now, and could easily re-use
code from their SVG implementations to implement this canvas 2d 


More information about the whatwg mailing list