title: iText PDF Exporter UTF-8 Character Encoding Error
body: <p>I'm facing with character encoding issue while exporting PDF with using iText PDF Library despite I set exporter's <strong>CHARACTER_ENCODING</strong> property to <strong>UTF-8</strong> as I added below : </p>
  
  <pre><code>Class clazz = Class.forName(User.class);
  Document document = new Document();
  PdfWriter.getInstance(document, baos);
  document.open();
  addMetaData(document);
  addDate(document);
  addTitlePage(document, className);
  addEmptyLineToDocument(document, 2);
  addContent(document, className, clazz);
  addEmptyLineToDocument(document, 2);
  addSignature(document);
  return document;
  </code></pre>
  
  <p>Here's the <strong>addContent</strong> method sample:</p>
  
  <pre><code>private static FontFamily fontFamily = FontFamily.TIMES_ROMAN;
  Font fontNormal10 = new Font(fontFamily, 10, Font.NORMAL);
  Paragraph paragraph = new Paragraph();
  Chunk chunk = new Chunk("Here is the list of " + className, fontNormal10);
  paragraph.add(chunk);
  // continues
  </code></pre>
  
  <p>Then I write the document with ServletOutputStream : </p>
  
  <pre><code>// **document** =&gt; which I created and returned above
  document.close();
  response.setHeader("Expires", "0");
  response.setHeader("Cache-Control", "must-revalidate, post-check=0, pre-check=0");
  response.setHeader("Pragma", "public");
  response.setHeader("Content-Disposition", "attachment; filename=" + outputFileName);
  response.setContentType("application/pdf; charset=UTF-8");
  response.setContentLength(baos.size());
  ServletOutputStream outputStream = response.getOutputStream();
  baos.writeTo(outputStream); 
  outputStream.flush();
  outputStream.close();
  </code></pre>
  
  <ul>
  <li>I also added JVM parameter "<strong>file.encoding=UTF-8</strong>" too..</li>
  <li>Set response content type with "<strong>charset=UTF-8;</strong>" property..</li>
  </ul>
  
  <p>Any ideas? Thanks in advance..</p>