[ https://issues.apache.org/jira/browse/PDFBOX-1408?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Juraj Lonc updated PDFBOX-1408: ------------------------------- Attachment: makcene-export.pdf Attached file contains font with ToUnicode mapping. That results to wrong calculation of space width. > Width of space character is calculated wrong > -------------------------------------------- > > Key: PDFBOX-1408 > URL: https://issues.apache.org/jira/browse/PDFBOX-1408 > Project: PDFBox > Issue Type: Bug > Reporter: Juraj Lonc > Attachments: makcene-export.pdf > > > PDFStreamEngine calculates width of space (line 357): > spaceWidthText = (font.getFontWidth( SPACE_BYTES, 0, 1 > )*glyphSpaceToTextSpaceFactor); > In some cases the result is 0. > Problem is that getFontWidth requires code number of " ". > If there is "ToUnicode" mapping for that font that it is necessary to lookup > CMap for code number and NOT to use 0x20 (space) as it is in souce code. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira