pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Malcolm Vincent <malcolmvinc...@gmail.com>
Subject Font encoding when adding text
Date Thu, 15 Feb 2018 08:27:54 GMT
Hi,

Is there anything special you need to be aware of when using
PDFont.encode(unicode-string)

I have a PDF with a font resource and when adding to an existing PDF
PDFont.encode("unicode string") seems to be throwing a character not found
exception.

Exception 'U+041E ('Ocyrillic') is not available in this font's encoding:
WinAnsiEncoding with differences' : MyriadPro-Light

But when I look at the font in the debugger I can see

code 18
glyphname "afii10032"
unicode character "O"
glyph "O"

and I verified that O by hex'ing it and I get D0 9E which is unicode for
U+041E

Any help would be appreciated!

Cheers
Malcolm

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message