-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix SVG resize in cairosvg and inkscape builder #184
base: develop
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello, Thank for this contribution.
I'm not sure to understand what this PR does.
Does this preserve image ratio ?
@L3o-pold ping. I haven't reviewed this PR. Can you provide us with some insight on this PR so we can review it in the best conditions? What problem are you solving? |
@inkhey it depends on how cairosvg.svg2png handle ratio. It prevents deforming svg. You can try to before/after with an svg icon for example. Before the patch if you ask a big size it will not be extended as it should. |
Just tested with or without this patch: For cairosvg:
For inkscape:
Not sure what should be the correct behavior here. |
@inkhey you can see that with patch file |
As behavior are unclear, i will create an issue to make decision. As we will not fix the fully problem here (should we use view or drawing view, what about some person that do need not preserving ratio), i suggest you to fix inkscape builder in a way ratio is preserved. A not perfect but nice enough solution may be setting only height or width, as inkscape does not provide command line out of the box to do so. |
Inkscape issue is https://gitlab.com/inkscape/inbox/-/issues/2111 related. |
No description provided.