KB: When Opening PDF Generated by Recostar on Linux, Adobe Reader Displays “Cannot find or create the font FreeSans”
Applies to: Transact version 2020.1.06 and above
Affected operating systems: Linux
Issue
This issue occurs when opening a PDF file created by Recostar on Linux after exporting a PDF via the Multipage Export Plugin. When opening the file in Adobe Reader, the following error occurs:
Cannot find or create the font ‘FreeSans.’ Some characters may not display or print correctly.
Figure 1. Adobe Reader error message.
Note: This issue does not occur with PDFs generated by iText or if the PDFs are opened in a web browser.
Solution
To resolve this issue, you will need to manually install Microsoft’s TrueType core fonts, then change the font in the Linux.xml file. Follow the steps below:
- Open a terminal in the Transact server directory.
- Install wget utility by entering the command:
yum install -y wget.
- Complete Steps 1-5 in How to Manually Install Microsoft’s TrueType Core Fonts. Then, continue to Step 4 in this article.
- Navigate to the [Ephesoft_Directory]/Application/native/RecostarPlugin/lib/RecoStarPDF/Linux.xml folder.
- Open the Linux.xml file in a text editor.
- Comment out the line: <Font FamilyName=’FreeSans’ FileName=’FreeSans.ttf’/>
- Then add the line <Font FamilyName=’arial’ FileName=’arial.ttf’/>
Note: In the example above, replace “arial” with your preferred font.
Figure 2. Add a line for the new font.
Note: Batch export will fail if the Linux.xml file is modified without installing the MS TrueType fonts.
- Save and close the file.
- Restart Transact.