Unexpected font style and size change

We noticed that compare functionality in Aspose.Words for Java in some cases behaves differently on Linux(Ubuntu) and Windows. Our application in some cases can change font-family capitalization in HTML from “Arial” to “arial” for example.
We then insert HTML fragment into the Document using DocumentBuilder’s insertHTML method.
When invoking compare(Document document, String author, Date dateTime) on the Document object we get different results on different OS:
• Window – case insensitive, no format revisions
• Ubuntu – case sensitive, generates format revisions

Would it be possible to make it behave the same way on Linux platform as far as being case insensitive to the font-family in HTML?

http://joxi.ru/8An55oRTqeQdz2
Looks like according to W3C spec CSS Fonts Module Level 3 the font-family should be supported in case insensitive mode
https://www.w3.org/TR/css-fonts-3/#font-family-casing
see section 5.1 Case sensitivity of font family names

Hi there,


Thanks for your inquiry. We have tested the scenario at Windows 7 and Ubuntu and have not found the shared issue. Please check the attached output documents.

Aspose.Words reads fonts installed on operating system during importing or saving HTML. So, if the fonts are different, the output will be different. Please copy the fonts from Windows to Ubuntu and test the same scenario. Hope this helps you.