ASPOSE.Words HTML Image not sized appropriately when saved to Doc

When specifying only the width or only the height of an image in HTML it is not maintaining the aspect ratio.

E.g.

Assuming SomeImage.jpg has a width of 100px and a height of 100px.

1) shows an image with a width of 50px and a height of 100px (no aspect ratio maintained as it is in HTML)

2) Same results. Read a post that states to leave the px off.

I first started with CSS and that didnt work either. Tried this after reading the FAQ regarding CSS support.

Please advise.

Regards,

Tom

Hi Tom,


Thanks for your inquiry. Aspose.Words’ HTML engine tries to mimic the way the Microsoft Word works. To you, this means that if you convert HTML file into a Microsoft Word document or PDF using Aspose.Words, the output will appear almost exactly as if it was done by Microsoft Word. In your case, it is the expected behavior as Microsoft Word does not maintain the aspect ratio too. If we can help you with anything else, please feel free to ask.

Best regards,