Description: FILEOPEN DOCX: Image partly off page on file open Steps to Reproduce: 1. Open the attached file 2. Save to DOCX 3. File reload Actual Results: Image moves to top of the page Expected Results: The old situation wasn't perfect (1-1 with ODT), but surely better compared to current Reproducible: Always User Profile Reset: No Additional Info: Found in Version: 7.2.0.0.alpha1+ (x64) / LibreOffice Community Build ID: 239b4bb27fd8db26e8416045b3015688a8b1b0ae CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win Locale: nl-NL (nl_NL); UI: en-US Calc: CL not in Version: 7.1.0.0.beta1+ (x64) Build ID: f9fab4203c1aa0b9a3f27ce2713b6d5addc7df19 CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: default; VCL: win Locale: nl-NL (nl_NL); UI: nl-NL Calc: CL
Telesto, you forgot attach the file, please do it
Created attachment 172889 [details] Example file
(In reply to Roman Kuznetsov from comment #1) > Telesto, you forgot attach the file, please do it Sorry.. thanks for the quick reminder
Created attachment 172918 [details] Bibisectlog Bisected to: author Miklos Vajna <vmiklos@collabora.com> 2021-05-26 11:56:04 +0200 committer Miklos Vajna <vmiklos@collabora.com> 2021-05-26 13:29:12 +0200 commit 2f21e4f357ec60450df84ddd858c3cf0a4711b02 (patch) tree e422784a36b1f34ef25b1d42738e8c8119db2caa parent 9ac3b599e65669380ab346cb2bb135a6edc3273a (diff) tdf#139915 DOCX import: fix anchored obj position with to-char and TEXT_LINE There were multiple problems here: - commit 8f1a1092d47947847e1d888b0284e8364c663d1f (tdf#97371 DOCX import: fix text covered by shape, 2016-01-28) disabled to-char anchoring for TEXT_LINE (e.g. "alignment top, relative to line") because changing the anchor type of a TextBox could not be changed, but this has been implemented in sw/ in the meantime, so it can be dropped - Now that the anchor type is to-char, we can set the vertical relation to TEXT_LINE, but Word's positive value is "below line", and ours mean "towards the top of the page, from the bottom of the line", so we need to drop the workaround of commit 3303a4c5f21874453e634d84408c50e7a0055a4d (tdf#135153 DOCX import: avoid line-of-text relation with to-para anchoring, 2021-01-18) Once these are in place, we can fix the remaining problem by inverting the vertical position of the shape, which instantly fixes the overlapping textboxes in the bugdoc. https://cgit.freedesktop.org/libreoffice/core/commit/?id=2f21e4f357ec60450df84ddd858c3cf0a4711b02
@NISZ As this might be related to bug 117692
This is mostly the same as bug #142855 Here the caption frame has the captioned image in it, in bug #142855 that was removed. But the vertical alignment is incorrectly read back as Top to line instead of Bottom to line. Funny thing is that even in Word the shape appears above the very first paragraph, juts like in Writer, but with the vertical alignment read correctly as below line. There is also something else, that I don't see yet. Even if I manually change the vertical alignment the result is not the same as before: Originally the frame is below paragraph A.1. but after changing the vertical alignment to below line it appears above A.1. Let's keep this one open about this latter mystery.
Created attachment 172931 [details] The original document and its docx version in Writer
Created attachment 172932 [details] The original document and its docx version in Word
Created attachment 172933 [details] Docx version of the original document Version: 7.2.0.0.alpha1+ (x64) / LibreOffice Community Build ID: 93a3e2f86c27b06062708fe788963a0e49f3a90b CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: default; VCL: win Locale: en-US (hu_HU); UI: en-US Calc: CL
This is basically an INVALID bug report. The caption frame is vertically anchored to the BOTTOM of the paragraph area. DOCX doesn't have such strange choices. If you change the ODT to anchor to the TOP, then everything works as expected.
*** Bug 142855 has been marked as a duplicate of this bug. ***