You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "John Hewson (JIRA)" <ji...@apache.org> on 2014/10/10 23:49:34 UTC
[jira] [Closed] (PDFBOX-245) how to write special characters with
PDPageContentStream?
[ https://issues.apache.org/jira/browse/PDFBOX-245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
John Hewson closed PDFBOX-245.
------------------------------
Resolution: Invalid
Closing as this is a "how to" question.
> how to write special characters with PDPageContentStream?
> ---------------------------------------------------------
>
> Key: PDFBOX-245
> URL: https://issues.apache.org/jira/browse/PDFBOX-245
> Project: PDFBox
> Issue Type: Bug
> Components: Writing
> Priority: Minor
>
> [imported from SourceForge]
> http://sourceforge.net/tracker/index.php?group_id=78314&atid=552833&aid=1657444
> Originally submitted by ransacker on 2007-02-11 10:29.
> When using PDPageContentStream.drawString() characters such as é,ë,ï don't get printed or get replaced by another character.
> I assume another encoding must be used?
> Where can the encoding be changed?
> The following code would sound logic to change the encoding but it doesn't seem to work;
> ..
> PDFont font = PDType1Font.TIMES_ROMAN
> font.setEncoding(New encoding.MacRomanEncoding)
> newStream.setFont(font, 8)
> ..
> newStream.drawString("é")
> ..
> An example would be greatly appreciated.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)