Description: In Microsoft Word there is a text frame located margin to margin. In Writer the position of left edge is the same, but the right edge moves to left. The frame fits to content. Steps to Reproduce: 1. Open the attached DOCX file in LibreOffice Writer. 2. Open a copy in Microsoft Word. 3. Compare the original file opened in Writer and Word. 4. View the attached screenshot. 5. Notice, that text frame content appears on the left side of document Actual Results: Text frame content appears on the left side of document when the document is opened in LibreOffice Writer 6.3.0.0.alpha0+. Expected Results: Text frame content should have the same position as the original file when the document is opened in Microsoft Word. Reproducible: Always User Profile Reset: No Additional Info: Version: 6.3.0.0.alpha0+ Build ID: ade1df0948563b532a5d293c31d46a4f042559ee CPU threads: 4; OS: Windows 10.0; UI render: GL; VCL: win; Locale: hu-HU (hu_HU); UI-Language: en-US Calc: threaded LibreOffice 3.5.0rc3 Build ID: 7e68ba2-a744ebf-1f241b7-c506db1-7d53735 Verzió: 4.0.0.3 (Build az.: 7545bee9c2a0782548772a21bc84a9dcc583b89) Verzió: 4.4.7.2 Build az.: f3153a8b245191196a4b6b9abd1d0da16eead600 Területi beállítások: hu_HU Verzió: 5.2.0.4 Build az.: 066b007f5ebcc236395c7d282ba488bca6720265 CPU szálak: 4; Rendszer verziója: Windows 6.2; Felületmegjelenítés: GL; Területi beállítások: hu-HU (hu_HU)
Created attachment 150392 [details] Test file
Created attachment 150393 [details] Screenshot
Thank you for reporting the bug. I can confirm that the bug is present in Version: 6.2.1.2 (x64) Build ID: 7bcb35dc3024a62dea0caee87020152d1ee96e71 CPU threads: 4; OS: Windows 6.3; UI render: default; VCL: win; Locale: en-US (en_US); UI-Language: en-US Calc: CL Version: 6.3.0.0.alpha0+ (x64) Build ID: 91cdf22b88a4f7bec243c8fb187627e766d3294c CPU threads: 4; OS: Windows 6.3; UI render: default; VCL: win; TinderBox: Win-x86_64@42, Branch:master, Time: 2019-03-08_00:38:10 Locale: en-US (en_US); UI-Language: en-US Calc: CL
Still reproducible in Version: 6.4.0.0.alpha1+ Build ID: de4839e66d3d195315729b95cc144cdab96b6e74 CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US Calc: threaded
Looks like the frame here has both its horizontal and vertical size set as automatic, which is imported correctly as seen in the properties dialog. However Writer tries to minimize the horizontal size of the automatic width frame, while Word seems to maximize it.
Created attachment 162557 [details] More exploratory example doc from Word 13 More cases... Auto width is maximized to column width, if the text is multiple paragraphs long or one paragraph that is longer than column width. If the text is 1 paragraph and shorter than column width, then auto width is minimized to the text length. This is shown here with 3, 2 and 1 column sections.
Created attachment 162558 [details] Screenshot of the exploratory document in Word
Attila Szűcs committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/c78221a5ad98939f3fb9ca6af4a2d2d2a63ff6ee tdf#124423 sw: fix AutoSize width frames of DOCX It will be available in 7.1.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Note: it doesn't need to add compatibility option to the UI, because AutoSize width frames created in Writer always exported as fixed width text boxes, i.e. their width don't change in Word.