You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Jacky Yang (JIRA)" <ji...@apache.org> on 2009/11/04 01:55:32 UTC

[jira] Commented: (PDFBOX-553) writing pdf file in Japanese, garbled

    [ https://issues.apache.org/jira/browse/PDFBOX-553?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12773316#action_12773316 ] 

Jacky Yang commented on PDFBOX-553:
-----------------------------------

i use PdfBox to write pdf file in Japanese.The code like this:
------------------------------------------------------------------
....
String file = "../helloFont.pdf";
String fontfile = "../ttf/MSMINCHO.TTF";
PDFont font = PDTrueTypeFont.loadTTF(doc, fontfile);
PDPageContentStream contentStream = new PDPageContentStream(doc,page);
contentStream.beginText();
contentStream.setFont(font, 12);
contentStream.moveTextPositionByAmount(100, 700);
contentStream.drawString("日本語だよ");
contentStream.endText();
contentStream.close();
doc.save(file);
....
------------------------------------------------------------------
generated pdf file is garbled.Please help me.Thanks. 


> writing pdf file in Japanese, garbled
> -------------------------------------
>
>                 Key: PDFBOX-553
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-553
>             Project: PDFBox
>          Issue Type: Bug
>          Components: PDModel
>    Affects Versions: 0.8.0-incubator
>         Environment: windows server2003
>            Reporter: Jacky Yang
>            Priority: Critical
>             Fix For: 1.0.0
>
>   Original Estimate: 240h
>  Remaining Estimate: 240h
>
> use PdfBox to write pdf file in Japanese,generated file is garbled.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.