Bug 153613 - FILEOPEN DOCX: export puts page break before textbox, instead of after
Summary: FILEOPEN DOCX: export puts page break before textbox, instead of after
Status: REOPENED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
4.3 all versions
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected, filter:docx
Depends on:
Blocks: DOCX-Page
  Show dependency treegraph
 
Reported: 2023-02-14 16:08 UTC by Justin L
Modified: 2023-12-14 12:27 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
form515c.doc: bad round-trip to DOCX (12.50 KB, application/msword)
2023-02-14 16:08 UTC, Justin L
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Justin L 2023-02-14 16:08:15 UTC
Created attachment 185366 [details]
form515c.doc: bad round-trip to DOCX

The floating textbox moved from page 1 to page 2 - with an additional empty paragraph added.

Steps to reproduce
-open form515c.doc and see the textbox on page 1. Three paragraphs in total.
-save as DOCX format and reload. textbox is on page 2, four paragraphs in total.

Although interesting to bibisect (lots of crashes loading or saving to DOCX), in the end all symptioms clearly bisected to LO 4.3
commit a31fbb53dba76736b37213b98b64937f05929a67
Author: Pallavi Jadhav (Synerzip) on Thu Feb 6 13:58:03 2014 +0530
    fdo#74566:DOCX: Preservation <w:br> tag for Break to Next Page
Comment 1 Justin L 2023-02-14 17:23:30 UTC
Actually, this probably should be a FILEOPEN problem. Word 2010 opens the round-tripped DOCX file just fine.

Using the round-tripped DOCX, I rebibisected with a simple fileopen. It didn't import any page breaks in 3.6-4.1.
In 4.2, the page break imported as we see it today,
with commit b40fe8e5a5037d2745cc7b1c9cc408ce6c79b9d9
Author: Miklos Vajna on Tue May 21 14:56:45 2013 +0200
    bnc#818997 RTF import: don't ignore page breaks between shapes
Comment 2 Commit Notification 2023-02-15 19:19:49 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/02444789bb5e59e2582fdb92a5852db9c6471eac

tdf#153613 writerfilter: anchors ignore prior run with page break

It will be available in 7.6.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.
Comment 3 Commit Notification 2023-02-16 20:36:09 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/d0bd19dadbe9d3d676e6ab62f8e9755d060939fe

tdf#153613 writerfilter: RTF pre-emptive tests

It will be available in 7.6.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.
Comment 4 Commit Notification 2023-02-16 20:40:12 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/a9bc19c2d4a35606668aa2dcc53355651b71ee78

tdf#153613 writerfilter: don't always split para for shape w/ pagebreak

It will be available in 7.6.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.
Comment 5 Commit Notification 2023-02-16 20:42:15 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/5884a122dc2a2c73865efdbdd861c281475a681e

tdf#153613 writerfilter: split para for inline too if not FirstRun

It will be available in 7.6.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.
Comment 6 Commit Notification 2023-02-16 23:23:28 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/6515f66372afb4d2e3ec57f9c99be4c3ffb2de84

tdf#153613 DOCX: DID YOU FIX ME? unit test

It will be available in 7.6.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.
Comment 7 Justin L 2023-02-17 18:44:44 UTC
The specific document provided has been fixed. Marking this bug report as closed.

My last commit contains a related example that still is not fixed. It is much more difficult to handle that one. That other document can either be fixed as related to this report, or a new bug report could be created for it.

AFAIK, LO cannot create these kinds of documents, and I expect that a simple round-trip eliminates this edge case, so it is low priority with high complexity - probably not worth worrying about.)
Comment 8 Commit Notification 2023-03-03 15:31:10 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/620d1dc63b652db97b05eb21685dad70e6b2ab0d

tdf#153613 writerfilter: handle defered break before SDT start

It will be available in 7.6.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.
Comment 9 Commit Notification 2023-03-15 01:39:31 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/828fde37632a5bb0542b6925454690a5287d6490

tdf#153613 tdf#146984 writerfilter: split para after anchors

It will be available in 7.6.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.
Comment 10 Commit Notification 2023-10-05 14:26:51 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/32102e559eed6eadf2ea146e212a330a3bc897ca

tdf#157574 Revert "tdf#153613 tdf#146984 split para after anchors"

It will be available in 24.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.
Comment 11 Commit Notification 2023-10-05 19:17:23 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "libreoffice-7-6":

https://git.libreoffice.org/core/commit/06702d8474bdac71fa2a61723ea476e888fc91d6

tdf#157574 Revert "tdf#153613 tdf#146984 split para after anchors"

It will be available in 7.6.3.

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.
Comment 12 Commit Notification 2023-12-13 23:31:51 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/6cd6df7e0d6b0ff8150c9a95a35b17800942026a

tdf#158681 Revert "tdf#153613 writerfilter: don't always split para

It will be available in 24.8.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.
Comment 13 Commit Notification 2023-12-14 01:56:09 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "libreoffice-24-2":

https://git.libreoffice.org/core/commit/de773a115c25c36993f5bb5a463ea5db452b5be5

tdf#158681 Revert "tdf#153613 writerfilter: don't always split para

It will be available in 24.2.0.0.beta2.

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.
Comment 14 Commit Notification 2023-12-14 08:40:58 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "libreoffice-7-6":

https://git.libreoffice.org/core/commit/773029159caf0164885015f6193774cebe898b9c

tdf#158681 Revert "tdf#153613 writerfilter: don't always split para

It will be available in 7.6.5.

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.