Hello. I’m trying to output some html to a pdf and am having problems formatting the font size. I have tried both approaches bellow (using Aspose’s functions and using html), but in either case the text in the pdf just shows up at its default size. I’m using Aspose pdf 10.5.0.0. Am I missing something obvious? Thanks for any help you can give me!
Aspose.Pdf.Generator.Pdf pdf1 = new Pdf();
Aspose.Pdf.Generator.Section sec1 = pdf.Sections.Add();
string htmlString = " test string ";
Aspose.Pdf.Generator.Text text1 = new Aspose.Pdf.Generator.Text(sec1, htmlString);
Aspose.Pdf.Generator.TextInfo textInfo1 = new Aspose.Pdf.Generator.TextInfo();
textInfo1.FontSize = 4;
text1.TextInfo = textInfo1;
text1.IsHtmlTagSupported = true;
sec1.Paragraphs.Add(text1);
-------------------------------------------------------------------------
Aspose.Pdf.Generator.Pdf pdf1 = new Pdf();
Aspose.Pdf.Generator.Section sec1 = pdf.Sections.Add();
string htmlString = " <font size = “4”>test string ";
text1.IsHtmlTagSupported = true;
sec1.Paragraphs.Add(text1);