问题
I'm running wkhtmltopdf on linux server (centos.10.x86_64). I'm trying to add "Times New Roman" font to the page. I see the fonts but on some font sizes it adds spaces between the letters. I tried setting the font by installing it on the machine (ttf) or by calling an external odf that I converted from the ttf or by adding it with base64 (css). It looks good on all, but it inserts spaces between the laters. I also tried to the dpi parameter but still the spaces are generated. Generating the same pdf over MAC works perfectly (probably because the font comes with the machine)
Why does it happen and how can it be fixed ?
Thanks.
The image attached describes the bug. No spaces added in each of the fonts group. The following the image text
abcdefg hijklmno pqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ
回答1:
Was resolved using "svg" font format
来源:https://stackoverflow.com/questions/25908298/wkhtmltopdf-custom-font-letter-spacing