title: PDF Sharp setting font styles
body: <p>I have a font dialog to let user pick a font name, font size and also possibly a font style.</p>
  
  <p>but this code doesn't work </p>
  
  <pre><code>XFont myFont = new XFont(txtP.Font.Name, txtP.Font.Size, txtP.Font.Style);
  </code></pre>
  
  <blockquote>
    <p>Error is: Error   2   Argument 3: cannot convert from
    'System.Drawing.FontStyle' to 'PdfSharp.Drawing.XFontStyle' /
    Error 1   The best overloaded method match for
    'PdfSharp.Drawing.XFont.XFont(string, double,
    PdfSharp.Drawing.XFontStyle)' has some invalid arguments</p>
  </blockquote>
  
  <p>is there a workaround on this? I would really like to let users choose Font Style also not just name and size.</p>