Please could me anyone say, if when i draw a string with the XTextFormatter the not solid underline is intended or a bug?
I use the Version "1.32" and the PdfSharp-WPF assembly.
Look at the Image to see the Problem.
Code:
PdfDocument pdfDocument = new PdfDocument();
PdfPage newPdfPage = pdfDocument.AddPage();
newPdfPage.Size = PdfSharp.PageSize.A4;
newPdfPage.Orientation = PdfSharp.PageOrientation.Portrait;
XGraphics newGfx = XGraphics.FromPdfPage(newPdfPage, XGraphicsUnit.Point);
newGfx.ScaleTransform(72.0 / 96, 72.0 / 96);
newGfx.TranslateTransform(94, 173);
newGfx.MFEH = PdfFontEmbedding.Automatic;
XTextFormatter formatter = new XTextFormatter(newGfx);
XRect rec = new XRect(0, 0, 500, 100);
formatter.Alignment = XParagraphAlignment.Right;
XFont newFont = new XFont("Arial", Utility.ConvertPointsToPixels(20), XFontStyle.Bold | XFontStyle.Underline);
formatter.DrawString("THAT IS A TEST!", newFont, XBrushes.Black, rec);
pdfDocument.Save("C:\\NewTestPDF.pdf");