summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorArmin Le Grand (Allotropia) <Armin.Le.Grand@me.com>2022-02-18 16:07:28 +0100
committerArmin Le Grand <Armin.Le.Grand@me.com>2022-02-22 18:09:24 +0100
commiteaaf5ef8f99404797ffbb44ceeebf8795d85f07e (patch)
tree12bce3931b78d2f009252a81cc219e342fcdd8e7 /svx
parent8187737a7844fe4669f80bf0e8ef0950148dc58f (diff)
Advanced Diagram support: first additions/reorganizations
To allow advanced Diagram/SmartArt support in the future this is a first step to organize imported SmartArt Data in a way that will allow to re-layout loaded SmartArts, under re-usage of the oox::Theme (held available). It is designed to work without holding available the original XML snippets defining the imported Diagram in any way, also for performance reasons. It tries to re-use some of the already basically added functionality, including the systematic layouting using the generic layout algorithm, plus some already available text extraction. Before being sure that the former state can be completely replaced this is optoinal and used when SAL_ENABLE_ADVANCED_SMART_ART is defined. Some new stuff is already done but e.g. the redefined reLayout method will not (yet) be triggered. It works and reliably produces a re-layouted identical version, also preserving transformations. Change-Id: I08cfbae04afa663d0589530aae549216d853128d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130171 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/svdraw/svdogrp.cxx19
1 files changed, 16 insertions, 3 deletions
diff --git a/svx/source/svdraw/svdogrp.cxx b/svx/source/svdraw/svdogrp.cxx
index f9eb754bb7c2..47e9f0f83901 100644
--- a/svx/source/svdraw/svdogrp.cxx
+++ b/svx/source/svdraw/svdogrp.cxx
@@ -35,6 +35,14 @@
#include <rtl/ustrbuf.hxx>
#include <vcl/canvastools.hxx>
+DiagramHelper::DiagramHelper() {}
+DiagramHelper::~DiagramHelper() {}
+
+void DiagramHelper::anchorToSdrObjGroup(SdrObjGroup& rTarget)
+{
+ rTarget.mp_DiagramHelper.reset(this);
+}
+
// BaseProperties section
std::unique_ptr<sdr::properties::BaseProperties> SdrObjGroup::CreateObjectSpecificProperties()
{
@@ -48,14 +56,19 @@ std::unique_ptr<sdr::contact::ViewContact> SdrObjGroup::CreateObjectSpecificView
}
SdrObjGroup::SdrObjGroup(SdrModel& rSdrModel)
-: SdrObject(rSdrModel),
- maRefPoint(0, 0)
+: SdrObject(rSdrModel)
+, SdrObjList()
+, maRefPoint(0, 0)
+, mp_DiagramHelper()
{
m_bClosedObj=false;
}
SdrObjGroup::SdrObjGroup(SdrModel& rSdrModel, SdrObjGroup const & rSource)
-: SdrObject(rSdrModel, rSource)
+: SdrObject(rSdrModel, rSource)
+, SdrObjList()
+, maRefPoint(0, 0)
+, mp_DiagramHelper()
{
m_bClosedObj=false;