Hi,
- Create a new PDF document using Aspose.Net.
- I add text with the following properties to the document:
Hi,
Hi Andrei,
Thanks for using our products.<span style=“font-size:10.0pt;font-family:“Arial”,“sans-serif””>
I
have tested the scenario and have observed that the bold text generated with Aspose.Pdf.Generator namespace is slightly bolder, than the output generated with MS Word. For the
sake of correction, I have logged it in our issue tracking system as <span style=“font-family:“Arial”,“sans-serif””>PDFNEWNET-33927. We
will investigate this issue in details and will keep you updated on the status
of a correction.<span style=“font-size:10.0pt;font-family:“Arial”,“sans-serif””><span style=“font-size:10.0pt;font-family:“Arial”,“sans-serif””>
We
apologize for your inconvenience.<span style=“font-size:10.0pt;font-family:“Arial”,“sans-serif””>
Hi Andrei,
string outFile = “c:/pdftest/33927.pdf”;<o:p></o:p>
Document doc = new Document();
Page page = doc.Pages.Add();
TextState kmcHeader = new TextState();
kmcHeader.Font = FontRepository.FindFont("Arial Narrow");
kmcHeader.FontSize = 12;
kmcHeader.ForegroundColor = System.Drawing.Color.FromArgb(127, 127, 127);
kmcHeader.FontStyle = FontStyles.Bold;
TextFragment kmcText = new TextFragment("Compensation");
kmcText.Segments[1].TextState = kmcHeader;
page.Paragraphs.Add(kmcText);
doc.Save(outFile);
The issues you have found earlier (filed as PDFNEWNET-33927) have been fixed in Aspose.Pdf for .NET 7.7.0.