I have a PDF form generated by LibreOffice. Since to a known bug in LibreOffice only a font subset is embedded into PDF even when the font is used in form fields. Therefore the form is not usable or form fields are using a wrong front (depending on PDF viewer) if the font is not installed on computer.
So I have to replace form subset in PDF form by whole font after generation in LibreOffice. Normally using ps2pdf or gs is recommended to fix a font issue in a pdf. But both programs don't support PDF form. If using them on a PDF form the form fields are broken. I tested it with Ghostscript 9.10 under Unbunt 14.04 LTS.
I can use pdffonts to show fonts embedded in PDF. But is there also a command-line tool to embed another font into a PDF?
Libreoffice v5.2 embedding fonts for forms fields is easy:
Enable the font in the form field: () Right-click form field > Control > Font
Then tell your document to include the used fonts into its file: () File > Properties > Font tab > Embed fonts into document In my case filesize increases from 50k to 5000k (using one font with two styles).
At last check PDF options to include fonts into pdf: () File > Export to Pdf > General tab: x Enable Create PDF form (to make the form fields fill-in ready to the user). Not shure whether both of the following options are needed: x Tagged PDF and x Hybrid PDF: The later will enlarge pdf to the size of the LibreOffice file.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With