From:  Eric Shepherd <eshepherd@mozilla.com>
Date:  21 Jan 2015 01:50:10 Hong Kong Time
Newsgroup:  news.mozilla.org/mozilla.dev.web-development
Subject:  

Re: Canvas question: dotted/dashed lines?

NNTP-Posting-Host:  63.245.216.66

What issues do you have with the canvas documentation? We literally just (within the last week or two) finished a massive overhaul, updating the content, writing docs for everything in the canvas rendering context, and so forth.

The reason you can’t find anything about how to draw a stroked line in a canvas is because there isn’t support for that at this time. You have to create an appropriate canvas pattern object and use that.  For instance: http://stackoverflow.com/questions/4576724/dotted-stroke-in-canvas

I hope they update the strokeStyle property to support “dashed” and so forth, though.

-- 
Eric Shepherd
Developer Documentation Lead
Mozilla
Blog: http://www.bitstampede.com/
Twitter: http://twitter.com/sheppy

On January 20, 2015 at 5:37:19 AM, Jeremy (jeremy@pinacol.com) wrote:

The canvas element is pretty poorly documented.