Description: We are considering LO as a MS Word replacement and checking out the reproduction of existing DOCX documents. When opening a docx with a text frame the first paragraph of the frame gets a "Spacing / Abwove paragraph" of 0,42 cm whereas the source document in MS Word has not (0 pt). I have attached a minimal anonymized document that is quite similiar to the source document for the sake of reproduction in a ask.libreoffice.org-question https://ask.libreoffice.org/en/question/254942/paragraph-spacing-differs-when-opening-docx/ You can easily see the difference in the options of the two programs in the attached screenshot too. Steps to Reproduce: Open attached document Actual Results: Paragraph spacing is set to a value non zero Expected Results: Paragraph spacing is set to a zero Reproducible: Always User Profile Reset: No Additional Info: Sest paragraph spacing to zero as in input file
Reproduced with Version: 7.0.0.1 (x64) Build ID: 04ba7e3f1e51af6c5d653e543a620e36719083fd CPU threads: 12; OS: Windows 10.0 Build 18363; UI render: Skia/Raster; VCL: win Locale: ru-RU (ru_RU); UI: en-US Calc: CL
Created attachment 162978 [details] Test document for tdf#134784 Attaching to have it here
Created attachment 162979 [details] Screenshot for tdf#134784
This has been answered on ask.libreoffice.org. The problem stemmed from formatting issues in the source document and could be overcome by already-in-place configurable compatibility mechanisms.
Can be closed imho
(In reply to rominator from comment #5) > Can be closed imho No, a workaround is not a fix :-)
Confirming with: Verzió: 6.2.0.3 Build az.: 98c6a8a1c6c7b144ce3cc729e34964b47ce25d62 CPU szálak: 4; OS: Windows 6.3; Felületmegjelenítés: GL; VCL: win; Területi beállítások: hu-HU (hu_HU); UI nyelve: hu-HU Calc: threaded But not yet in: Version: 6.1.0.3 Build ID: efb621ed25068d70781dc026f7e9c5187a4decd1 CPU threads: 4; OS: Windows 6.3; UI render: default; Locale: en-US (hu_HU); Calc: CL
Bibisected using bibisect-win32-6.2 to: https://cgit.freedesktop.org/libreoffice/core/commit/?id=dc0300eac3b755bc207cd1fe87217f4ebaeb9f58 author László Németh <nemeth@numbertext.org> 2018-07-17 19:46:22 +0200 committer László Németh <nemeth@numbertext.org> 2018-07-18 08:55:01 +0200 tdf#118521 DOCX import: fix paragraph margin from paragraph style Adding CC to: László Németh
I am not really getting the deal here. Should I use the compatibility settings or expect writer to import the DOCX so that it looks like the MS Word thing? I am asking this because I am now using 6.3.6.2 (which you say has a problem since this commit 2018) and an UNCHECKED compatibility setting "Add paragraph and table spacings at tops of pages". This settinng unfortunately leads to other problems in this document (and this version) like the title of the document (title-style) being positioned falsely, and other paragraph spacing issues that I came around later. I could attach some files for this issues too but I would first need to know what the intentions of the compatibility settings and the DOCX import are and how I should be testing this.
(In reply to rominator from comment #9) > I am not really getting the deal here. Should I use the compatibility > settings or expect writer to import the DOCX so that it looks like the MS > Word thing? As I said in comment 6: a workaround is *not* a fix. This is a bug, and needs fixing. You may see that the bug has been investigated, it was found out when and why has it appeared (so it's a regression), and a developer has assigned it to himself (so you know that László is working on it). Compatibility settings are set *automatically* when you open a file type that needs those settings. E.g., Writer and Word use different conventions how to calculate tab offsets; it would be impossible to interoperate if LibreOffice didn't introduce a compatibility option "behave like Word for tabs", and didn't enable it automatically every time it opens a DOC(X). So the enabled compatibility option is the *correct* thing for DOCX; disabling it *naturally* results in interoperability problems. And so it's just a workaround to temporary avoid the *bug* in the option's effect.
Thank you very much for the clarification on how the compatibility settings work! This means of course that I should update the correct answer at ask.libreoffice.org. I am looking forward to getting the fixed version by László so that we can check other documents of our customers for compatibility issues with this fix! We have been working with MS Word for over a decade and are now checking out writer mainly for PDF conversion of documents.
László Németh committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/c04ee66c7cfeb725d637b0f9ec3e3b1f8776bfe9 tdf#134784 DOCX import: fix shape paragraph margins 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.
tdf#134784 DOCX import: fix shape paragraph margins based on bad style inheritance. Regression from commit dc0300eac3b755bc207cd1fe87217f4ebaeb9f58 (tdf#118521 DOCX import: fix paragraph margin from paragraph style), revealing the problematic m_sCurrentParaStyleName, see also https://cgit.freedesktop.org/libreoffice/core/commit/?id=8920d865ee148518bf71f71ce1866b24cc17c07e) for more information.
Verified in Version: 7.1.0.0.alpha0+ Build ID: cd85546a2fbdade42f80fd3b6bd650791db9f32d CPU threads: 4; OS: Linux 5.7; UI render: default; VCL: gtk3 Locale: tr-TR (en_US.UTF-8); UI: en-US Calc: threaded @László Németh, thanks for fixing this issue!
László Németh committed a patch related to this issue. It has been pushed to "libreoffice-7-0": https://git.libreoffice.org/core/commit/2f40b190b22213a80aa11021f69619f1b72838be tdf#134784 DOCX import: fix shape paragraph margins It will be available in 7.0.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.
Verified in: Version: 7.1.0.0.alpha0+ (x64) Build ID: a3b4831208da615789bd1e2d5660dd130807f504 CPU threads: 4; OS: Windows 10.0 Build 17134; UI render: Skia/Raster; VCL: win Locale: hu-HU (hu_HU); UI: hu-HU Calc: threaded Thanks, László :)
Hi, thanks for the fix! I will also check that out from an end-user perspective. Kind reagards, Roman