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

Certificate PDF outputs loose their fonts and background #95

Open
MathewBiddle opened this issue May 17, 2023 · 1 comment
Open

Certificate PDF outputs loose their fonts and background #95

MathewBiddle opened this issue May 17, 2023 · 1 comment
Labels
bug Something isn't working ideas-for-next-workshop

Comments

@MathewBiddle
Copy link
Contributor

When converting the svg's to pdf's we loose the fancy fonts and background.

SVG:
image

PDF:
image

There are ways to embed fonts into svg, but I haven't figured it out. I think the trouble is Adobe only comes with 12 fonts by default.

Will need to fiddle with this function to make it work:

def svg2pdf(fname):
drawing = svg2rlg(fname)
outname = fname.replace(".svg", ".pdf")
renderPDF.drawToFile(drawing, outname)

@MathewBiddle MathewBiddle added bug Something isn't working ideas-for-next-workshop labels May 17, 2023
@7yl4r
Copy link
Contributor

7yl4r commented May 19, 2023

It might be easier to just export to png instead of a pdf.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working ideas-for-next-workshop
Projects
None yet
Development

No branches or pull requests

2 participants