Bug 79804 - Incorrect text rendering
Summary: Incorrect text rendering
Status: RESOLVED DUPLICATE of bug 93299
Alias: None
Product: poppler
Classification: Unclassified
Component: cairo backend (show other bugs)
Version: unspecified
Hardware: x86 (IA32) Linux (All)
: medium normal
Assignee: poppler-bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-06-08 16:30 UTC by madbiologist
Modified: 2016-04-08 05:32 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
example pdf (17.80 KB, text/plain)
2014-06-08 16:30 UTC, madbiologist
Details
screenshot showing text misrendering (83.80 KB, image/gif)
2014-06-08 16:33 UTC, madbiologist
Details

Description madbiologist 2014-06-08 16:30:56 UTC
Created attachment 100679 [details]
example pdf

Originally reported at https://bugs.launchpad.net/ubuntu/+source/evince/+bug/485745 in the 7th comment, and still reproducible with evince 3.10.3-0ubuntu10 and poppler 0.24.5-2ubuntu4.

The text in the attached file is badly misrendered.  See the screenshot attached in the next comment.
Comment 1 madbiologist 2014-06-08 16:33:16 UTC
Created attachment 100680 [details]
screenshot showing text misrendering
Comment 2 Thomas Freitag 2016-03-16 16:14:47 UTC
That PDF uses the hebrew chars of the arial font, but the font is not embedded:

./utils/pdffonts -subst HW4.pdf 
name                                 object ID substitute font                      substitute font file
------------------------------------ --------- ------------------------------------ ------------------------------------
Courier                                   5  0 Nimbus Mono L                        /usr/share/fonts/type1/gsfonts/n022003l.pfb
Arial,Bold                                8  0 Liberation Sans Bold                 /usr/share/fonts/truetype/liberation/LiberationSans-Bold.ttf
Calibri,Bold                             10  0 DejaVu Sans Bold                     /usr/share/fonts/truetype/dejavu/DejaVuSans-Bold.ttf
Arial                                    12  0 Liberation Sans                      /usr/share/fonts/truetype/liberation/LiberationSans-Regular.ttf
Times-Roman                              13  0 Nimbus Roman No9 L                   /usr/share/fonts/type1/gsfonts/n021003l.pfb
Times-Italic                             14  0 Nimbus Roman No9 L Regular Italic    /usr/share/fonts/type1/gsfonts/n021023l.pfb
Symbol                                   15  0 Symbol                               /usr/share/fonts/X11/Type1/Symbol.pfb
Arial,Bold                               20  0 Liberation Sans Bold                 /usr/share/fonts/truetype/liberation/LiberationSans-Bold.ttf

Therefore You need the unicode version of the arial font (and also arial bold) and configure fontconfig to use this/these font/s, or You should force the PDF generator to include the fonts!

Poppler doesn't deliver any fonts!
Comment 3 Thomas Freitag 2016-03-16 16:17:39 UTC
Oh, I forgot: I even haven't installed the unicode version of these fonts, so on my system I got the same output with the fonts of comment 2.
But I can render it on my windows system, where I have the MS fonts installed!
Comment 4 Jason Crain 2016-03-19 23:16:26 UTC
This file would be fixed by my patch in bug 93299.  It provides fontconfig some hints about the character encoding so it can do better at choosing an appropriate font.
Comment 5 Thomas Freitag 2016-03-20 11:00:37 UTC
(In reply to Jason Crain from comment #4)
> This file would be fixed by my patch in bug 93299.  It provides fontconfig
> some hints about the character encoding so it can do better at choosing an
> appropriate font.

May You have a look at bug 43488 and bug 41104 if Your patch of bug 93299 fixes them, too? And mark them as duplicate if so?
Comment 6 Jason Crain 2016-03-20 14:11:24 UTC
(In reply to Thomas Freitag from comment #5)
> May You have a look at bug 43488 and bug 41104 if Your patch of bug 93299
> fixes them, too? And mark them as duplicate if so?

No, my patch does not fix either of those.  The files in both of those bugs directly use the glyph IDs to look up glyphs.  Which is completely insane for a non-embedded font because glyph IDs are not in any way portable.  To get them to work you could install the exact same Arial font.  Not just a similar or compatible font like Liberation Sans, but Microsoft's own Arial font.  Installing msttcorefonts should work.  Might have to also add a fontconfig rule to match ArialMT to Arial.
Comment 7 Jason Crain 2016-04-08 05:32:49 UTC

*** This bug has been marked as a duplicate of bug 93299 ***


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.