-
Notifications
You must be signed in to change notification settings - Fork 255
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
[BUG] SVG images are not inserted correctly #572
Comments
Welcome! Thanks for posting your first issue. The way things work here is that while customer issues are prioritized, other issues go into our backlog where they are assessed and fitted into the roadmap when suitable. If you need to get this done, consider buying a license which also enables you to use it in your commercial products. More information can be found on https://unidoc.io/ |
@njkleiner Thanks for your test repo and data you've provided, that was very helpful to us. We've done several enhancements related to SVG and they will be included into UniPDF release later this month, we will notify you when it will be available. The enhancements include fixes for both panics you've found and processing of 'transform' attribute. For 2 files from your test set there is still a problem with displaying related to 'defs' attribute but this is already included into our roadmap for next releases. |
@njkleiner The new UniPDF release is out https://github.com/unidoc/unipdf/releases/tag/v3.64.0 could you please test SVG improvements? Thanks for your cooperation. |
@njkleiner I am closing this issue, if you have any problem with UniPDF, feel free to open another issue or re-open this one. |
Description
Some kinds of SVG images cannot be drawn on a PDF page using
creator.NewGraphicSVGFromFile
.Expected Behavior
The SVG image should be drawn on the page.
If the SVG image cannot be drawn for whatever reason (e.g., the particular structure used within the SVG file is not supported), calling
creator.NewGraphicSVGFromFile
should at least return an error instead of panicking.Actual Behavior
We can observe the following two outcomes (depending on the SVG image input file):
creator.NewGraphicSVGFromFile
does not return an error, but the image is not drawn on the page.creator.NewGraphicSVGFromFile
panics.See the pflege-de/unipdf-issue-insert-svg repository for a full proof-of-concept program that can be used to reproduce the issue, including various example SVG files.
See the README of the repository for more information, including concrete reproduction steps.
The text was updated successfully, but these errors were encountered: