Jump to content
elgarak

Importing PDFs generated with LaTeX

Recommended Posts

Affinity Publisher (and Designer) do not import PDFs generated by LaTeX properly. So far, it seems to be not influenced by the LaTeX engine (pdfLatex or XeLaTeX, for instance).

First obvious problem is that Publisher does not use the fonts that are embedded in the PDF. First workaround tried by me was to install LaTeX specific fonts into macOS, and choose them in the replacement dialog, but this does not completely work (math doesn't read at all convincingly. Text works better that way, but diacritics (German umlauts) don't set correctly (the dots are set off to the left)). After some digging into the forums, a better workaround is to change the LaTeX source to use the macOS installed replacement fonts, and open and re-save the PDF with Preview. This does produce an improved import, as far as text is concerned. Math still has some problems. The equations are by now recognizable, but there are still the occasional (completely) wrong glyph used, and some sizes are wrong (for normal Roman font used within math environments).

I have attached a small test file with some common elements (mostly equations). This file is done with standard pdfLaTeX and the LaTeX-specific Computer Modern fonts. As far as I checked, all fonts are embedded within the PDF. The PDF opens properly on my Windows test system in browsers and PDF readers, and prints properly. I can produce other variations, if needed.

equations.pdf

Share this post


Link to post
Share on other sites

Hi elgarak,

Thanks very much for the files. I've found some similar fonts to the ones the document is using, however Affinity is still looking for them when opening the PDF, so if possible could you attach the actual fonts that the ones in the document used please?

I tried a set of TTF and OTF Computer Modern fonts, but the OTF gave very different results to the TTF, so I just want to make sure we're on the same page when I report to development!

Thanks!

Share this post


Link to post
Share on other sites
2 hours ago, fde101 said:

try opening the PDF in Preview or other app that uses the embedded fonts?

Opening with Preview works but does not help the issue... but in another thread it was suggested that printing the file to .ps should convert the fonts to curves. You might want to try that. One page at the time maximum, .ps import seem not to support multipage.

Share this post


Link to post
Share on other sites
On 10/5/2018 at 6:44 PM, fde101 said:

That was meant for Sean to give him something to compare against.

Thanks, but I wanted to make sure the results I was getting when importing to Affinity was the same as the ones OP was getting. As two different versions of these fonts was giving me completely differing results when importing!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×