Bug 84270 - poppler doesn't render any glyphs from a wrong embedded font
Summary: poppler doesn't render any glyphs from a wrong embedded font
Status: RESOLVED FIXED
Alias: None
Product: poppler
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: poppler-bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-09-24 08:37 UTC by Thomas Freitag
Modified: 2014-09-25 22:26 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
PDF with missing glyphs (21.76 KB, application/pdf)
2014-09-24 08:37 UTC, Thomas Freitag
Details
Accepts offsets to the end of the table (1.37 KB, patch)
2014-09-24 08:59 UTC, Thomas Freitag
Details | Splinter Review

Description Thomas Freitag 2014-09-24 08:37:46 UTC
Created attachment 106769 [details]
PDF with missing glyphs

Any glyph of the embedded font SFBMTB+Frutiger-Bold is not rendered in the attached PDF, where as the glyphs of the also embedded font PFBMTB+Frutiger-Light are rendered.
Comment 1 Thomas Freitag 2014-09-24 08:55:10 UTC
The truetype font SFBMTB+Frutiger-Bold has a POST entry in format 2. (This contains the data needed for the FontInfo dictionary entry as well as the PostScript names for all of the glyphs in the font) The spec for this entry says:

If you do not want to associate a PostScript name with a particular glyph, use index number 0 which points to the name .notdef. 

But the software which embeds this font makes it in another way: All not associated glyphs points to the end(!!) of the Postscript name table (entry for this glyphs: 270). That's why poppler invalidates this font and therefore don't render any glyphs of it, and it does so without giving any error message.

But since ghostscript and acrobat reader show the glyph of this font I think poppler should do it either.
Comment 2 Thomas Freitag 2014-09-24 08:59:55 UTC
Created attachment 106771 [details] [review]
Accepts offsets to the end of the table

This patch accepts the entries which points to the end of the table and handles them as if they points to .notdef.

(I've regtested the patch without any problems)
Comment 3 Albert Astals Cid 2014-09-25 22:26:19 UTC
Awesome, commtied.


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.