1

I have to generate pdf file using iText in Netbeans IDE. The pdf may contain bangla letter. I already generate pdf file with Bangla letters. But the problem is Bangla letters are not in correct form.

Suppose I have to show: বরিশাল -- But pdf generate: [1]: http://i.stack.imgur.com/abwOV.jpg Suppose I have to show: পড়ি -- But pdf generate: পড় ি

My code to generate this file:

    Document document = new Document();

    BaseFont unicode = BaseFont.createFont("c:/windows/fonts/NikoshBan.ttf", BaseFont.IDENTITY_H, BaseFont.EMBEDDED);
    Font font = new Font(unicode);

    PdfWriter writer=PdfWriter.getInstance(document, new FileOutputStream("TableDat.pdf")); 

    document.open();

    document.add(new Paragraph("বরিশাল",font));

    document.close();
4

0 回答 0