0

I am creating a Rich Text Format (RTF) document using a very old version of iText. I have to use Arial & Rockwell fonts, when I use and test these fonts within local server environment it works fine. But after deployment to Dev or Prod server environments, these font changes are not picking.

I tried to use font using following methods, but none is working.

  1. Reference local windows font using absolute path (C:\windows\fonts\arial.ttf).
  2. Copied the font in resource folder(Where other resource like images resides) and embed them to use in document creation.

Please help me out as this problem is driving me crazy.

Bruno Lowagie
  • 75,994
  • 9
  • 109
  • 165
Gaurav
  • 1
  • 1
  • RTF creation has been discontinued in iText since December 2009. You must be using a very old version. I don't know anyone who uses iText to create RTF anymore. This also means that I don't know anyone who supports the creating of RTF using iText anymore. By the way: an RTF document isn't the same as a Word document. As far as I know, fonts aren't embedded in an RTF file. If you can embed fonts in RTF, I know for sure that it was never supported in iText. – Bruno Lowagie May 17 '16 at 13:45
  • @BrunoLowagie Thank you so much for explaining. As I have already gone through iText tutorials related to font and did exactly same, but couldn't solve the issue. And yes my iText version is very old(1.3xx). Is there any other way through I can do things differently. Appreciate your help. – Gaurav May 17 '16 at 13:52
  • When you open your RTF file generated on Prod in a text editor and look at the actual RTF code do you see the words "Rockwell" and "Arial"? – Chris Haas May 18 '16 at 17:48

0 Answers0