Hi WebKit folks, I worked on the Path interface defined by the Canvas spec of W3C and WHATWG  for the last couple of weeks.
Summary: Canvas supports a new DOM interface called Path. The Path interface takes a series of very well known path methods like moveTo, lineTo, cubicCurveTo, rect and allows to create and keep a path independent of a Canvas context. Additionally, I added the attribute 'currentPath' to the Canvas context to provide read and write access to the current path created on the Canvas context. Code snippet: var path = new Path(); path.rect(0,0,100,100); var ctx = canvas.getContext('2d'); ctx.currentPath = path; ctx.lineTo(200,200); ctx.closePath(); var path2 = ctx.currentPath; // path2 != path Not implemented are addText, addPath, addPathByStrokingText. Another proposal from Rik Cabanier seems to address the idea behind these methods better. I would like to ask to enable CANVAS_PATH by default on trunk. Ports can opt-out the flag again. More information about some implementation details in a short article. If there are any concerns, suggestions or questions, I am happy to answer them. Greetings, Dirk  http://www.w3.org/html/wg/drafts/2dcontext/html5_canvas/#path-objects  http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#path-objects  http://blogs.adobe.com/webplatform/2013/01/31/revised-canvas-paths/  http://dschulze.com/blog/articles/10/html-canvas-path-object-in-webkit _______________________________________________ webkit-dev mailing list email@example.com https://lists.webkit.org/mailman/listinfo/webkit-dev