There's a bug with TT symbol fonts and Identity-H. Use "Cp1252" instead of
BaseFont.IDENTITY_H.

Best Regards,
Paulo Soares

> -----Original Message-----
> From: Thorsten Sch�fer [SMTP:[EMAIL PROTECTED]
> Sent: Friday, June 06, 2003 13:42
> To:   [EMAIL PROTECTED]
> Subject:      [iText-questions] Problem adding a font to a PDF
> 
> Hi,
> 
> I want to add three fonts to my PDF: Arial, Arial bold and Webdings. It
> works for the first two of them but not for webdings! All three font
> files are in the classpath. I also tried to use a full path (c:\...) but
> this also didn't work. Any ideas on that problem?
> 
> Thanks in advance,
> 
> Thorsten
> 
> <code>
> BaseFont font = BaseFont.createFont("arial.ttf", BaseFont.IDENTITY_H,
> BaseFont.EMBEDDED);
> BaseFont fontBold = BaseFont.createFont("arialbd.ttf",
> BaseFont.IDENTITY_H, BaseFont.EMBEDDED);
> // These 2 works
> BaseFont fontSymols = BaseFont.createFont("webdings.ttf",
> BaseFont.IDENTITY_H, BaseFont.EMBEDDED);
> 
> // This call throws the following exception:
> com.lowagie.text.DocumentException: PDF
>         at com.lowagie.text.pdf.TrueTypeFontUnicode.<init>(Unknown
> Source)
>         at com.lowagie.text.pdf.BaseFont.createFont(Unknown Source)
>         at com.lowagie.text.pdf.BaseFont.createFont(Unknown Source)
> 
> </code>
> 
> 
> 
> -------------------------------------------------------
> This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
> thread debugger on the planet. Designed with thread debugging features
> you've never dreamed of, try TotalView 6 free at www.etnus.com.
> _______________________________________________
> iText-questions mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/itext-questions


-------------------------------------------------------
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to