We have an issue with the letter spacing:
When using the ova image (based on ubuntu), the letter spacing on the pdf is perfect. On a Debian installation using the install.py --production, there are issues with the spacing.
Steps to reproduce:
- Load and install the Frappe/ERPNext production ova image. Run and make a print pdf from a customer record. Observe the customer group label.
- Create a new virtual machine with a vanilla Debian. Install ERPNext according to the install.py --production. Run the system and make a print pdf from a customer record. Compare the customer group label.
Expected behaviour: spacing should be identical.
Actual behaviour: spacing is different.
The CSS and graphics load normally (so no issue on wkhtmltopdf on loading referenced files). We have noted, that font changes seem to get overwritten in the pdf (they apply in the preview, but not in the pdf).
Edit: it only affects Debian 9 stretch. Debian 8 performs as expected.
Any ideas on this?
Side note on pdf creation: when the print template contains the following code
<p>This is a test text.</p>
<p style="font-family: 'Times New Roman', Times, serif;">This is a test text in Times.</p>
<p style="font-family: 'Times New Roman', Times, serif !important;">This is a test text in Times, important.</p>
The preview will show this like
In the pdf it will however be shown without applying the font format:
…and the spacing issue remains when comparing the install.py/Debian against ova/ubuntu…
Update on this: the issue is resolved when installing cups (for some soft dependency).
$ sudo apt install cups
I have the exact same issue but I use frappe_docker and if I try
sudo apt install cups I get:
bash: sudo: command not found
$ apt install cups
E: Could not open lock file /var/lib/dpkg/lock-frontend - open (13: Permission denied)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), are you root?
And in any case, even if I managed to install cups within the docker container to test if it resolves my issue with rendering fonts in PDF, I would need to modify the Dockerfile and create my own docker image of erpnext-python to have cups installed permanently.
I have seen a lot of threads on the same issue in this forum.
Would it be possible to include cups by default in frappe_docker?
Would it be possible to include cups by default in frappe_docker ?
Why not, it should actually be there for a proper output