title: Setting styles for embedded fonts in jsPDF
body: <p>i have an issue with generating pdfs in regards to embedding fonts. I just used</p>
  <pre><code>pdf.addFileToVFS('Acme-Regular-italic.ttf', fontBase64Data);
  pdf.addFont('Acme-Regular-italic.ttf', 'Acme', 'italic');
  pdf.setFont(&quot;Acme&quot;, 'italic');
  pdf.text(&quot;italic Acme&quot;, 10, 10);
  
  pdf.addFileToVFS('Acme-Regular.ttf', fontBase64Data);
  pdf.addFont('Acme-Regular.ttf', 'Acme', 'normal');
  pdf.setFont(&quot;Acme&quot;, 'normal');
  pdf.text(&quot;regular Acme&quot;, 10, 40);
  
  pdf.addFileToVFS('Acme-Regular-bold.ttf', fontBase64Data);
  pdf.addFont('Acme-Regular-bold.ttf', 'Acme', 'bold');
  pdf.setFont(&quot;Acme&quot;, 'bold');
  pdf.text(&quot;bold Acme&quot;, 10, 70);
  </code></pre>
  <p>where fontBase64Data is always the Acme.ttf encodes as base64</p>
  <p>and the font i see for the three variants is always the same!? So I wonder what I am missing. Do I need to pass different base64 encodingds (one for regular, one for bold...) - whcih I don't have? If so where can I get those?</p>
  <p>Here the result i get as screenshot from pdf:
  <a href="https://i.stack.imgur.com/rCKiX.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/rCKiX.png" alt="enter image description here" /></a></p>
  <p>Cheers
  Tom</p>