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

# Images coming out of the containing div

hi,

In some word files, the html that is returned has images coming out of the containing div while most images are contained inside.

Versions used :
aspose-words 18.7-jdk16
aspose-pdf 10.4.0

PFA the sample document having this issue:

Aspose - Sample document - dummy.docx (944.3 KB)

Thanks

@rabinintig The shapes that goes out of the left edge have negative horizontal position. In the source MS Word document they goes outsize left page margin too. So in this case you have encountered the expected behavior. By the way MS Word also shifts the shapes outsized the visible area if save your document to HTML.
If you need to preserve MS Word document layout in HTML, you can try using SaveFormat.HTML_FIXED. In this case, Aspose.Words produces HTML with fixed position of all elements and the output document looks exactly the same as if you save it to PDF or XPS:

Document doc = new Document("C:\\Temp\\in.docx");
doc.save("C:\\Temp\\out.html", SaveFormat.HTML_FIXED);