Bug 122628

Summary: FILEOPEN DOCX: custom document information field adds extra CR's before filling in the relevant data (comment 9)
Product: LibreOffice Reporter: Cor Nouws <cno>
Component: WriterAssignee: Not Assigned <libreoffice-bugs>
Status: NEW ---    
Severity: normal CC: cno, libreoffice, nemeth, telesto, xiscofauli
Priority: medium Keywords: filter:docx
Version: unspecified   
Hardware: All   
OS: All   
See Also: https://bugs.documentfoundation.org/show_bug.cgi?id=123622
https://bugs.documentfoundation.org/show_bug.cgi?id=103206
https://bugs.documentfoundation.org/show_bug.cgi?id=68335
Whiteboard: interoperability
Crash report or crash signature: Regression By:
Bug Depends on:    
Bug Blocks: 107830, 112969    
Attachments: docx file with frames in header that open with wrong wrapping
screen print of original file in Word
screen print of original file in master 63
screen print of original file in LO 4062
screen print of original file in LO 3304
screen print of improved file in master 63
finaly the improved file, saved as docx in master 63
Minimized document with problematic text box containing document field
Screenshot of the minimized document in Word and Writer
Even more minimal sample only with the custom field

Description Cor Nouws 2019-01-10 10:50:06 UTC
Created attachment 148204 [details]
docx file with frames in header that open with wrong wrapping

Attached a DOCX with three frames in the header, that in LibreOffice mix with the content of the letter.
The frames are opened with wrapping In Background. If you change that to wrapping Off, the document in displayed excellent.

Then also saving in LibreOffice as docx and opening again, works good.

First noticed in master 63.
But this has never worked in LibreOffice.
Comparing with e.g. 4062 and 3304, we can even notice great improvements.

Will attach a screen shot from Word and some more too.
Comment 1 Cor Nouws 2019-01-10 10:51:28 UTC
Created attachment 148205 [details]
screen print of original file in Word
Comment 2 Cor Nouws 2019-01-10 10:51:59 UTC
Created attachment 148206 [details]
screen print of original file in master 63
Comment 3 Cor Nouws 2019-01-10 10:52:33 UTC
Created attachment 148207 [details]
screen print of original file in LO 4062
Comment 4 Cor Nouws 2019-01-10 10:53:04 UTC
Created attachment 148208 [details]
screen print of original file in LO 3304
Comment 5 Cor Nouws 2019-01-10 10:53:49 UTC
Created attachment 148209 [details]
screen print of improved file in master 63
Comment 6 Cor Nouws 2019-01-10 10:54:23 UTC
Created attachment 148210 [details]
finaly the improved file, saved as docx in master 63
Comment 7 Xisco FaulĂ­ 2019-02-12 17:02:52 UTC
Reproduced in

Version: 6.2.0.0.alpha1+
Build ID: a20a2d7e0d28658f2d9089da076961a599833a28
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
Comment 8 Xisco FaulĂ­ 2020-03-25 15:51:36 UTC
*** Bug 131574 has been marked as a duplicate of this bug. ***
Comment 9 NISZ LibreOffice Team 2020-05-18 15:27:18 UTC
Created attachment 160981 [details]
Minimized document with problematic text box containing document field

Minimized document shows two general problems:

- The paragraph in the header has a huge, 13 cm (361 pt) Spacing after value set to make vertical room for the textboxes. Writer seems to have (since 3.5 times) a limit on the spacing after value which is 10 cm (283 pt). This is the main reason why the header slips into the document body.

- Another problem is that the text box left in this file contains a custom document information field ("Aan") which is imported with three empty preceding paragraphs that were not present in Word. I made this more obvious by adding a random D at the beginning of the text box and a random Z at the end of it.
Comment 10 NISZ LibreOffice Team 2020-05-18 15:28:07 UTC
Created attachment 160982 [details]
Screenshot of the minimized document in Word and Writer

Version: 7.0.0.0.alpha1+ (x64)
Build ID: 557c6777ad33b54af28541a96bcf91596995b388
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: default; VCL: win; 
Locale: hu-HU (hu_HU); UI: en-US
Calc: CL
Comment 11 NISZ LibreOffice Team 2020-05-18 15:30:06 UTC
This also has no frame objects to begin with, changing meta bug accordingly.
Comment 12 Justin L 2020-08-12 12:59:10 UTC
The overlapping part is fixed in 6.4.6 because of bug 128195.

As per emulation, anything anchored in a header/footer is considered "in background" in case it spills over into the body section. (see bug 135595)

(In reply to NISZ LibreOffice Team from comment #9)
> - Another problem is that the text box left in this file contains a custom
> document information field ("Aan") which is imported with three empty
> preceding paragraphs that were not present in Word.
So I guess we'll leave the issue open to focus on this part.
Comment 13 NISZ LibreOffice Team 2020-11-10 08:33:09 UTC
Created attachment 167162 [details]
Even more minimal sample only with the custom field

Even more simplified, only the custom field in this one. Bad ever since:

LibreOffice 3.5.0rc3 
Build ID: 7e68ba2-a744ebf-1f241b7-c506db1-7d53735
Comment 14 QA Administrators 2022-11-11 03:56:23 UTC Comment hidden (spam)