diff options
author | Gülşah Köse <gulsah.kose@collabora.com> | 2020-08-07 14:53:13 +0300 |
---|---|---|
committer | Xisco Fauli <xiscofauli@libreoffice.org> | 2020-09-01 18:00:21 +0200 |
commit | 30646d95555db67cca8902a1a456f57dfdc9c30b (patch) | |
tree | 61e284347fa8b135795b32eec78bd30c97d84e61 /oox | |
parent | ed057e1ecbdfaa067d635f38e46501ff3ec776a1 (diff) |
tdf#133015 Do not import multicol table text on master.
Change-Id: I0a1b1dc2f9b314858ed90347065407bcd1dbbb73
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100311
Tested-by: Jenkins
Reviewed-by: Gülşah Köse <gulsah.kose@collabora.com>
Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101748
Diffstat (limited to 'oox')
-rw-r--r-- | oox/inc/drawingml/table/tableproperties.hxx | 2 | ||||
-rw-r--r-- | oox/source/drawingml/table/tableproperties.cxx | 5 | ||||
-rw-r--r-- | oox/source/ppt/pptshape.cxx | 2 |
3 files changed, 6 insertions, 3 deletions
diff --git a/oox/inc/drawingml/table/tableproperties.hxx b/oox/inc/drawingml/table/tableproperties.hxx index dcdf41b17ed0..ec8b3c4c5b60 100644 --- a/oox/inc/drawingml/table/tableproperties.hxx +++ b/oox/inc/drawingml/table/tableproperties.hxx @@ -59,7 +59,7 @@ public: const ::oox::drawingml::TextListStylePtr& pMasterTextListStyle ); /// Distributes text body with multiple columns in table cells. - void pullFromTextBody(oox::drawingml::TextBodyPtr pTextBody, sal_Int32 nShapeWidth, bool bhasSameSubTypeIndex); + void pullFromTextBody(oox::drawingml::TextBodyPtr pTextBody, sal_Int32 nShapeWidth, bool bhasSameSubTypeIndex, bool bMaster); private: diff --git a/oox/source/drawingml/table/tableproperties.cxx b/oox/source/drawingml/table/tableproperties.cxx index 1ecea1363659..bf7d0dcfe7a2 100644 --- a/oox/source/drawingml/table/tableproperties.cxx +++ b/oox/source/drawingml/table/tableproperties.cxx @@ -207,7 +207,7 @@ void TableProperties::pushToPropSet(const ::oox::core::XmlFilterBase& rFilterBas xTableStyleToDelete.reset(); } -void TableProperties::pullFromTextBody(oox::drawingml::TextBodyPtr pTextBody, sal_Int32 nShapeWidth, bool bhasSameSubTypeIndex) +void TableProperties::pullFromTextBody(oox::drawingml::TextBodyPtr pTextBody, sal_Int32 nShapeWidth, bool bhasSameSubTypeIndex, bool bMaster) { // Create table grid and a single row. sal_Int32 nNumCol = pTextBody->getTextProperties().mnNumCol; @@ -245,6 +245,9 @@ void TableProperties::pullFromTextBody(oox::drawingml::TextBodyPtr pTextBody, sa // Copy properties provided by <a:lstStyle>. pCellTextBody->getTextListStyle() = pTextBody->getTextListStyle(); + if (bMaster) + continue; + for (sal_Int32 nParaInCol = 0; nParaInCol < nParaPerCol; ++nParaInCol) { if (nPara < pTextBody->getParagraphs().size()) diff --git a/oox/source/ppt/pptshape.cxx b/oox/source/ppt/pptshape.cxx index 53e429df3da4..3a8e1bac0951 100644 --- a/oox/source/ppt/pptshape.cxx +++ b/oox/source/ppt/pptshape.cxx @@ -236,7 +236,7 @@ void PPTShape::addShape( // represent that as a table. sServiceName = "com.sun.star.drawing.TableShape"; oox::drawingml::table::TablePropertiesPtr pTableProperties = getTableProperties(); - pTableProperties->pullFromTextBody(pTextBody, maSize.Width, bhasSameSubTypeIndex); + pTableProperties->pullFromTextBody(pTextBody, maSize.Width, bhasSameSubTypeIndex, meShapeLocation == Layout); setTextBody(nullptr); } } |