Bug 88939 - check required hmtx in TTF
Summary: check required hmtx in TTF
Status: RESOLVED FIXED
Alias: None
Product: poppler
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: Other All
: medium enhancement
Assignee: poppler-bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-02-03 10:50 UTC by master_volkov
Modified: 2015-02-07 19:47 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Fix bug font wrong codepage (468 bytes, text/plain)
2015-02-03 10:50 UTC, master_volkov
Details
bug pdf with wrong font (89.69 KB, application/octet-stream)
2015-02-03 18:50 UTC, master_volkov
Details

Description master_volkov 2015-02-03 10:50:39 UTC
Created attachment 113098 [details]
Fix bug font wrong codepage

In MS specification TTF in https://www.microsoft.com/typography/tt/ttf_spec/ttch02.doc clean write: table 'hmtx(horizontal metrics)' is required. And in https://www.microsoft.com/typography/tt/ttf_spec/ttch03.doc this required too.
But font without hmtx exist (mostly as embedded font in pdf). I have that example pdf - on Windows they open without any problems but in linux - font is adsent.

I create bug in "FreeType Project" https://savannah.nongnu.org/bugs/index.php?44169

, but after (if it will be fixed) pdf anyway not opening correct.

With that simply patch (and patched freetype2 from https://savannah.nongnu.org/bugs/index.php?44169) pdf be opening correctly and font visible and readable.

Thet bug with buggy pdf exist in MuPDF http://bugs.ghostscript.com/show_bug.cgi?id=695690
Comment 1 Albert Astals Cid 2015-02-03 18:45:58 UTC
Please attach such a pdf file
Comment 2 master_volkov 2015-02-03 18:50:35 UTC
Created attachment 113133 [details]
bug pdf with wrong font
Comment 3 Albert Astals Cid 2015-02-03 19:08:49 UTC
The needed freetype commit has still not happened right? Can you ping us in this bug once freetype can render that font?
Comment 4 master_volkov 2015-02-03 19:17:48 UTC
Yes, ofcourse, but fix in freetype for render font without problem very simple - only 1 string comment and 1 string add. That ready patch attached to bug https://savannah.nongnu.org/bugs/index.php?44169
Comment 5 master_volkov 2015-02-04 10:08:01 UTC
In freetype bug reopened from https://savannah.nongnu.org/bugs/?44169
to whishlist
https://savannah.nongnu.org/bugs/?44184
Comment 6 master_volkov 2015-02-07 17:13:47 UTC
Freetype commit for fix that happened (and bee in 2.6.0 version of reetype):

http://git.savannah.gnu.org/cgit/freetype/freetype2.git/commit/?id=92359bd8851448ba40167affdf5663659a7b28f0

with that patch fonts is visible, but codepage is wrong.
With attached patch for "Fix bug font wrong codepage" all displayed OK.

And if i copy wrong displayed chars and words in clipboard and past to another place - i view readable text.
Comment 7 master_volkov 2015-02-07 17:39:03 UTC
That freetype commit fix problem in mupdf http://bugs.ghostscript.com/show_bug.cgi?id=695690

In poppler font viewed, but displayed codepage wrong.
Comment 8 Albert Astals Cid 2015-02-07 19:47:50 UTC
Pushed


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.