Konubinix' opinionated web of thoughts

Maaf

Fleeting

Wrong pdffonts in their communication

The pdf they send (e.g., the attestation habitation) displays fine in zathura, but is garbled when printed with lpr.

Check whether the fonts it uses are embedded in the file (emb column).

pdffonts "${file}"
name                                 type              encoding         emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
Verdana-Bold                         CID TrueType      Identity-H       no  no  yes      7  0
Verdana                              CID TrueType      Identity-H       no  no  yes      8  0
Verdana                              CID TrueType      Identity-H       no  no  yes      9  0
Verdana-Bold                         CID TrueType      Identity-H       no  no  yes     10  0

Look at the “emb” column. It says no, therefore, they are not. Re-render it with poppler, which embeds the fonts it uses.

pdftocairo -pdf "${file}" "/tmp/print.pdf"
pdffonts "/tmp/print.pdf"
name                                 type              encoding         emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
HEPCTC+DejaVuSans-Bold               TrueType          WinAnsi          yes yes yes      7  0
ETDQMS+DejaVuSans                    TrueType          WinAnsi          yes yes yes      8  0
ETJPUH+DejaVuSans                    TrueType          WinAnsi          yes yes yes     10  0
AQQZZH+DejaVuSans-Bold               TrueType          WinAnsi          yes yes yes     11  0

The fonts are now embedded, so print this file instead of the original.

lpr "/tmp/print.pdf"

Notes pointant ici