pixelDensity(2) with SVG creates incorrect viewport in the file #693
Labels
bug
Something isn't working
good first issue
Good for newcomers
help wanted
Extra attention is needed
In GitLab by @mrbbp on Mar 24, 2023, 09:36
Description
i was playing around with svg export and curve drawing.
I'm working on MacOS with a retina display, therefore i add pixelDensity to improve display.
Expected Behavior
the document should stay in the viewbox
Current Behavior
When we export to svg, there is a glitch on the output file.
there is a
transform="scale(2,2)"
on the exported shape.I understand why, but in fact it's useless, because it's vector shape exported.
the document is defined with the right definition (created with
size(width, height)
in the script)by adding a
transform
, it modify the preview and the size of the shape in the viewbox.Steps to Reproduce
Your Environment
Possible Causes / Solutions
Remove the
transform="scale(2,2)"
on each group of shapeor
adjust the document size (
with
andheight
) according to thepixelDensity
instruction in the<svg>
tag to have a correct preview and document viewbox.The text was updated successfully, but these errors were encountered: