pdfbox-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mehdi Houshmand (Updated) (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (PDFBOX-1250) CFF to Type1 Font conversion is missing/corrupting the font metrics
Date Fri, 09 Mar 2012 09:49:58 GMT

     [ https://issues.apache.org/jira/browse/PDFBOX-1250?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Mehdi Houshmand updated PDFBOX-1250:
------------------------------------

    Attachment: pdfbox-type1font.pfb
                example.unc.pdf

The offending PDF and the Type1 font program that FontBox creates
                
> CFF to Type1 Font conversion is missing/corrupting the font metrics
> -------------------------------------------------------------------
>
>                 Key: PDFBOX-1250
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-1250
>             Project: PDFBox
>          Issue Type: Bug
>          Components: FontBox, PDModel
>            Reporter: Mehdi Houshmand
>            Priority: Minor
>         Attachments: example.unc.pdf, pdfbox-type1font.pfb
>
>
> So the problem here is easily reproducible with pretty much ANY CIDFontTypeOC font file
is embedded in a PDF and PDFBox is used to rasterize it, all the glyphs appear to have bad
horizontal metrics.
> Fontbox converts the CID encoded font into a Type1 font using the org.apache.fontbox.cff.Type1FontFormatter
class and for some reason, when it does this, the horizontal metrics of the glyphs are lost/corrupted.
This can clearly be seen by putting a System.out just before the byte[] type1Bytes is given
to Font.createFont in PDType1CFont.java.
> I've included the PDF and the Type1 font that PDFBox gives java.awt.Font, openning the
font in FontForge or painting the text with Graphics2D will easily illustrate this issue.
> We plan on fixing this issue in the imminent future but unfortunately, I don't make the
rules...

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message