KurtCode/PDFKitten — Issue #13: Problem with determining special characters width
Author: slitskevich
Created: 2011-12-02 08:54:13+00:00
State: open

I've got a problem with some special characters, e.g. ™ or even ". The Type 1 font Widths array doesn't have a value for them. Their width is considered to be 0 in Scanner's didScanCharacter. As a result the text matrix is not properly transformed and selections found in the line after the character have wrong transformation and are not properly highlighted.

I noticed that the characters are not properly processed by CGPDFStringCopyTextString and CGPDFStringGetBytePtr either.
I tried to read font program stored in the font description under FontFile3 but i don't know how to process the stream.

Do you have an idea where in the pdf can i retrieve the information about corresponding glyphs?
I'd really appreciate any help!