Can anyone give me an example of these attributes in action: stroke-dasharray, stroke-linecap, stroke-linejoin i tried using them, but i don\'t quite understand the sente
If you want to apply a dashed line in a standard SVG way on a Raphael line object, this worked well for me; whereas I didn't have any luck using period and hyphens as done in the Raphael way.
myLine.attr({stroke:'green'}).node.setAttribute('stroke-dasharray', '10,10');
The parameters (10,10
in this example) are the length,gap and you can iterate that as much as you want. Like 5, 5, 1, 5
would be shorter dashes with dots.
Reference: https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/stroke-dasharray