mathandy / svgpathtools

A collection of tools for manipulating and analyzing SVG Path objects and Bezier curves.
MIT License
557 stars 142 forks source link

px to pt conversion #141

Closed user123-source closed 3 years ago

user123-source commented 3 years ago

Hi

I am trying to draw on to an existing svg, but seem to be having a problem lining up elements. I think its the conversion to pt from px and i am using 1.25, but its still a bit off.

How would i draw using pt instead of px?

user123-source commented 3 years ago

Wow, that was a journey

I'm still new to SVGs, but just figured out that it was a scaling issue between the SVG viewBox and bounding box. Once I added in the ratio adjustment of the two everything lined up.