I tried using the FontSelector approach but can't see to get the Indic/Arabic 
pdfs to render appropriately. Using the same fonts with the FontMapper works. 
Is this a limitation with FontSelectors or am I missing something?

Thanks,
Priya

--- On Tue, 3/16/10, Priya Mandawat <chotat...@yahoo.com> wrote:

From: Priya Mandawat <chotat...@yahoo.com>
Subject: FontSelector vs FontMapper
To: itext-questions@lists.sourceforge.net
Date: Tuesday, March 16, 2010, 10:05 PM

Hi,  I'm new to iText so please bear with me if this is a dumb question. 
I need to create pdf files in different languages (depending on the user's 
locale). I looked around to see how it's done and I see the following
1. examples using the FontSelector class, inserting fonts in the appropriate 
order and then processing the text to be rendered against it.
2. examples using the FontMapper/DefaultFontMapper to provide the pdf font for 
a given awt font.
My question is: What is the difference between the 2 approaches, or when should 
either be used over the other?
As a follow up, I tried using the latter and was running into problems with 
fetching the dir (that contains the fonts) to be passed to the
 defaultFontMapper.insertDirectory from my jar file. Below is the code snippet:
// The fonts are under "/iText/fonts" in the jarUrl url 
= getClass().getResource("/iText/fonts");
//This yields the url://x-transient://365/iText/fonts, which is invalid
// Hence, this does nothing...defaultFontMapper.insertDirectory(new File(url));
What is the right way to do this?
Help deeply appreciated!
Thanks,Priya







      


      
------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

Buy the iText book: http://www.1t3xt.com/docs/book.php
Check the site with examples before you ask questions: 
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/

Reply via email to