Bug 129452 - FILEOPEN DOCX bottom border of vertically merged table cells missing
Summary: FILEOPEN DOCX bottom border of vertically merged table cells missing
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
6.4.0.0.beta1+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:7.0.0 target:6.4.1 target:7.1.0
Keywords:
Depends on:
Blocks: DOCX-Tables
  Show dependency treegraph
 
Reported: 2019-12-17 15:08 UTC by NISZ LibreOffice Team
Modified: 2020-07-16 16:31 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
Example file from Word (17.54 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2019-12-17 15:09 UTC, NISZ LibreOffice Team
Details
Screenshot of the original document side by side in Word and Writer. (74.30 KB, image/png)
2019-12-17 15:10 UTC, NISZ LibreOffice Team
Details
tables to check_simplified_tableProperties.docx: still missing border (10.94 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2020-06-05 12:39 UTC, Justin L
Details
tables to check_simplified_tableProperties2c.docx: simpler, clearer, breaking example (10.85 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2020-06-05 17:52 UTC, Justin L
Details

Note You need to log in before you can comment on or make changes to this bug.
Description NISZ LibreOffice Team 2019-12-17 15:08:44 UTC
Description:
Attached DOCX file made in Word contains a simple table with vertically merged cells and internal borders turned off.
When opened in Writer the bottom vertical border of the table is missing.


Steps to Reproduce:
1.	Create a table in Word with vertically merged cells in one column
2.	Turn off the internal borders of the table.
3.	Save the file and reopen it in Writer.


Actual Results:
The bottom horizontal external border of the table is missing under the column with the merged cells.

Expected Results:
External border visible is all around the table.


Reproducible: Always


User Profile Reset: No



Additional Info:
LibreOffice details:
Verzió: 6.4.0.0.beta1 (x86)
Build az.: 4d7e5b0c40ed843384704eca3ce21981d4e98920
CPU szálak: 4; OS: Windows 6.3 Build 9600; Felületmegjelenítés: alapértelmezett; VCL: win; 
Területi beállítások: hu-HU (hu_HU); Felület nyelve: hu-HU
Calc: CL

Also happens in:

Verzió: 3.6.0.4 (Build az.: 932b512)

Verzió: 4.1.0.3
Build az.: 719826cd009b9a1fa43e253db0616288c682826

Verzió: 5.0.0.5
Build az.: 1b1a90865e348b492231e1c451437d7a15bb262b
Területi beállítások: hu-HU (hu_HU)

Verzió: 5.4.0.3
Build az.: 92c2794a7c181ba4c1c5053618179937228ed1fb
CPU szálak: 4; OS: Windows 6.2; Felületmegjelenítés: GL; 
Területi beállítások: hu-HU (hu_HU); Calc: CL

The borders are not visible in:
LibreOffice 3.5.0rc3 
Build ID: 7e68ba2-a744ebf-1f241b7-c506db1-7d53735
Comment 1 NISZ LibreOffice Team 2019-12-17 15:09:15 UTC
Created attachment 156628 [details]
Example file from Word
Comment 2 NISZ LibreOffice Team 2019-12-17 15:10:17 UTC
Created attachment 156629 [details]
Screenshot of the original document side by side in Word and Writer.
Comment 3 Commit Notification 2020-01-07 15:56:30 UTC
Szabolcs Toth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/0f4dd820ee433932d9d9237b676292d31c4ba913

tdf#129452 DOCX import: fix bottom border of merged column

It will be available in 6.5.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 Xisco Faulí 2020-01-08 09:52:47 UTC
Verified in

Version: 6.5.0.0.alpha0+
Build ID: 4f6d95ead1286748810e937c7672de08b8b39a38
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

@Szabolcs Toth, thanks for fixing this issue!
Comment 5 Commit Notification 2020-01-20 08:20:06 UTC
Szabolcs Toth committed a patch related to this issue.
It has been pushed to "libreoffice-6-4":

https://git.libreoffice.org/core/commit/63518134fc0a148dcce75bebaba43dc5ae761da8

tdf#129452 DOCX import: fix bottom border of merged column

It will be available in 6.4.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.
Comment 6 Justin L 2020-06-05 12:39:27 UTC
Created attachment 161649 [details]
tables to check_simplified_tableProperties.docx: still missing border

You have the same problem that I have - nCell != nColumn. So it cannot be used to compare to other rows.
Comment 7 Justin L 2020-06-05 17:52:16 UTC
Created attachment 161664 [details]
tables to check_simplified_tableProperties2c.docx: simpler, clearer, breaking example

OK - I think I'll back away from this one and let you guys handle it because this document shows that your backported commit can have bad effects (on admittedly a hand-crafted example - not sure if Word would every actually create this, but under the right conditions it might).

It is the same problem - nCell is clearly not called nCol because we can't assume that. Somehow (and I have no idea how) the concept of gridspan needs to be connected to cells in DomainMapperTableHandler - or at least a way to map between logical (unmerged) column and nCell.
Comment 8 Commit Notification 2020-07-07 16:33:43 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/2ad32b39af2e00ef253a2ef99e033feef416808f

tdf#129452 writerfilter: preserve gridBefore longer than currentRow

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.
Comment 9 Commit Notification 2020-07-08 15:32:23 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/2e8992aea2017e89a6f7ba5f0ef544f29059243b

tdf#129452 writerfilter: preserve gridSpans longer than currentRow

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.
Comment 10 Commit Notification 2020-07-13 18:52:31 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/19d7f9624e92422409ed2744091d502fdae8692b

tdf#129452 writerfilter: use column, not cell when comparing rows

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.
Comment 11 Xisco Faulí 2020-07-14 14:47:29 UTC
Hi Justin,
should you commits be backported to libreoffice-7-0 branch ?
Comment 12 Justin L 2020-07-14 16:07:10 UTC
(In reply to Xisco Faulí from comment #11)
> should your commits be backported to libreoffice-7-0 branch ?
no.
Comment 13 Commit Notification 2020-07-15 19:12:12 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/19ffc31ac047e9e8986591937ad945bc7dc2b875

tdf129452 writerfilter: only affect vertical Merge_restart

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.