We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

AddFromHtml is not rendering font size nor font family

Hi,
I have Aspose.Slides for .NET 14.4 and I am using AddFromHtml to read html into a PowerPoint table cell. Most formatting is displayed properly (bold, italics, bullets, numbers,font color, and alignment).
I am having issues with the font size and font family. They are not being rendered.
I have attached the sample html file I am using. In there you can see there are span tags with different font sizes and a font family.

This is font size 20 test
This is font size 9 test</span
This is Times New Roman font

I am using PowerPoint 2010.
Thank you very much for your assistance.

Hi Ana,

Thank you for sharing the details.

I am able to reproduce your mentioned issue after an initial test. Your issue has been registered in our issue tracking system with issue id: SLIDESNET-35432. You will be notified via this forum thread once the issue gets resolved.

Thanks & Regards,

/* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-fareast-font-family:"Times New Roman"; mso-fareast-theme-font:minor-fareast; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin;}

<![endif]–>

Owais,

Is there any workaround? Do I need to set the font size or font-family in a different way so the format will be applied in PowerPoint?
Thank you,
Ana

Hi Ana,

As a workaround you can use the tag in html file to apply the formatting in the generated presentation file. You can try following in your HTML file and check if it works fine for you.

<font face="verdana" color="green" size="3">This is font size 3 test

<font color="blue" size="2">This is font size 2 test

<font face="Times New Roman" color="red" size="4"> This is Times New Roman font

Please feel free to contact support in case you need any further assistance.

Thanks & Regards,

/* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-fareast-font-family:"Times New Roman"; mso-fareast-theme-font:minor-fareast; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin;}

<![endif]–>