Bug 134621 - FILEOPEN: DOCX: pTab alignment of center and right have no corresponding equivalent in LO
Summary: FILEOPEN: DOCX: pTab alignment of center and right have no corresponding equi...
Status: RESOLVED DUPLICATE of bug 78144
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: low minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected
Depends on:
Blocks: DOC-Images
  Show dependency treegraph
 
Reported: 2020-07-07 16:06 UTC by Xisco Faulí
Modified: 2023-05-25 10:46 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
sample file (72.18 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2020-07-07 16:06 UTC, Xisco Faulí
Details
Comparison before and after RT in MSO (528.66 KB, image/png)
2020-07-07 16:07 UTC, Xisco Faulí
Details
Screenshot of the example file saved to doc format in 6.3dev in Word (70.39 KB, image/png)
2020-07-13 15:34 UTC, NISZ LibreOffice Team
Details
sample compared in LO and MSO (239.65 KB, image/jpeg)
2021-08-19 10:11 UTC, Timur
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Xisco Faulí 2020-07-07 16:06:03 UTC
Created attachment 162762 [details]
sample file

Steps to reproduce:
1. Open attached document
2. Save it as DOC file
3. Open the new generated file in MSO ( I'm using MSO 2010 )

-> Image 'Base Mark' is no in the header

Reproduced in

Version: 7.1.0.0.alpha0+
Build ID: 9af38b4504ccda57a0c32eb8bdd03e5a8ca29ddc
CPU threads: 4; OS: Linux 4.19; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded

[Bug found by office-interoperability-tools]
Comment 1 Xisco Faulí 2020-07-07 16:07:14 UTC
Created attachment 162763 [details]
Comparison before and after RT in MSO
Comment 2 Xisco Faulí 2020-07-07 16:08:24 UTC
Regression introduced by:

https://cgit.freedesktop.org/libreoffice/core/commit/?id=82f7252b143ed18ac517b4261726d094f136047d

author	László Németh <nemeth@numbertext.org>	2019-11-22 09:26:14 +0100
committer	László Németh <nemeth@numbertext.org>	2019-11-22 14:59:19 +0100
commit 82f7252b143ed18ac517b4261726d094f136047d (patch)
tree ac5159441522954959729f65f644042585526482
parent 122468bf97f1ea456274991103a13489b8d5df58 (diff)
tdf#128499 DOC export: fix lost ToC formatting regression

Bisected with: bibisect-linux64-7.0

Adding Cc: to László Németh
Comment 3 NISZ LibreOffice Team 2020-07-10 10:41:56 UTC
Before that change the first header paragraphs tabulator settings were not saved, after it they are. Manually adding the tabulator positions to the old doc export in Word creates the same layout with the image outflowing.

Since there are two tab positions at 8.5 cm and 17 cm but four tab characters, these are now positioned correctly. But unlike in docx, in doc these excessive tabs can not break to multiple lines, which makes the image in the docx appear and in doc disappear.

When saving the original docx to doc in Word 13 it adds an extra line break after the first tab character and deletes the last two (this is cheating...) so that it retains more or less the image position, although more to the center than right of the header.
Comment 4 NISZ LibreOffice Team 2020-07-13 15:34:27 UTC
Created attachment 162985 [details]
Screenshot of the example file saved to doc format in 6.3dev in Word

So this is how it looked in the commit before the solution to bug #92335
This is saved with commit e84428b92a32fcd6d157291173087b3a4e2c7f35 in the bibisect-win32-6.3 repo.

Bug #92335 caused bug #128499 in the doc export and then the solution of #92335 was limited to docx. 
Now after bug #128499 is solved we have the same behavior of doc export as before bug #92335
Comment 5 Timur 2021-08-19 10:11:05 UTC
Created attachment 174408 [details]
sample compared in LO and MSO
Comment 6 Justin L 2023-05-25 10:46:16 UTC
Things have changed.
Now the DOCX initially imports in a way that sounds very similar to Word as described in comment 3. A line-break is introduced after two tabs, and the image is more or less in the center of the page.

That happened in LO 7.3 with commit 054b554b18d89b7efa87f79b5f33865252e9e789
Author: Miklos Vajna on Fri Jan 28 13:38:20 2022 +0100
    DOCX import: handle a subset of <w:ptab w:alignment="left">

The round-trip to DOC looks the same as DOCX in MSO and LO.

Ultimately, this is a DOCX import issue. We do not yet handle the right alignment aspect of w:ptab.

*** This bug has been marked as a duplicate of bug 78144 ***