2

I've received a pdf invoice document containing Polish characters and I cannot render it properly using evince. The problem is related to the font settings. pdffonts show me this:

$ pdffonts test.pdf 
name                                 type              encoding         emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
EDWAAA+HelveticaNeue-Roman           CID TrueType      Custom           yes yes yes      8  0
EDWAAB+Helvetica75Roman              CID TrueType      Custom           yes yes yes      7  0
ArialMT                              Type 1            WinAnsi          no  no  yes      9  0

Since I didn't have ArialMT font I've downloaded it from here and now I have it correctly cached:

$ fc-match ArialMT
ARI.ttf: "Arial MT" "Regular"

Then I've checked and confirmed installed font correctly displays Polish characters by choosing it in LibreOffice.

Despite this fonts are rendered like this:

enter image description here

This looks like a problem with Poppler because I can render it correctly with mupdf and Firefox:

enter image description here

okular and qpdfview fail just like evince.

I've downloaded the most recent version of Poppler from here and installed with:

mkdir build
cd build
cmake ..
make
make install

But the problem remain the same. Not sure if evince is using it, though, since I don't see it its shared dependencies

$ ldd /usr/bin/evince | grep -i poppler
$

How can I use force evince to correctly display this font?

1 Answer 1

1

Try Install MS TrueType Fonts as shown below:

$ sudo apt update
$ sudo apt install ttf-mscorefonts-installer

Microsoft’s End user agreement wizard will appear. Click OK to continue.

After installing the fonts, you need to update the font cache using command:

$ sudo fc-cache -f -v

Alternatively, copy all Windows fonts to /usr/share/fonts directory and install the fonts using the following commands:

$ mkdir /usr/share/fonts/WindowsFonts
cp /Windowsdrive/Windows/Fonts/* /usr/share/fonts/WindowsFonts
$ chmod 755 /usr/share/fonts/WindowsFonts/*

Finally, regenerate the fontconfig cache using command:

$ fc-cache

Instruction is from: https://www.ostechnix.com/install-microsoft-windows-fonts-ubuntu-16-04/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.