Quantcast
Channel: wrong letter positioning and font in PDF form - Ask Ubuntu
Viewing all articles
Browse latest Browse all 2

wrong letter positioning and font in PDF form

$
0
0

I'm using Ubuntu 18.04 and filling out the SS-5 Social Security Administration form. However, some of the letters are wrongly positioned.

Evince 3.28.2-1:

evince screenshot (has kerning issues)

Okular 1.3.3 (Ubuntu version 4:17.12.3-0ubuntu1):

Okular screenshot (has kerning issues)

xpdf 3.04-7:

xpdf screenshot (has kerning issues)

mudpdf 1.12.0:

mupdf screenshot (no kerning issues)

The built-in PDF reader for Firefox 59.0.2:

firefox screenshot (no kerning issues)

The built-in PDF reader for Chromium 65.0.3325.181:

chromium screenshot (no kerning issues)

Here is the output of pdffonts:

$ pdffonts ss-5.pdfname                                 type              encoding         emb sub uni object ID------------------------------------ ----------------- ---------------- --- --- --- ---------IHPIKC+ArialMT                       CID TrueType      Identity-H       yes yes yes    824  0ArialMT                              TrueType          WinAnsi          no  no  no     826  0Arial-BoldMT                         TrueType          WinAnsi          no  no  no     828  0CourierStd                           Type 1            WinAnsi          no  no  no     145  0Helvetica                            Type 1            WinAnsi          no  no  no     197  0MyriadPro-Regular                    Type 1            WinAnsi          no  no  no     198  0ZapfDingbats                         Type 1            ZapfDingbats     no  no  no     199  0

I have already installed the ttf-mscorefonts-installer and poppler-data packages.

Here are my questions:

  • Can I change the font used for filling in the cells of the form?

    It seems like Evince and xpdf are using a variable-width font when they should be using a monospaced font, and maybe this is causing the positioning problem.

  • If I were to file a bug report, should I file it as a poppler issue, a fontconfig issue, or somewhere else?

Update: bug reports:

Edit: The workaround from @xiota is perfectly functional. However, this is still a bug in poppler, because when the PDF viewer substitutes a different font due to the original not being embedded, the spacing in the XFA form should match the substituted font, not the original font. There is a pull request to fix this that is currently in progress. Poppler developer Tobias Deiminger (@haxtibal) described the approach in a different bug report:

The strategy there is, if a font is not embedded, gather and use metrics fromthe actual substitute font instead of metrics from PDF font descriptor orhardcoded ones.


Viewing all articles
Browse latest Browse all 2

Latest Images

Trending Articles





Latest Images