sw/qa/extras/ooxmlexport/data/tdf138612.docx |binary sw/qa/extras/ooxmlexport/ooxmlexport5.cxx | 17 +++++++++++++++++ writerfilter/source/dmapper/TablePropertiesHandler.hxx | 3 --- 3 files changed, 17 insertions(+), 3 deletions(-)
New commits: commit 17419824db9174d45dc41ed731aa227ede6f72c4 Author: László Németh <[email protected]> AuthorDate: Fri Dec 4 20:47:04 2020 +0100 Commit: Xisco Fauli <[email protected]> CommitDate: Mon Dec 7 16:49:30 2020 +0100 tdf#138612 DOCX import: fix lost part of split table cell by removing unnecessary rewriting of cell properties during import of w:tblPrEx. Regression from commit da8ea444b004a0be36964ae9a778f73e752b2673 (tdf#133455 DOCX import: fix table border regression) Change-Id: I93ce36991437644db439c8cf02e1a8503fbdfba7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107239 Tested-by: Jenkins Reviewed-by: László Németh <[email protected]> (cherry picked from commit f319d6b543c2367546bc80d138e56ed03731e265) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107304 (cherry picked from commit 2c4806d6b8d79c1b95a41b72d295888bca01d5d8) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107305 Reviewed-by: Xisco Fauli <[email protected]> diff --git a/sw/qa/extras/ooxmlexport/data/tdf138612.docx b/sw/qa/extras/ooxmlexport/data/tdf138612.docx new file mode 100644 index 000000000000..dd116044b56e Binary files /dev/null and b/sw/qa/extras/ooxmlexport/data/tdf138612.docx differ diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport5.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport5.cxx index 43b404553741..e6645a0e819f 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport5.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport5.cxx @@ -743,6 +743,23 @@ DECLARE_OOXMLEXPORT_TEST(testTdf133455, "tdf133455.docx") assertXPath(pXmlDocument, "/w:document/w:body/w:tbl/w:tr[11]/w:tc[1]/w:tcPr/w:tcBorders/w:bottom[@w:val = 'nil']", 0); } +DECLARE_OOXMLEXPORT_EXPORTONLY_TEST(testTdf138612, "tdf138612.docx") +{ + xmlDocUniquePtr pXmlDocument = parseExport("word/document.xml"); + + // Row 5 Col 1 - vertically merged cell + assertXPath(pXmlDocument, "/w:document/w:body/w:tbl/w:tr[5]/w:tc[1]/w:tcPr/w:vMerge", "val", "restart"); + // Row 5 Col 2 - split cell + // This was w:vMerge="restart" + assertXPath(pXmlDocument, "/w:document/w:body/w:tbl/w:tr[5]/w:tc[2]/w:tcPr/w:vMerge", 0); + + // Row 6 Col 1 - merged with cell in Row 5 Col 1 + assertXPath(pXmlDocument, "/w:document/w:body/w:tbl/w:tr[6]/w:tc[1]/w:tcPr/w:vMerge", "val", "continue"); + // Row 6 Col 2 - split cell + // This was w:vMerge="continue" (merged with cell in Row 5 Col 2) + assertXPath(pXmlDocument, "/w:document/w:body/w:tbl/w:tr[6]/w:tc[2]/w:tcPr/w:vMerge", 0); +} + DECLARE_OOXMLEXPORT_EXPORTONLY_TEST(testTdf128646, "tdf128646.docx") { // The problem was that not hidden shapes anchored to empty hidden paragraphs were imported as hidden. diff --git a/writerfilter/source/dmapper/TablePropertiesHandler.hxx b/writerfilter/source/dmapper/TablePropertiesHandler.hxx index d35ad7f114f0..514adbe129fe 100644 --- a/writerfilter/source/dmapper/TablePropertiesHandler.hxx +++ b/writerfilter/source/dmapper/TablePropertiesHandler.hxx @@ -77,10 +77,7 @@ private: void tableExceptionProps( TablePropertyMapPtr pProps ) { if ( m_pTableManager ) - { m_pTableManager->tableExceptionProps( pProps ); - cellProps( pProps ); - } else m_pCurrentProperties->InsertProps(pProps.get()); }; _______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
