Created attachment 195536 [details] 160077_layoutInCell_horiRight.docx: looks OK in LO, even when round-tripped, but RT is bad in MS Word In 7.3.1, the code was changed to ignore LayoutInCell when through wrapping was combined with a horizontal paragraph orientation. However, this ignores vertical implications (kindof fixed in bug 160077) and round-tripping (from a MSO perspective). commit e993638d5ecd33783f2eebdccfa87a81e5a8a2c5 Author: Miklos Vajna on Mon Jan 24 12:53:25 2022 +0100 DOCX import: fix <wp:anchor layoutInCell="1"> with <wp:wrapNone> Although it is super tempting to turn layoutInCell off, this is the opposite direction that MSO is going. In CompatibilityMode=15, MSO ignores the value of layoutInCell and always treats it as "on".
Created attachment 195539 [details] 160077_layoutInCell_horiRightRT.docx: round-tripped by 25.2 master Opening this file in MS Word (I tried 2010 and 2019), the image shifts into the right column (since it is trying to align with the right side of the overall containing paragraph). It is also interesting to note that when going to the layout properties in MS Word, it SAYS that the shape is vertically aligned to the top of the page, and when you press OK, it does jump to the top of the page. So, using this comment's file, there are two additional bugs: 1.) IMPORT: layout of compat14 layoutInCell=off needs to be based on the "anchor" paragraph probably, not the cell paragraph that actually contains the shape. 2.) EXPORT: I assume there is some kind of invalid combination on exporting the vertial position, which MS Word honours, but then tries to change via the dialog. Both of these bugs are exposed by comment 0's IMPORT turning off layoutInCell.
Created attachment 195540 [details] 160077_layoutInCell_horiRightRT_mso2019.pdf: how comment 1's round-tripped file looks in Word 2019
Created attachment 195592 [details] tdf128646C.docx: argh - this unit test destroyed one of my critical suppositions
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/ce0429edab26e961c73af2d4bdf1516cca05205b tdf#162211 layoutInCell: clean-up unit tests and make some pre-emptive It will be available in 25.2.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.
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/2c9f8ad2705834cdbe208373e10a0daad1040fd2 tdf#162211 revert "tdf#160077 writerfilter: shape vertRelation is FRAME It will be available in 25.2.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.
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/31f87f369fdb40fc746d98443d75af2e9ce2452d tdf#162211 tdf#160077 tdf#91632 layoutInCell: vert page->margin, *->top It will be available in 25.2.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.
Justin Luth committed a patch related to this issue. It has been pushed to "libreoffice-24-8": https://git.libreoffice.org/core/commit/017fe82d7c057c9a41d558ddfbb5c598c8e1998b tdf#162211 revert "tdf#160077 writerfilter: shape vertRelation is FRAME It will be available in 24.8.1. 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.
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/a4418c907fb40707f07a5794dd07a93e51140636 tdf#162211 tdf#137590 layoutInCell: vertical escaping with wrapThrough It will be available in 25.2.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.
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/da249b2c386f0e16a0e63e38ec363c4a5ffd8fdb tdf#162211 writerfilter: don't discard layoutInCell It will be available in 25.2.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.
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/0c2d2ca64f796b3f3f0bc8a8d123aa1be99414f1 tdf#162211 tdf#158384 layoutInCell: doTextBoxPositioning better It will be available in 25.2.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.
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/10bc43d6885a38ca4cccaf201df33ebea64736c3 tdf#162211 tdf#160077 layoutInCell: use row margin for MSOLayout It will be available in 25.2.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.
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/7144a9c791ab587b4621c2b35611ba2020baab58 tdf#162211 tdf#153909 layoutInCell vml: don't discard layoutInCell It will be available in 25.2.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.