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

transform statement #4

Closed
UlrichRe opened this issue Nov 10, 2016 · 15 comments
Closed

transform statement #4

UlrichRe opened this issue Nov 10, 2016 · 15 comments

Comments

@UlrichRe
Copy link

Hi Jeroen,

thank you for your work. I would like to use rsvg to convert an svg character string to a pdf file, but it looks to me that there is an issue with inner nodes transform statements.

F.i. look in the attached example svg.test.pdf at value 8,4 of node 'RND (Plan) [J]'.
Value 8,4 should be right-aligned in column 'Total', but it is displayed too far left.
File svg.test.pdf was generated by rsvg from svg character string in file svg.test.txt.
file svg.test.safari.pdf was generated from svg.test.txt in Safari and looks correct.
( svg.test.txt also is presented correctly in Chrome.)

Regards,
Ulrich

svg test.pdf
svg test.txt
svg test safari.pdf

@jeroen
Copy link
Member

jeroen commented Nov 24, 2016

You have to ask rendering questions to the librsvg folks: https://wiki.gnome.org/LibRsvg. The R package only has bindings to librsvg2, it does not actually implement the rendering. I suspect that your svg file is malformed in some way though.

@UlrichRe
Copy link
Author

UlrichRe commented Nov 28, 2016 via email

@jeroen
Copy link
Member

jeroen commented Nov 28, 2016

Yes you will have to ask this on the librsvg mailing list or bug tracker. The R package only has a bindings, it does not control the rendering in any way...

@UlrichRe
Copy link
Author

UlrichRe commented Nov 29, 2016 via email

@UlrichRe
Copy link
Author

UlrichRe commented Dec 3, 2016 via email

@jeroen
Copy link
Member

jeroen commented Dec 3, 2016

Which operating system do you use? On Windows the package uses librsvg-2.40.16. On other systems it depends on what is installed on your system. But I think this problem appears with the latest version as well.

@UlrichRe
Copy link
Author

UlrichRe commented Dec 3, 2016 via email

@jeroen
Copy link
Member

jeroen commented Dec 3, 2016

Do you have homebrew installed on your system?

@UlrichRe
Copy link
Author

UlrichRe commented Dec 3, 2016 via email

@jeroen
Copy link
Member

jeroen commented Dec 3, 2016

That way you can controll the version of librsvg yourself. So you can do:

brew install librsvg

And then in R:

install.packages("rsvg", type = "source")

@UlrichRe
Copy link
Author

UlrichRe commented Dec 3, 2016 via email

@jeroen
Copy link
Member

jeroen commented Dec 3, 2016

Note that the librsvg from brew also comes with a handy command line utility rsvg-convert. You can use this to convert the svg to png via the command line, to rule out a problem in R:

rsvg-convert svg.test.txt > out.png

@UlrichRe
Copy link
Author

UlrichRe commented Dec 3, 2016 via email

@jeroen
Copy link
Member

jeroen commented Dec 3, 2016

Yes, try this

rsvg-convert svg.test.txt -f pdf -o test.pdf

@jeroen
Copy link
Member

jeroen commented Dec 3, 2016

I am closing this issue here because this is a problem in librsvg that also happens without R.

@jeroen jeroen closed this as completed Dec 3, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants