Skip to content
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

SVG getting mangled when I export to pdf #278

Closed
kennedydane opened this issue Nov 11, 2015 · 12 comments
Closed

SVG getting mangled when I export to pdf #278

kennedydane opened this issue Nov 11, 2015 · 12 comments
Labels
bug Existing features not working as expected

Comments

@kennedydane
Copy link

Hi Simon,

I've put my test case here. Essentially the html output is from a jinja2 script and the svg is from ggplot (python's one, not R). I can't imagine why it would make a difference, and it didn't, but I used weasyprint in both CLI and in python. The pdf is just fine if I export my image to png (except the png is uglier and bigger).

Thanks for any help you can give,
Dane.

@SimonSapin
Copy link
Member

@liZe is you cairo patch published somewhere?

@kennedydane
Copy link
Author

Super, thanks! I think the latter will be pretty easy to implement.

/me goes and tries.

@kennedydane
Copy link
Author

Oh, btw, while trying to figure out what was potting I noticed in image.py that quite often you're setting self.intrinsic_ratio, where setting self._intrinsic_ratio would be more consistent. I couldn't find where intrinsic_ratio was actually used, so it might not even be a problem. But ya. Seemed odd to me.

@kennedydane
Copy link
Author

Yay, just changing that width and heigh parameter worked like a charm.

@SimonSapin
Copy link
Member

It’s been a while since I looked at image.py. If you think there’s a bug there, please file an issue with details or submit a PR!

@kennedydane
Copy link
Author

I'm not really confident in my knowledge of the code, but I'll try to make a contribution a bit later in the week.

@liZe
Copy link
Member

liZe commented Nov 11, 2015

http://lists.cairographics.org/archives/cairo/2013-May/024301.html
http://lists.cairographics.org/archives/cairo/2013-June/024406.html

I've tried to send the patch twice on the mailing list, and twice directly with the author of the commit.

@liZe
Copy link
Member

liZe commented Jan 1, 2016

@liZe
Copy link
Member

liZe commented Jan 15, 2016

And one more, sent with git-send-mail after a remark from a member of the mailing list:
http://lists.cairographics.org/archives/cairo/2016-January/027185.html

@liZe liZe added the bug Existing features not working as expected label Mar 8, 2016
@liZe
Copy link
Member

liZe commented Apr 10, 2016

Someone with the same problem:
https://lists.cairographics.org/archives/cairo/2016-April/027371.html

@liZe
Copy link
Member

liZe commented Apr 16, 2016

Yeah! The patch finally got accepted!

https://cgit.freedesktop.org/cairo/commit/?id=d2f1ebf579ba12b816eec9317f98eb845fbfeb4f

@liZe liZe closed this as completed Apr 16, 2016
@kennedydane
Copy link
Author

kennedydane commented Apr 18, 2016

fantastic :-).

On Sat, Apr 16, 2016 at 12:08 PM, Guillaume Ayoub [email protected]
wrote:

Closed #278 #278.


You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub
#278 (comment)


Dane Kennedy

If you really want something in this life, you have to work for it. Now,
quiet! They're about to announce the lottery numbers
-- Homer Simpson

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Existing features not working as expected
Projects
None yet
Development

No branches or pull requests

3 participants