-
Notifications
You must be signed in to change notification settings - Fork 24
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
Enable cairo renderer in Graphviz #285
Comments
I am not sure the effort needed to create a wasm version of cairo (and its dependencies) to create a pdf would be worth the effort? In the past when I have needed to generate (quality) pdf files from a rendered web page I have stood up a headless chrome instance on the server and used the "Save as / Export to PDF" feature (that is built into the browser)... I do have a generic widget that can host visualizations and download them to png from the browser? |
The problem is that a chrome instance is pretty heavy. Our application is currently mostly a static web page with a few requests to a cheap VPS does not have the capacity to do rendering of its own. This is why we would like to push this to the client which would also improve latency and reduce bandwidth as we do not need to send PDFs over the network. |
FYI - I have a POC of svg->pdf working (via wasm), but it requires loading the referenced font(s) manually into the wasm function, which is not very elegant. |
The cairo renderer is very useful for PDF outputs. Something similar can be hacked together by using svg2pdf.js but that has several layout bugs where elements (especially text) end up in the wrong place.
The text was updated successfully, but these errors were encountered: