Hi everyone,
I'm a relative newbie so forgive me if this question has been asked before. I want my application to generate a pdf that uses a TTF font, and looking at the example docs I would do something like this:
BaseFont bfComic = BaseFont.createFont("c:\\windows\\fonts\\comicbd.ttf", BaseFont.CP1252, BaseFont.NOT_EMBEDDED);
Font font = new Font(bfComic, 12);
This is all well and good on Windows, but my application is supposed to work on other platforms (ie. Linux, OS X). What I've tried so far is to copy the font I want to use into my application directory so that I don't need to include the absolute path to the font. Is this the best way to do this? Can I stick the font in a jar file? Any insights on how people handle this situation would be appreciated.
Thanks,
Chris
- [iText-questions] Font best practices Chris Fong
