diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-09-21 11:50:57 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-09-21 13:30:20 +0200 |
commit | aef569ed83a3ccc02639e5b2a1c7cc131ba262fc (patch) | |
tree | 90bf85cdf5359ec5e300000d396cd13d33e924fb /oox/inc | |
parent | 356db87a6b622722d0d04ee3e17730a96865770a (diff) |
tdf#120028 PPTX import: map shapes with multiple columns to table shapes
Longer term the core Impress shape has to be improved so that it can have
text in multiple columns.
Shorter term, map text with multiple columns to table shapes, that gives
correct layout in many cases and requires changes to the import filter
only.
Change-Id: Id7942b16882ab1f083ded2f0e577e8c9e128697c
Reviewed-on: https://gerrit.libreoffice.org/60859
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Jenkins
Diffstat (limited to 'oox/inc')
-rw-r--r-- | oox/inc/drawingml/table/tableproperties.hxx | 3 | ||||
-rw-r--r-- | oox/inc/drawingml/textbody.hxx | 2 | ||||
-rw-r--r-- | oox/inc/drawingml/textbodyproperties.hxx | 2 |
3 files changed, 7 insertions, 0 deletions
diff --git a/oox/inc/drawingml/table/tableproperties.hxx b/oox/inc/drawingml/table/tableproperties.hxx index af6671a81f23..dd50cd7a694d 100644 --- a/oox/inc/drawingml/table/tableproperties.hxx +++ b/oox/inc/drawingml/table/tableproperties.hxx @@ -59,6 +59,9 @@ public: const css::uno::Reference < css::beans::XPropertySet > & xPropSet, const ::oox::drawingml::TextListStylePtr& pMasterTextListStyle ); + /// Distributes text body with multiple columns in table cells. + void pullFromTextBody(oox::drawingml::TextBodyPtr pTextBody, sal_Int32 nShapeWidth); + private: const TableStyle& getUsedTableStyle(const ::oox::core::XmlFilterBase& rFilterBase, std::unique_ptr<TableStyle>& rTableStyleToDelete); diff --git a/oox/inc/drawingml/textbody.hxx b/oox/inc/drawingml/textbody.hxx index c2b0c5acc762..835f1c34b792 100644 --- a/oox/inc/drawingml/textbody.hxx +++ b/oox/inc/drawingml/textbody.hxx @@ -45,6 +45,8 @@ public: const TextParagraphVector& getParagraphs() const { return maParagraphs; } TextParagraph& addParagraph(); + /// Appends an existing paragraph to this text body. + void appendParagraph(std::shared_ptr<TextParagraph> pTextParagraph); const TextListStyle& getTextListStyle() const { return maTextListStyle; } TextListStyle& getTextListStyle() { return maTextListStyle; } diff --git a/oox/inc/drawingml/textbodyproperties.hxx b/oox/inc/drawingml/textbodyproperties.hxx index 62ee3190ae58..247851ef6cc8 100644 --- a/oox/inc/drawingml/textbodyproperties.hxx +++ b/oox/inc/drawingml/textbodyproperties.hxx @@ -42,6 +42,8 @@ struct TextBodyProperties boost::optional< sal_Int32 > moTextOffRight; css::drawing::TextVerticalAdjust meVA; OUString msPrst; + /// Number of requested columns. + sal_Int32 mnNumCol = 1; explicit TextBodyProperties(); |