1

I use svg path with

style="stroke: rgb(0,0,0); stroke-width: 10; stroke-linecap: round; fill: none;"

that allows me not to close svg path and it will have particular stroke width and shape.

But I need to use pure svg path without any properties or styles and get the same result. Is there're any algorithms to achieve it?

Here is an input svg.

An output should looks like

<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" width="500" height="500" xml:space="preserve">
<path d="path-data"/>
</svg>
Pavlo Kozlov
  • 966
  • 1
  • 9
  • 22
  • "pure svg path without any properties" you mean with only `` ? that's a weird requirement, and you won't be able to produce anything from it no. Ah or you mean you're ok to get the `d` attribute, but want the same result as stroke-width=10 but only with the default fill ? – Kaiido Apr 24 '17 at 07:50
  • That's correct! Updated question description. – Pavlo Kozlov Apr 24 '17 at 07:54
  • 1
    Then it's not trivial to produce such a path programmatically, stroking can be tricky. – Kaiido Apr 24 '17 at 07:57

0 Answers0