[Libreoffice-commits] core.git: Branch 'feature/drawinglayercore' - 13 commits - drawinglayer/CppunitTest_drawinglayer_border.mk drawinglayer/inc drawinglayer/Library_drawinglayercore.mk drawinglayer/Library_drawinglayer.mk drawinglayer/Module_drawinglayer.mk drawinglayer/source emfio/CppunitTest_emfio_emf.mk emfio/Library_emfio.mk filter/Library_pdffilter.mk filter/Library_svgfilter.mk filter/source include/basegfx include/drawinglayer include/o3tl include/svx include/vcl o3tl/qa Repository.mk sc/CppunitTest_sc_parallelism.mk sc/CppunitTest_sc_ucalc.mk sc/Library_sc.mk sc/source sd/CppunitTest_sd_uimpress.mk sd/Library_sd.mk sd/source sfx2/Library_sfx.mk sfx2/source svgio/CppunitTest_svgio.mk svgio/Library_svgio.mk svgio/source svx/CppunitTest_svx_unit.mk svx/inc svx/Library_svxcore.mk svx/Library_svx.mk svx/qa svx/source sw/CppunitTest_sw_uwriter.mk sw/Library_sw.mk sw/Library_swui.mk sw/source vcl/inc vcl/Library_vcl.mk vcl/qa vcl/source

Tomaž Vajngerl (via logerrit) logerrit at kemper.freedesktop.org
Fri Feb 19 08:38:18 UTC 2021


Rebased ref, commits from common ancestor:
commit 6f8476143acc0330cf5be7b209a3fb9175992abc
Author:     Tomaž Vajngerl <tomaz.vajngerl at collabora.co.uk>
AuthorDate: Fri Feb 19 17:37:22 2021 +0900
Commit:     Tomaž Vajngerl <tomaz.vajngerl at collabora.co.uk>
CommitDate: Fri Feb 19 17:37:22 2021 +0900

    drawinglayer: move TextLayouter to processor2d
    
    Change-Id: I87c7fafb51f108dcf58e7ddb97595f6488d884a0

diff --git a/drawinglayer/Library_drawinglayer.mk b/drawinglayer/Library_drawinglayer.mk
index 451a9b1e55d3..05f47793daae 100644
--- a/drawinglayer/Library_drawinglayer.mk
+++ b/drawinglayer/Library_drawinglayer.mk
@@ -95,7 +95,6 @@ $(eval $(call gb_Library_add_exception_objects,drawinglayer,\
     drawinglayer/source/primitive2d/textdecoratedprimitive2d \
     drawinglayer/source/primitive2d/texteffectprimitive2d \
     drawinglayer/source/primitive2d/texthierarchyprimitive2d \
-    drawinglayer/source/primitive2d/textlayoutdevice \
     drawinglayer/source/primitive2d/textlineprimitive2d \
     drawinglayer/source/primitive2d/textprimitive2d \
     drawinglayer/source/primitive2d/textstrikeoutprimitive2d \
@@ -130,6 +129,7 @@ $(eval $(call gb_Library_add_exception_objects,drawinglayer,\
     drawinglayer/source/processor2d/objectinfoextractor2d \
     drawinglayer/source/processor2d/processorfromoutputdevice \
     drawinglayer/source/processor2d/textaspolygonextractor2d \
+    drawinglayer/source/processor2d/textlayoutdevice \
     drawinglayer/source/processor2d/vclhelperbufferdevice \
     drawinglayer/source/processor2d/vclmetafileprocessor2d \
     drawinglayer/source/processor2d/vclpixelprocessor2d \
diff --git a/drawinglayer/source/primitive2d/textdecoratedprimitive2d.cxx b/drawinglayer/source/primitive2d/textdecoratedprimitive2d.cxx
index 8befcff3a7e3..43db89f68dd0 100644
--- a/drawinglayer/source/primitive2d/textdecoratedprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/textdecoratedprimitive2d.cxx
@@ -59,7 +59,7 @@ namespace drawinglayer::primitive2d
                 return;
 
             // common preparations
-            TextLayouterDevice aTextLayouter;
+            drawinglayer::processor2d::TextLayouterDevice aTextLayouter;
 
             // TextLayouterDevice is needed to get metrics for text decorations like
             // underline/strikeout/emphasis marks from it. For setup, the font size is needed
diff --git a/drawinglayer/source/primitive2d/textprimitive2d.cxx b/drawinglayer/source/primitive2d/textprimitive2d.cxx
index aa95f0091c30..b6bf98314752 100644
--- a/drawinglayer/source/primitive2d/textprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/textprimitive2d.cxx
@@ -18,7 +18,7 @@
  */
 
 #include <drawinglayer/primitive2d/textprimitive2d.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <basegfx/polygon/b2dpolypolygon.hxx>
 #include <drawinglayer/primitive2d/PolyPolygonColorPrimitive2D.hxx>
 #include <drawinglayer/primitive2d/drawinglayer_primitivetypes2d.hxx>
@@ -111,7 +111,7 @@ void TextSimplePortionPrimitive2D::getTextOutlinesAndTransformation(
     const basegfx::B2DVector aFontScale(getCorrectedScaleAndFontScale(aScale));
 
     // prepare textlayoutdevice
-    TextLayouterDevice aTextLayouter;
+    drawinglayer::processor2d::TextLayouterDevice aTextLayouter;
     aTextLayouter.setFontAttribute(getFontAttribute(), aFontScale.getX(), aFontScale.getY(),
                                    getLocale());
 
@@ -271,7 +271,7 @@ TextSimplePortionPrimitive2D::getB2DRange(VisitingParameters const& /*rParameter
             const basegfx::B2DVector aFontScale(getCorrectedScaleAndFontScale(aScale));
 
             // prepare textlayoutdevice
-            TextLayouterDevice aTextLayouter;
+            drawinglayer::processor2d::TextLayouterDevice aTextLayouter;
             aTextLayouter.setFontAttribute(getFontAttribute(), aFontScale.getX(), aFontScale.getY(),
                                            getLocale());
 
diff --git a/drawinglayer/source/primitive2d/textstrikeoutprimitive2d.cxx b/drawinglayer/source/primitive2d/textstrikeoutprimitive2d.cxx
index 71818e7861cc..25f4e0a1fa8d 100644
--- a/drawinglayer/source/primitive2d/textstrikeoutprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/textstrikeoutprimitive2d.cxx
@@ -18,7 +18,7 @@
  */
 
 #include <primitive2d/textstrikeoutprimitive2d.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/primitive2d/textprimitive2d.hxx>
 #include <drawinglayer/primitive2d/drawinglayer_primitivetypes2d.hxx>
 #include <basegfx/polygon/b2dpolygon.hxx>
@@ -68,7 +68,7 @@ namespace drawinglayer::primitive2d
             getObjectTransformation().decompose(aScale, aTranslate, fRotate, fShearX);
 
             // prepare TextLayouter
-            TextLayouterDevice aTextLayouter;
+            drawinglayer::processor2d::TextLayouterDevice aTextLayouter;
 
             aTextLayouter.setFontAttribute(
                 getFontAttribute(),
diff --git a/drawinglayer/source/primitive2d/textlayoutdevice.cxx b/drawinglayer/source/processor2d/textlayoutdevice.cxx
similarity index 99%
rename from drawinglayer/source/primitive2d/textlayoutdevice.cxx
rename to drawinglayer/source/processor2d/textlayoutdevice.cxx
index 933476b2045a..759a5757c8a2 100644
--- a/drawinglayer/source/primitive2d/textlayoutdevice.cxx
+++ b/drawinglayer/source/processor2d/textlayoutdevice.cxx
@@ -23,7 +23,7 @@
 
 #include <com/sun/star/uno/XComponentContext.hpp>
 #include <drawinglayer/attribute/fontattribute.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <comphelper/processfactory.hxx>
 #include <comphelper/unique_disposing_ptr.hxx>
 #include <osl/diagnose.h>
@@ -36,7 +36,7 @@
 #include <i18nlangtag/languagetag.hxx>
 #include <vcl/svapp.hxx>
 
-namespace drawinglayer::primitive2d
+namespace drawinglayer::processor2d
 {
 namespace
 {
diff --git a/drawinglayer/source/processor2d/vclprocessor2d.cxx b/drawinglayer/source/processor2d/vclprocessor2d.cxx
index c2c835e5291d..41942896a96f 100644
--- a/drawinglayer/source/processor2d/vclprocessor2d.cxx
+++ b/drawinglayer/source/processor2d/vclprocessor2d.cxx
@@ -52,7 +52,7 @@
 // for support of Title/Description in all apps when embedding pictures
 #include <drawinglayer/primitive2d/objectinfoprimitive2d.hxx>
 // control support
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 
 #include <drawinglayer/primitive2d/pointarrayprimitive2d.hxx>
 #include <drawinglayer/primitive2d/epsprimitive2d.hxx>
@@ -124,7 +124,7 @@ void VclProcessor2D::RenderTextSimpleOrDecoratedPortionPrimitive2D(
             && basegfx::fTools::more(aFontScaling.getY(), 0.0))
         {
             // Get the VCL font (use FontHeight as FontWidth)
-            vcl::Font aFont(primitive2d::getVclFontFromFontAttribute(
+            vcl::Font aFont(processor2d::getVclFontFromFontAttribute(
                 rTextCandidate.getFontAttribute(), aFontScaling.getX(), aFontScaling.getY(),
                 fRotate, rTextCandidate.getLocale()));
 
diff --git a/drawinglayer/source/tools/wmfemfhelper.cxx b/drawinglayer/source/tools/wmfemfhelper.cxx
index a4bfa3d36c46..c75516bd050c 100644
--- a/drawinglayer/source/tools/wmfemfhelper.cxx
+++ b/drawinglayer/source/tools/wmfemfhelper.cxx
@@ -39,7 +39,7 @@
 #include <drawinglayer/primitive2d/invertprimitive2d.hxx>
 #include <drawinglayer/primitive2d/modifiedcolorprimitive2d.hxx>
 #include <primitive2d/wallpaperprimitive2d.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/primitive2d/textdecoratedprimitive2d.hxx>
 #include <primitive2d/textlineprimitive2d.hxx>
 #include <primitive2d/textstrikeoutprimitive2d.hxx>
@@ -1067,7 +1067,7 @@ namespace wmfemfhelper
         const vcl::Font& rFont = rProperty.getFont();
         basegfx::B2DVector aFontScaling;
 
-        rFontAttribute = drawinglayer::primitive2d::getFontAttributeFromVclFont(
+        rFontAttribute = drawinglayer::processor2d::getFontAttributeFromVclFont(
                             aFontScaling,
                             rFont,
                             bool(rProperty.getLayoutMode() & ComplexTextLayoutFlags::BiDiRtl),
@@ -1079,7 +1079,7 @@ namespace wmfemfhelper
         // take text align into account
         if(ALIGN_BASELINE != rFont.GetAlignment())
         {
-            drawinglayer::primitive2d::TextLayouterDevice aTextLayouterDevice;
+            drawinglayer::processor2d::TextLayouterDevice aTextLayouterDevice;
             aTextLayouterDevice.setFont(rFont);
 
             if(ALIGN_TOP == rFont.GetAlignment())
@@ -1231,7 +1231,7 @@ namespace wmfemfhelper
         if(pResult && rProperty.getTextFillColorActive())
         {
             // text background is requested, add and encapsulate both to new primitive
-            drawinglayer::primitive2d::TextLayouterDevice aTextLayouterDevice;
+            drawinglayer::processor2d::TextLayouterDevice aTextLayouterDevice;
             aTextLayouterDevice.setFont(rFont);
 
             // get text width
@@ -1341,7 +1341,7 @@ namespace wmfemfhelper
         aTextTransform.translate(rAction.GetStartPoint().X(), rAction.GetStartPoint().Y());
 
         // prepare TextLayouter (used in most cases)
-        drawinglayer::primitive2d::TextLayouterDevice aTextLayouter;
+        drawinglayer::processor2d::TextLayouterDevice aTextLayouter;
         aTextLayouter.setFont(rProperty.getFont());
 
         if(bOverlineUsed)
@@ -1885,7 +1885,7 @@ namespace wmfemfhelper
 
                     if(nTextLength && rPropertyHolders.Current().getTextColorActive())
                     {
-                        drawinglayer::primitive2d::TextLayouterDevice aTextLayouterDevice;
+                        drawinglayer::processor2d::TextLayouterDevice aTextLayouterDevice;
                         aTextLayouterDevice.setFont(rPropertyHolders.Current().getFont());
 
                         std::vector< double > aTextArray(
@@ -1947,7 +1947,7 @@ namespace wmfemfhelper
                         // Since AddTextRectActions is the only way as long as we do not have
                         // a simple text layouter available, i will try to add it to the
                         // TextLayouterDevice isolation.
-                        drawinglayer::primitive2d::TextLayouterDevice aTextLayouterDevice;
+                        drawinglayer::processor2d::TextLayouterDevice aTextLayouterDevice;
                         aTextLayouterDevice.setFont(rPropertyHolders.Current().getFont());
                         GDIMetaFile aGDIMetaFile;
 
diff --git a/include/drawinglayer/primitive2d/textbreakuphelper.hxx b/include/drawinglayer/primitive2d/textbreakuphelper.hxx
index de233da8ea07..afe15f45f711 100644
--- a/include/drawinglayer/primitive2d/textbreakuphelper.hxx
+++ b/include/drawinglayer/primitive2d/textbreakuphelper.hxx
@@ -21,7 +21,7 @@
 
 #include <drawinglayer/drawinglayerdllapi.h>
 #include <drawinglayer/primitive2d/Primitive2DContainer.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <basegfx/matrix/b2dhommatrixtools.hxx>
 
 namespace drawinglayer::primitive2d { class TextSimplePortionPrimitive2D; }
@@ -40,7 +40,7 @@ namespace drawinglayer::primitive2d
         private:
             const TextSimplePortionPrimitive2D&     mrSource;
             Primitive2DContainer                       mxResult;
-            TextLayouterDevice                      maTextLayouter;
+            drawinglayer::processor2d::TextLayouterDevice                      maTextLayouter;
             basegfx::utils::B2DHomMatrixBufferedOnDemandDecompose maDecTrans;
 
             bool                                    mbNoDXArray : 1;
@@ -58,7 +58,7 @@ namespace drawinglayer::primitive2d
             virtual bool allowChange(sal_uInt32 nCount, basegfx::B2DHomMatrix& rNewTransform, sal_uInt32 nIndex, sal_uInt32 nLength);
 
             /// allow read access to evtl. useful local parts
-            const TextLayouterDevice& getTextLayouter() const { return maTextLayouter; }
+            const drawinglayer::processor2d::TextLayouterDevice& getTextLayouter() const { return maTextLayouter; }
             const TextSimplePortionPrimitive2D& getSource() const { return mrSource; }
 
         public:
diff --git a/include/drawinglayer/primitive2d/textlayoutdevice.hxx b/include/drawinglayer/processor2d/textlayoutdevice.hxx
similarity index 98%
rename from include/drawinglayer/primitive2d/textlayoutdevice.hxx
rename to include/drawinglayer/processor2d/textlayoutdevice.hxx
index 93587769c449..ddcdf06bc0dd 100644
--- a/include/drawinglayer/primitive2d/textlayoutdevice.hxx
+++ b/include/drawinglayer/processor2d/textlayoutdevice.hxx
@@ -49,7 +49,7 @@ struct Locale;
 
 // access to one global impTimedRefDev incarnation in namespace drawinglayer::primitive
 
-namespace drawinglayer::primitive2d
+namespace drawinglayer::processor2d
 {
 /** TextLayouterDevice class
 
@@ -122,6 +122,6 @@ vcl::Font DRAWINGLAYER_DLLPUBLIC getVclFontFromFontAttribute(
 attribute::FontAttribute DRAWINGLAYER_DLLPUBLIC getFontAttributeFromVclFont(
     basegfx::B2DVector& o_rSize, const vcl::Font& rFont, bool bRTL, bool bBiDiStrong);
 
-} // end of namespace drawinglayer::primitive2d
+} // end of namespace drawinglayer::processor2d
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/ui/view/hintwin.cxx b/sc/source/ui/view/hintwin.cxx
index d690ab33d002..c8db42fff6ca 100644
--- a/sc/source/ui/view/hintwin.cxx
+++ b/sc/source/ui/view/hintwin.cxx
@@ -23,7 +23,7 @@
 #include <drawinglayer/geometry/viewinformation2d.hxx>
 #include <drawinglayer/primitive2d/polygonprimitive2d.hxx>
 #include <drawinglayer/primitive2d/PolyPolygonColorPrimitive2D.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/primitive2d/textprimitive2d.hxx>
 #include <basegfx/polygon/b2dpolygontools.hxx>
 #include <basegfx/matrix/b2dhommatrixtools.hxx>
@@ -65,7 +65,7 @@ drawinglayer::primitive2d::Primitive2DContainer ScOverlayHint::createOverlaySequ
     // Create the text primitive for the title
     basegfx::B2DVector aFontSize;
     drawinglayer::attribute::FontAttribute aFontAttr =
-        drawinglayer::primitive2d::getFontAttributeFromVclFont(aFontSize, aHeadFont, false, false);
+        drawinglayer::processor2d::getFontAttributeFromVclFont(aFontSize, aHeadFont, false, false);
 
     FontMetric aFontMetric = pDefaultDev->GetFontMetric(aHeadFont);
     Size aHintMargin = pDefaultDev->PixelToLogic(Size(HINT_MARGIN, HINT_MARGIN), rMapMode);
@@ -100,7 +100,7 @@ drawinglayer::primitive2d::Primitive2DContainer ScOverlayHint::createOverlaySequ
     nTextOffsetY = aFontMetric.GetAscent();
     sal_Int32 nLineHeight = aFontMetric.GetLineHeight();
 
-    aFontAttr = drawinglayer::primitive2d::getFontAttributeFromVclFont(aFontSize, aTextFont, false, false);
+    aFontAttr = drawinglayer::processor2d::getFontAttributeFromVclFont(aFontSize, aTextFont, false, false);
 
     sal_Int32 nIndex = 0;
     Point aLineStart = aTextStart;
diff --git a/sd/source/ui/view/sdview.cxx b/sd/source/ui/view/sdview.cxx
index 5a2a0be72ce7..620bf88f6db6 100644
--- a/sd/source/ui/view/sdview.cxx
+++ b/sd/source/ui/view/sdview.cxx
@@ -67,7 +67,7 @@
 #include <basegfx/polygon/b2dpolygontools.hxx>
 #include <basegfx/color/bcolor.hxx>
 #include <drawinglayer/primitive2d/polygonprimitive2d.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <svx/sdr/contact/objectcontact.hxx>
 #include <svx/sdr/table/tablecontroller.hxx>
 #include <basegfx/matrix/b2dhommatrix.hxx>
@@ -360,7 +360,7 @@ drawinglayer::primitive2d::Primitive2DContainer ViewRedirector::createRedirected
                             aScaledVclFont.SetFontHeight( 500 * nTextSizeFactor );
 
                             // get basic geometry and get text size
-                            drawinglayer::primitive2d::TextLayouterDevice aTextLayouter;
+                            drawinglayer::processor2d::TextLayouterDevice aTextLayouter;
                             aTextLayouter.setFont(aScaledVclFont);
                             const sal_Int32 nTextLength(aObjectString.getLength());
 
@@ -384,7 +384,7 @@ drawinglayer::primitive2d::Primitive2DContainer ViewRedirector::createRedirected
                             aVclFont.SetFontHeight( 500 );
 
                             const drawinglayer::attribute::FontAttribute aFontAttribute(
-                                drawinglayer::primitive2d::getFontAttributeFromVclFont(
+                                drawinglayer::processor2d::getFontAttributeFromVclFont(
                                     aTextSizeAttribute,
                                     aVclFont,
                                     false,
diff --git a/sfx2/source/control/emojiviewitem.cxx b/sfx2/source/control/emojiviewitem.cxx
index f9394ea9435c..5878aef883fd 100644
--- a/sfx2/source/control/emojiviewitem.cxx
+++ b/sfx2/source/control/emojiviewitem.cxx
@@ -11,7 +11,7 @@
 
 #include <basegfx/matrix/b2dhommatrixtools.hxx>
 #include <drawinglayer/primitive2d/PolyPolygonSelectionPrimitive2D.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/processor2d/baseprocessor2d.hxx>
 #include <com/sun/star/lang/Locale.hpp>
 #include <rtl/ustrbuf.hxx>
@@ -36,7 +36,7 @@ void EmojiViewItem::calculateItemsPosition (const tools::Long /*nThumbnailHeight
                                                 const tools::Long /*nPadding*/, sal_uInt32 nMaxTextLength,
                                                 const ThumbnailItemAttributes *pAttrs)
 {
-    drawinglayer::primitive2d::TextLayouterDevice aTextDev;
+    drawinglayer::processor2d::TextLayouterDevice aTextDev;
     aTextDev.setFontAttribute(pAttrs->aFontAttr,
                               pAttrs->aFontSize.getX(), pAttrs->aFontSize.getY(),
                               css::lang::Locale() );
diff --git a/sfx2/source/control/thumbnailview.cxx b/sfx2/source/control/thumbnailview.cxx
index c3ebe3bfe903..b83cd375eda6 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -18,7 +18,7 @@
 #include <comphelper/processfactory.hxx>
 #include <drawinglayer/attribute/fontattribute.hxx>
 #include <drawinglayer/primitive2d/PolyPolygonColorPrimitive2D.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/processor2d/baseprocessor2d.hxx>
 #include <drawinglayer/processor2d/processorfromoutputdevice.hxx>
 #include <o3tl/safeint.hxx>
@@ -894,7 +894,7 @@ void ThumbnailView::SetDrawingArea(weld::DrawingArea* pDrawingArea)
     {
         OutputDevice& rDevice = pDrawingArea->get_ref_device();
         pDefaultDevice->SetPointFont(rDevice, pDrawingArea->get_font());
-        mpItemAttrs->aFontAttr = getFontAttributeFromVclFont(mpItemAttrs->aFontSize, rDevice.GetFont(), false, true);
+        mpItemAttrs->aFontAttr = drawinglayer::processor2d::getFontAttributeFromVclFont(mpItemAttrs->aFontSize, rDevice.GetFont(), false, true);
     }
 
     SetOutputSizePixel(pDrawingArea->get_preferred_size());
diff --git a/sfx2/source/control/thumbnailviewitem.cxx b/sfx2/source/control/thumbnailviewitem.cxx
index 79a71c361c9b..e8cc2945b3e6 100644
--- a/sfx2/source/control/thumbnailviewitem.cxx
+++ b/sfx2/source/control/thumbnailviewitem.cxx
@@ -27,7 +27,7 @@
 #include <drawinglayer/primitive2d/fillgraphicprimitive2d.hxx>
 #include <drawinglayer/primitive2d/polygonprimitive2d.hxx>
 #include <drawinglayer/primitive2d/PolyPolygonSelectionPrimitive2D.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/primitive2d/textprimitive2d.hxx>
 #include <drawinglayer/processor2d/baseprocessor2d.hxx>
 #include <vcl/graph.hxx>
@@ -120,7 +120,7 @@ void ThumbnailViewItem::calculateItemsPosition (const tools::Long nThumbnailHeig
                                                 const tools::Long nPadding, sal_uInt32 nMaxTextLength,
                                                 const ThumbnailItemAttributes *pAttrs)
 {
-    drawinglayer::primitive2d::TextLayouterDevice aTextDev;
+    drawinglayer::processor2d::TextLayouterDevice aTextDev;
     aTextDev.setFontAttribute(pAttrs->aFontAttr,
                               pAttrs->aFontSize.getX(), pAttrs->aFontSize.getY(),
                               css::lang::Locale() );
@@ -205,7 +205,7 @@ void ThumbnailViewItem::Paint (drawinglayer::processor2d::BaseProcessor2D *pProc
 void ThumbnailViewItem::addTextPrimitives (const OUString& rText, const ThumbnailItemAttributes *pAttrs, Point aPos, drawinglayer::primitive2d::Primitive2DContainer& rSeq)
 {
     // adjust text drawing position according to text font
-    drawinglayer::primitive2d::TextLayouterDevice aTextDev;
+    drawinglayer::processor2d::TextLayouterDevice aTextDev;
     aTextDev.setFontAttribute(
         pAttrs->aFontAttr,
         pAttrs->aFontSize.getX(),
@@ -218,7 +218,7 @@ void ThumbnailViewItem::addTextPrimitives (const OUString& rText, const Thumbnai
     OUString aOrigText(mrParent.isDrawMnemonic() ? OutputDevice::GetNonMnemonicString(rText, nMnemonicPos) : rText);
 
     TextEngine aTextEngine;
-    aTextEngine.SetFont(getVclFontFromFontAttribute(pAttrs->aFontAttr,
+    aTextEngine.SetFont(drawinglayer::processor2d::getVclFontFromFontAttribute(pAttrs->aFontAttr,
                               pAttrs->aFontSize.getX(), pAttrs->aFontSize.getY(), 0,
                               css::lang::Locale()));
     aTextEngine.SetMaxTextWidth(maDrawArea.getWidth());
diff --git a/svgio/source/svgreader/svgcharacternode.cxx b/svgio/source/svgreader/svgcharacternode.cxx
index dc24adc7ffc0..95a21d14e651 100644
--- a/svgio/source/svgreader/svgcharacternode.cxx
+++ b/svgio/source/svgreader/svgcharacternode.cxx
@@ -21,7 +21,7 @@
 #include <svgstyleattributes.hxx>
 #include <drawinglayer/attribute/fontattribute.hxx>
 #include <drawinglayer/primitive2d/textprimitive2d.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/primitive2d/textbreakuphelper.hxx>
 #include <drawinglayer/primitive2d/textdecoratedprimitive2d.hxx>
 
@@ -258,7 +258,7 @@ namespace svgio::svgreader
                 css::lang::Locale aLocale;
 
                 // prepare TextLayouterDevice
-                drawinglayer::primitive2d::TextLayouterDevice aTextLayouterDevice;
+                drawinglayer::processor2d::TextLayouterDevice aTextLayouterDevice;
                 aTextLayouterDevice.setFontAttribute(aFontAttribute, fFontWidth, fFontHeight, aLocale);
 
                 // prepare TextArray
diff --git a/svx/source/svdraw/svdotextdecomposition.cxx b/svx/source/svdraw/svdotextdecomposition.cxx
index fd53bf0e9d3d..7734c769c4c1 100644
--- a/svx/source/svdraw/svdotextdecomposition.cxx
+++ b/svx/source/svdraw/svdotextdecomposition.cxx
@@ -51,7 +51,7 @@
 #include <drawinglayer/primitive2d/texthierarchyprimitive2d.hxx>
 #include <drawinglayer/primitive2d/wrongspellprimitive2d.hxx>
 #include <drawinglayer/primitive2d/graphicprimitive2d.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/primitive2d/unifiedtransparenceprimitive2d.hxx>
 #include <svx/unoapi.hxx>
 #include <drawinglayer/geometry/viewinformation2d.hxx>
@@ -162,7 +162,7 @@ namespace
         OUString caseMappedText = rInfo.mrFont.CalcCaseMap( rInfo.maText );
         basegfx::B2DVector aFontScaling;
         drawinglayer::attribute::FontAttribute aFontAttribute(
-            drawinglayer::primitive2d::getFontAttributeFromVclFont(
+            drawinglayer::processor2d::getFontAttributeFromVclFont(
                 aFontScaling,
                 rInfo.mrFont,
                 rInfo.IsRTL(),
@@ -592,7 +592,7 @@ namespace
             }
 
             // Start position is inside. Get TextBoundRect and TopLeft next
-            drawinglayer::primitive2d::TextLayouterDevice aTextLayouterDevice;
+            drawinglayer::processor2d::TextLayouterDevice aTextLayouterDevice;
             aTextLayouterDevice.setFont(pInfo->mrFont);
 
             const basegfx::B2DRange aTextBoundRect(
diff --git a/svx/source/svdraw/svdotextpathdecomposition.cxx b/svx/source/svdraw/svdotextpathdecomposition.cxx
index a607d05c7800..81c25f9b3c6f 100644
--- a/svx/source/svdraw/svdotextpathdecomposition.cxx
+++ b/svx/source/svdraw/svdotextpathdecomposition.cxx
@@ -31,7 +31,7 @@
 #include <com/sun/star/i18n/BreakIterator.hpp>
 #include <comphelper/processfactory.hxx>
 #include <com/sun/star/i18n/CharacterIteratorMode.hpp>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/primitive2d/textprimitive2d.hxx>
 #include <basegfx/color/bcolor.hxx>
 
@@ -130,7 +130,7 @@ namespace
 
         double getDisplayLength(sal_Int32 nIndex, sal_Int32 nLength) const
         {
-            drawinglayer::primitive2d::TextLayouterDevice aTextLayouter;
+            drawinglayer::processor2d::TextLayouterDevice aTextLayouter;
             double fRetval(0.0);
 
             if(maFont.IsVertical())
@@ -201,7 +201,7 @@ namespace
 
         static double getParagraphTextLength(const ::std::vector< const impPathTextPortion* >& rTextPortions)
         {
-            drawinglayer::primitive2d::TextLayouterDevice aTextLayouter;
+            drawinglayer::processor2d::TextLayouterDevice aTextLayouter;
             double fRetval(0.0);
 
             for(const impPathTextPortion* pCandidate : rTextPortions)
@@ -328,13 +328,13 @@ namespace
                 if(pCandidate && pCandidate->getTextLength())
                 {
                     const drawinglayer::attribute::FontAttribute aCandidateFontAttribute(
-                        drawinglayer::primitive2d::getFontAttributeFromVclFont(
+                        drawinglayer::processor2d::getFontAttributeFromVclFont(
                             aFontScaling,
                             pCandidate->getFont(),
                             pCandidate->isRTL(),
                             false));
 
-                    drawinglayer::primitive2d::TextLayouterDevice aTextLayouter;
+                    drawinglayer::processor2d::TextLayouterDevice aTextLayouter;
                     aTextLayouter.setFont(pCandidate->getFont());
                     sal_Int32 nUsedTextLength(0);
 
diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx
index 633a991fc5c1..1d5e160e49ed 100644
--- a/sw/source/core/layout/paintfrm.cxx
+++ b/sw/source/core/layout/paintfrm.cxx
@@ -92,7 +92,7 @@
 #include <drawinglayer/primitive2d/discreteshadowprimitive2d.hxx>
 #include <drawinglayer/primitive2d/maskprimitive2d.hxx>
 #include <drawinglayer/primitive2d/textprimitive2d.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <drawinglayer/processor2d/baseprocessor2d.hxx>
 #include <drawinglayer/processor2d/processorfromoutputdevice.hxx>
 #include <svx/unoapi.hxx>
@@ -3666,7 +3666,7 @@ void SwColumnFrame::PaintBreak( ) const
     vcl::Font aFont = pOut->GetSettings().GetStyleSettings().GetToolFont();
     aFont.SetFontHeight( 8 * 20 );
     pOut->SetFont( aFont );
-    drawinglayer::attribute::FontAttribute aFontAttr = drawinglayer::primitive2d::getFontAttributeFromVclFont(
+    drawinglayer::attribute::FontAttribute aFontAttr = drawinglayer::processor2d::getFontAttributeFromVclFont(
             aFontSize, aFont, IsRightToLeft(), false );
 
     tools::Rectangle aTextRect;
diff --git a/sw/source/uibase/docvw/HeaderFooterWin.cxx b/sw/source/uibase/docvw/HeaderFooterWin.cxx
index 0c4ed113f6c7..5ec55732bada 100644
--- a/sw/source/uibase/docvw/HeaderFooterWin.cxx
+++ b/sw/source/uibase/docvw/HeaderFooterWin.cxx
@@ -35,8 +35,8 @@
 #include <drawinglayer/primitive2d/modifiedcolorprimitive2d.hxx>
 #include <drawinglayer/primitive2d/polygonprimitive2d.hxx>
 #include <drawinglayer/primitive2d/PolyPolygonColorPrimitive2D.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
 #include <drawinglayer/primitive2d/textprimitive2d.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <editeng/boxitem.hxx>
 #include <svx/hdft.hxx>
 #include <sfx2/bindings.hxx>
@@ -309,7 +309,7 @@ void SwHeaderFooterWin::PaintButton()
     // Create the text primitive
     basegfx::BColor aLineColor = SwViewOption::GetHeaderFooterMarkColor().getBColor();
     B2DVector aFontSize;
-    FontAttribute aFontAttr = drawinglayer::primitive2d::getFontAttributeFromVclFont(aFontSize, m_xVirDev->GetFont(), false, false);
+    FontAttribute aFontAttr = drawinglayer::processor2d::getFontAttributeFromVclFont(aFontSize, m_xVirDev->GetFont(), false, false);
 
     FontMetric aFontMetric = m_xVirDev->GetFontMetric(m_xVirDev->GetFont());
     double nTextOffsetY = aFontMetric.GetAscent() + TEXT_PADDING;
diff --git a/sw/source/uibase/docvw/UnfloatTableButton.cxx b/sw/source/uibase/docvw/UnfloatTableButton.cxx
index 24e6780e1ed2..9eae3bdf94cb 100644
--- a/sw/source/uibase/docvw/UnfloatTableButton.cxx
+++ b/sw/source/uibase/docvw/UnfloatTableButton.cxx
@@ -34,7 +34,7 @@
 #include <drawinglayer/primitive2d/textprimitive2d.hxx>
 #include <drawinglayer/processor2d/baseprocessor2d.hxx>
 #include <drawinglayer/attribute/fontattribute.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/processor2d/textlayoutdevice.hxx>
 #include <basegfx/matrix/b2dhommatrixtools.hxx>
 #include <drawinglayer/processor2d/processorfromoutputdevice.hxx>
 #include <basegfx/vector/b2dvector.hxx>
@@ -208,7 +208,7 @@ void UnfloatTableButton::PaintButton()
     basegfx::BColor aLineColor = SwViewOption::GetHeaderFooterMarkColor().getBColor();
     basegfx::B2DVector aFontSize;
     drawinglayer::attribute::FontAttribute aFontAttr
-        = drawinglayer::primitive2d::getFontAttributeFromVclFont(aFontSize, m_xVirDev->GetFont(),
+        = drawinglayer::processor2d::getFontAttributeFromVclFont(aFontSize, m_xVirDev->GetFont(),
                                                                  false, false);
 
     FontMetric aFontMetric = m_xVirDev->GetFontMetric(m_xVirDev->GetFont());
commit 48cd69915f3d0b7cce046ef3a405139a2c25ca58
Author:     Tomaž Vajngerl <tomaz.vajngerl at collabora.co.uk>
AuthorDate: Sat Jan 2 20:52:36 2021 +0900
Commit:     Tomaž Vajngerl <tomaz.vajngerl at collabora.co.uk>
CommitDate: Thu Feb 18 15:11:00 2021 +0900

    make BasePrimitive2D easier extensible with VisitingParameters
    
    BasePrimitive2D virtual methods get2DDecomposition and getB2DRange
    are used in many subclasses of BasePrimitive2D. If we want to
    extend the parameters that we want to pass to those classes (and
    we will need to in the future changes) we need to change all the
    subclasses too. So this commit intoduces VisitingParameters class,
    which holds the parameters that we want to pass, which avoids the
    need to extend the BasePrimitive2D API.
    
    The only member of VisitingParameters is ViewInformation2D, which
    was previously a parameter for both methods.
    
    Change-Id: I39afc28707f1511aafce4e8a84dbc45b84fc8cd5

diff --git a/drawinglayer/inc/primitive2d/cropprimitive2d.hxx b/drawinglayer/inc/primitive2d/cropprimitive2d.hxx
index 86297687ad5f..b0135ffb25e7 100644
--- a/drawinglayer/inc/primitive2d/cropprimitive2d.hxx
+++ b/drawinglayer/inc/primitive2d/cropprimitive2d.hxx
@@ -82,7 +82,7 @@ namespace drawinglayer::primitive2d
             virtual bool operator==(const BasePrimitive2D& rPrimitive) const override;
 
             /// local decomposition
-            virtual void get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const override;
+            virtual void get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const override;
 
             /// provide unique ID
             virtual sal_uInt32 getPrimitive2DID() const override;
diff --git a/drawinglayer/inc/primitive2d/texteffectprimitive2d.hxx b/drawinglayer/inc/primitive2d/texteffectprimitive2d.hxx
index 45a21f67dab8..1c4234719c05 100644
--- a/drawinglayer/inc/primitive2d/texteffectprimitive2d.hxx
+++ b/drawinglayer/inc/primitive2d/texteffectprimitive2d.hxx
@@ -57,9 +57,8 @@ private:
     basegfx::B2DHomMatrix maLastObjectToViewTransformation;
 
     /// create local decomposition
-    virtual void
-    create2DDecomposition(Primitive2DContainer& rContainer,
-                          const geometry::ViewInformation2D& rViewInformation) const override;
+    virtual void create2DDecomposition(Primitive2DContainer& rContainer,
+                                       VisitingParameters const& rParameters) const override;
 
 public:
     /// constructor
@@ -80,16 +79,14 @@ public:
         by a fixed discrete unit, thus the contained geometry needs only once be asked for its
         own basegfx::B2DRange
      */
-    virtual basegfx::B2DRange
-    getB2DRange(const geometry::ViewInformation2D& rViewInformation) const override;
+    virtual basegfx::B2DRange getB2DRange(VisitingParameters const& rParameters) const override;
 
     /// provide unique ID
     virtual sal_uInt32 getPrimitive2DID() const override;
 
     /// Override standard getDecomposition to be view-dependent here
-    virtual void
-    get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor,
-                       const geometry::ViewInformation2D& rViewInformation) const override;
+    virtual void get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor,
+                                    VisitingParameters const& rParameters) const override;
 };
 
 } // end of namespace primitive2d::drawinglayer
diff --git a/drawinglayer/inc/primitive2d/textlineprimitive2d.hxx b/drawinglayer/inc/primitive2d/textlineprimitive2d.hxx
index c84deefd8547..d8feee52e9ba 100644
--- a/drawinglayer/inc/primitive2d/textlineprimitive2d.hxx
+++ b/drawinglayer/inc/primitive2d/textlineprimitive2d.hxx
@@ -41,7 +41,7 @@ namespace drawinglayer::primitive2d
             basegfx::BColor                             maLineColor;
 
             /// local decomposition.
-            virtual void create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const override;
+            virtual void create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const override;
 
         public:
             /// constructor
diff --git a/drawinglayer/inc/primitive2d/textstrikeoutprimitive2d.hxx b/drawinglayer/inc/primitive2d/textstrikeoutprimitive2d.hxx
index 1843d5ef9f11..d1652f1ea1bf 100644
--- a/drawinglayer/inc/primitive2d/textstrikeoutprimitive2d.hxx
+++ b/drawinglayer/inc/primitive2d/textstrikeoutprimitive2d.hxx
@@ -68,7 +68,7 @@ namespace drawinglayer::primitive2d
             css::lang::Locale                       maLocale;
 
             /// local decomposition.
-            virtual void create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const override;
+            virtual void create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const override;
 
         public:
             /// constructor
@@ -105,7 +105,7 @@ namespace drawinglayer::primitive2d
             TextStrikeout                           meTextStrikeout;
 
             /// local decomposition.
-            virtual void create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const override;
+            virtual void create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const override;
 
         public:
             /// constructor
diff --git a/drawinglayer/inc/primitive2d/wallpaperprimitive2d.hxx b/drawinglayer/inc/primitive2d/wallpaperprimitive2d.hxx
index c92006b36db3..85754a28c255 100644
--- a/drawinglayer/inc/primitive2d/wallpaperprimitive2d.hxx
+++ b/drawinglayer/inc/primitive2d/wallpaperprimitive2d.hxx
@@ -47,7 +47,7 @@ namespace drawinglayer::primitive2d
             WallpaperStyle                      meWallpaperStyle;
 
             /// create local decomposition
-            virtual void create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const override;
+            virtual void create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const override;
 
         public:
             /// constructor
@@ -65,7 +65,7 @@ namespace drawinglayer::primitive2d
             virtual bool operator==(const BasePrimitive2D& rPrimitive) const override;
 
             /// get B2Drange
-            virtual basegfx::B2DRange getB2DRange(const geometry::ViewInformation2D& rViewInformation) const override;
+            virtual basegfx::B2DRange getB2DRange(VisitingParameters const & rParameters) const override;
 
             /// provide unique ID
             virtual sal_uInt32 getPrimitive2DID() const override;
diff --git a/drawinglayer/source/primitive2d/PolyPolygonColorPrimitive2D.cxx b/drawinglayer/source/primitive2d/PolyPolygonColorPrimitive2D.cxx
index aa48a965e692..7b588f2de0dc 100644
--- a/drawinglayer/source/primitive2d/PolyPolygonColorPrimitive2D.cxx
+++ b/drawinglayer/source/primitive2d/PolyPolygonColorPrimitive2D.cxx
@@ -48,8 +48,8 @@ bool PolyPolygonColorPrimitive2D::operator==(const BasePrimitive2D& rPrimitive)
     return false;
 }
 
-basegfx::B2DRange PolyPolygonColorPrimitive2D::getB2DRange(
-    const geometry::ViewInformation2D& /*rViewInformation*/) const
+basegfx::B2DRange
+PolyPolygonColorPrimitive2D::getB2DRange(VisitingParameters const& /*rParameters*/) const
 {
     // return range
     return basegfx::utils::getRange(getB2DPolyPolygon());
diff --git a/drawinglayer/source/primitive2d/PolyPolygonGradientPrimitive2D.cxx b/drawinglayer/source/primitive2d/PolyPolygonGradientPrimitive2D.cxx
index 076436b40655..f49d813a79a9 100644
--- a/drawinglayer/source/primitive2d/PolyPolygonGradientPrimitive2D.cxx
+++ b/drawinglayer/source/primitive2d/PolyPolygonGradientPrimitive2D.cxx
@@ -28,7 +28,7 @@ using namespace com::sun::star;
 namespace drawinglayer::primitive2d
 {
 void PolyPolygonGradientPrimitive2D::create2DDecomposition(
-    Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+    Primitive2DContainer& rContainer, VisitingParameters const& /*rParameters*/) const
 {
     if (!getFillGradient().isDefault())
     {
diff --git a/drawinglayer/source/primitive2d/PolyPolygonGraphicPrimitive2D.cxx b/drawinglayer/source/primitive2d/PolyPolygonGraphicPrimitive2D.cxx
index c857ba5c8e3d..1582393f54b5 100644
--- a/drawinglayer/source/primitive2d/PolyPolygonGraphicPrimitive2D.cxx
+++ b/drawinglayer/source/primitive2d/PolyPolygonGraphicPrimitive2D.cxx
@@ -31,7 +31,7 @@ using namespace com::sun::star;
 namespace drawinglayer::primitive2d
 {
 void PolyPolygonGraphicPrimitive2D::create2DDecomposition(
-    Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+    Primitive2DContainer& rContainer, VisitingParameters const& /*rParameters*/) const
 {
     if (getFillGraphic().isDefault())
         return;
diff --git a/drawinglayer/source/primitive2d/PolyPolygonHairlinePrimitive2D.cxx b/drawinglayer/source/primitive2d/PolyPolygonHairlinePrimitive2D.cxx
index e4c73f9191a5..db602d7f3606 100644
--- a/drawinglayer/source/primitive2d/PolyPolygonHairlinePrimitive2D.cxx
+++ b/drawinglayer/source/primitive2d/PolyPolygonHairlinePrimitive2D.cxx
@@ -28,7 +28,7 @@ using namespace com::sun::star;
 namespace drawinglayer::primitive2d
 {
 void PolyPolygonHairlinePrimitive2D::create2DDecomposition(
-    Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+    Primitive2DContainer& rContainer, VisitingParameters const& /*rParameters*/) const
 {
     const basegfx::B2DPolyPolygon aPolyPolygon(getB2DPolyPolygon());
     const sal_uInt32 nCount(aPolyPolygon.count());
@@ -65,8 +65,8 @@ bool PolyPolygonHairlinePrimitive2D::operator==(const BasePrimitive2D& rPrimitiv
     return false;
 }
 
-basegfx::B2DRange PolyPolygonHairlinePrimitive2D::getB2DRange(
-    const geometry::ViewInformation2D& /*rViewInformation*/) const
+basegfx::B2DRange
+PolyPolygonHairlinePrimitive2D::getB2DRange(VisitingParameters const& /*rParameters*/) const
 {
     // return range
     return basegfx::utils::getRange(getB2DPolyPolygon());
diff --git a/drawinglayer/source/primitive2d/PolyPolygonHatchPrimitive2D.cxx b/drawinglayer/source/primitive2d/PolyPolygonHatchPrimitive2D.cxx
index ad85c02f22c1..268abc1113ba 100644
--- a/drawinglayer/source/primitive2d/PolyPolygonHatchPrimitive2D.cxx
+++ b/drawinglayer/source/primitive2d/PolyPolygonHatchPrimitive2D.cxx
@@ -28,7 +28,7 @@ using namespace com::sun::star;
 namespace drawinglayer::primitive2d
 {
 void PolyPolygonHatchPrimitive2D::create2DDecomposition(
-    Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+    Primitive2DContainer& rContainer, VisitingParameters const& /*rParameters*/) const
 {
     if (!getFillHatch().isDefault())
     {
diff --git a/drawinglayer/source/primitive2d/PolyPolygonMarkerPrimitive2D.cxx b/drawinglayer/source/primitive2d/PolyPolygonMarkerPrimitive2D.cxx
index b545ec9465fa..dfd4a8abafc7 100644
--- a/drawinglayer/source/primitive2d/PolyPolygonMarkerPrimitive2D.cxx
+++ b/drawinglayer/source/primitive2d/PolyPolygonMarkerPrimitive2D.cxx
@@ -28,7 +28,7 @@ using namespace com::sun::star;
 namespace drawinglayer::primitive2d
 {
 void PolyPolygonMarkerPrimitive2D::create2DDecomposition(
-    Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+    Primitive2DContainer& rContainer, VisitingParameters const& /*rParameters*/) const
 {
     const basegfx::B2DPolyPolygon aPolyPolygon(getB2DPolyPolygon());
     const sal_uInt32 nCount(aPolyPolygon.count());
@@ -71,8 +71,8 @@ bool PolyPolygonMarkerPrimitive2D::operator==(const BasePrimitive2D& rPrimitive)
     return false;
 }
 
-basegfx::B2DRange PolyPolygonMarkerPrimitive2D::getB2DRange(
-    const geometry::ViewInformation2D& /*rViewInformation*/) const
+basegfx::B2DRange
+PolyPolygonMarkerPrimitive2D::getB2DRange(VisitingParameters const& /*rParameters*/) const
 {
     // return range
     return basegfx::utils::getRange(getB2DPolyPolygon());
diff --git a/drawinglayer/source/primitive2d/PolyPolygonSelectionPrimitive2D.cxx b/drawinglayer/source/primitive2d/PolyPolygonSelectionPrimitive2D.cxx
index 7be684c2f71e..6e098d6c2a9c 100644
--- a/drawinglayer/source/primitive2d/PolyPolygonSelectionPrimitive2D.cxx
+++ b/drawinglayer/source/primitive2d/PolyPolygonSelectionPrimitive2D.cxx
@@ -31,7 +31,7 @@ using namespace com::sun::star;
 namespace drawinglayer::primitive2d
 {
 void PolyPolygonSelectionPrimitive2D::create2DDecomposition(
-    Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+    Primitive2DContainer& rContainer, VisitingParameters const& /*rParameters*/) const
 {
     if (getTransparence() >= 1.0 || !getB2DPolyPolygon().count())
         return;
@@ -97,8 +97,8 @@ bool PolyPolygonSelectionPrimitive2D::operator==(const BasePrimitive2D& rPrimiti
     return false;
 }
 
-basegfx::B2DRange PolyPolygonSelectionPrimitive2D::getB2DRange(
-    const geometry::ViewInformation2D& rViewInformation) const
+basegfx::B2DRange
+PolyPolygonSelectionPrimitive2D::getB2DRange(VisitingParameters const& rParameters) const
 {
     basegfx::B2DRange aRetval(basegfx::utils::getRange(getB2DPolyPolygon()));
 
@@ -106,7 +106,8 @@ basegfx::B2DRange PolyPolygonSelectionPrimitive2D::getB2DRange(
     {
         // get the current DiscreteUnit (not sure if getDiscreteUnit() is updated here, better go safe way)
         const double fDiscreteUnit(
-            (rViewInformation.getInverseObjectToViewTransformation() * basegfx::B2DVector(1.0, 0.0))
+            (rParameters.getViewInformation().getInverseObjectToViewTransformation()
+             * basegfx::B2DVector(1.0, 0.0))
                 .getLength());
 
         aRetval.grow(fDiscreteUnit * getDiscreteGrow());
diff --git a/drawinglayer/source/primitive2d/PolyPolygonStrokePrimitive2D.cxx b/drawinglayer/source/primitive2d/PolyPolygonStrokePrimitive2D.cxx
index 53abec1138c3..2e1f93b7e208 100644
--- a/drawinglayer/source/primitive2d/PolyPolygonStrokePrimitive2D.cxx
+++ b/drawinglayer/source/primitive2d/PolyPolygonStrokePrimitive2D.cxx
@@ -28,7 +28,7 @@ using namespace com::sun::star;
 namespace drawinglayer::primitive2d
 {
 void PolyPolygonStrokePrimitive2D::create2DDecomposition(
-    Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+    Primitive2DContainer& rContainer, VisitingParameters const& /*rParameters*/) const
 {
     const basegfx::B2DPolyPolygon aPolyPolygon(getB2DPolyPolygon());
     const sal_uInt32 nCount(aPolyPolygon.count());
@@ -77,8 +77,8 @@ bool PolyPolygonStrokePrimitive2D::operator==(const BasePrimitive2D& rPrimitive)
     return false;
 }
 
-basegfx::B2DRange PolyPolygonStrokePrimitive2D::getB2DRange(
-    const geometry::ViewInformation2D& /*rViewInformation*/) const
+basegfx::B2DRange
+PolyPolygonStrokePrimitive2D::getB2DRange(VisitingParameters const& /*rParameters*/) const
 {
     // get range of it (subdivided)
     basegfx::B2DRange aRetval(basegfx::utils::getRange(getB2DPolyPolygon()));
diff --git a/drawinglayer/source/primitive2d/Primitive2DContainer.cxx b/drawinglayer/source/primitive2d/Primitive2DContainer.cxx
index 3ae4a9b3e3c4..d4998c442ce8 100644
--- a/drawinglayer/source/primitive2d/Primitive2DContainer.cxx
+++ b/drawinglayer/source/primitive2d/Primitive2DContainer.cxx
@@ -48,8 +48,7 @@ Primitive2DContainer Primitive2DContainer::maybeInvert(bool bInvert) const
 }
 
 // get B2DRange from a given Primitive2DSequence
-basegfx::B2DRange
-Primitive2DContainer::getB2DRange(const geometry::ViewInformation2D& aViewInformation) const
+basegfx::B2DRange Primitive2DContainer::getB2DRange(VisitingParameters const& rParameters) const
 {
     basegfx::B2DRange aRetval;
 
@@ -59,7 +58,7 @@ Primitive2DContainer::getB2DRange(const geometry::ViewInformation2D& aViewInform
 
         for (sal_Int32 a(0); a < nCount; a++)
         {
-            aRetval.expand(getB2DRangeFromPrimitive2DReference((*this)[a], aViewInformation));
+            aRetval.expand(getB2DRangeFromPrimitive2DReference((*this)[a], rParameters));
         }
     }
 
diff --git a/drawinglayer/source/primitive2d/Tools.cxx b/drawinglayer/source/primitive2d/Tools.cxx
index 7db3a94c8d04..2da6d80e82e9 100644
--- a/drawinglayer/source/primitive2d/Tools.cxx
+++ b/drawinglayer/source/primitive2d/Tools.cxx
@@ -28,9 +28,8 @@ using namespace css;
 namespace drawinglayer::primitive2d
 {
 // get B2DRange from a given Primitive2DReference
-basegfx::B2DRange
-getB2DRangeFromPrimitive2DReference(const Primitive2DReference& rCandidate,
-                                    const geometry::ViewInformation2D& aViewInformation)
+basegfx::B2DRange getB2DRangeFromPrimitive2DReference(const Primitive2DReference& rCandidate,
+                                                      VisitingParameters const& rParameters)
 {
     basegfx::B2DRange aRetval;
 
@@ -42,13 +41,13 @@ getB2DRangeFromPrimitive2DReference(const Primitive2DReference& rCandidate,
         if (pCandidate)
         {
             // use it if possible
-            aRetval.expand(pCandidate->getB2DRange(aViewInformation));
+            aRetval.expand(pCandidate->getB2DRange(rParameters));
         }
         else
         {
             // use UNO API call instead
             const uno::Sequence<beans::PropertyValue>& rViewParameters(
-                aViewInformation.getViewInformationSequence());
+                rParameters.getViewInformation().getViewInformationSequence());
             aRetval.expand(basegfx::unotools::b2DRectangleFromRealRectangle2D(
                 rCandidate->getRange(rViewParameters)));
         }
diff --git a/drawinglayer/source/primitive2d/animatedprimitive2d.cxx b/drawinglayer/source/primitive2d/animatedprimitive2d.cxx
index d2c8d4a6571a..aa2bf7506161 100644
--- a/drawinglayer/source/primitive2d/animatedprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/animatedprimitive2d.cxx
@@ -62,12 +62,12 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        void AnimatedSwitchPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void AnimatedSwitchPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             if(getChildren().empty())
                 return;
 
-            const double fState(getAnimationEntry().getStateAtTime(rViewInformation.getViewTime()));
+            const double fState(getAnimationEntry().getStateAtTime(rParameters.getViewInformation().getViewTime()));
             const sal_uInt32 nLen(getChildren().size());
             sal_uInt32 nIndex(basegfx::fround(fState * static_cast<double>(nLen)));
 
@@ -95,11 +95,11 @@ namespace drawinglayer::primitive2d
         {
         }
 
-        void AnimatedBlinkPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void AnimatedBlinkPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             if(!getChildren().empty())
             {
-                const double fState(getAnimationEntry().getStateAtTime(rViewInformation.getViewTime()));
+                const double fState(getAnimationEntry().getStateAtTime(rParameters.getViewInformation().getViewTime()));
 
                 if(fState < 0.5)
                 {
@@ -133,13 +133,13 @@ namespace drawinglayer::primitive2d
             }
         }
 
-        void AnimatedInterpolatePrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void AnimatedInterpolatePrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             const sal_uInt32 nSize(maMatrixStack.size());
 
             if(nSize)
             {
-                double fState(getAnimationEntry().getStateAtTime(rViewInformation.getViewTime()));
+                double fState(getAnimationEntry().getStateAtTime(rParameters.getViewInformation().getViewTime()));
 
                 if(fState < 0.0)
                 {
diff --git a/drawinglayer/source/primitive2d/backgroundcolorprimitive2d.cxx b/drawinglayer/source/primitive2d/backgroundcolorprimitive2d.cxx
index ba0f47193b49..d8f7be330310 100644
--- a/drawinglayer/source/primitive2d/backgroundcolorprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/backgroundcolorprimitive2d.cxx
@@ -30,8 +30,10 @@ using namespace com::sun::star;
 
 namespace drawinglayer::primitive2d
 {
-        void BackgroundColorPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void BackgroundColorPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
+            auto const & rViewInformation = rParameters.getViewInformation();
+
             if(!rViewInformation.getViewport().isEmpty())
             {
                 const basegfx::B2DPolygon aOutline(basegfx::utils::createPolygonFromRect(rViewInformation.getViewport()));
@@ -61,17 +63,17 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange BackgroundColorPrimitive2D::getB2DRange(const geometry::ViewInformation2D& rViewInformation) const
+        basegfx::B2DRange BackgroundColorPrimitive2D::getB2DRange(VisitingParameters const & rParameters) const
         {
             // always as big as the view
-            return rViewInformation.getViewport();
+            return rParameters.getViewInformation().getViewport();
         }
 
-        void BackgroundColorPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void BackgroundColorPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             ::osl::MutexGuard aGuard( m_aMutex );
 
-            if(!getBuffered2DDecomposition().empty() && (maLastViewport != rViewInformation.getViewport()))
+            if(!getBuffered2DDecomposition().empty() && (maLastViewport != rParameters.getViewInformation().getViewport()))
             {
                 // conditions of last local decomposition have changed, delete
                 const_cast< BackgroundColorPrimitive2D* >(this)->setBuffered2DDecomposition(Primitive2DContainer());
@@ -80,11 +82,11 @@ namespace drawinglayer::primitive2d
             if(getBuffered2DDecomposition().empty())
             {
                 // remember ViewRange
-                const_cast< BackgroundColorPrimitive2D* >(this)->maLastViewport = rViewInformation.getViewport();
+                const_cast< BackgroundColorPrimitive2D* >(this)->maLastViewport = rParameters.getViewInformation().getViewport();
             }
 
             // use parent implementation
-            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rViewInformation);
+            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rParameters);
         }
 
         // provide unique ID
diff --git a/drawinglayer/source/primitive2d/baseprimitive2d.cxx b/drawinglayer/source/primitive2d/baseprimitive2d.cxx
index 752bc3063a3b..b809574116cd 100644
--- a/drawinglayer/source/primitive2d/baseprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/baseprimitive2d.cxx
@@ -48,55 +48,59 @@ namespace
 class B2DRangeVisitor : public Primitive2DDecompositionVisitor
 {
 public:
-    const geometry::ViewInformation2D& mrViewInformation;
+    VisitingParameters const& mrParameters;
     basegfx::B2DRange maRetval;
-    B2DRangeVisitor(const geometry::ViewInformation2D& rViewInformation)
-        : mrViewInformation(rViewInformation)
+
+    B2DRangeVisitor(VisitingParameters const& rParameters)
+        : mrParameters(rParameters)
     {
     }
-    virtual void append(const Primitive2DReference& r) override
+
+    virtual void append(const Primitive2DReference& rReference) override
     {
-        maRetval.expand(getB2DRangeFromPrimitive2DReference(r, mrViewInformation));
+        maRetval.expand(getB2DRangeFromPrimitive2DReference(rReference, mrParameters));
     }
-    virtual void append(const Primitive2DContainer& r) override
+
+    virtual void append(const Primitive2DContainer& rReference) override
     {
-        maRetval.expand(r.getB2DRange(mrViewInformation));
+        maRetval.expand(rReference.getB2DRange(mrParameters));
     }
-    virtual void append(Primitive2DContainer&& r) override
+
+    virtual void append(Primitive2DContainer&& rReference) override
     {
-        maRetval.expand(r.getB2DRange(mrViewInformation));
+        maRetval.expand(rReference.getB2DRange(mrParameters));
     }
 };
 }
 
-basegfx::B2DRange
-BasePrimitive2D::getB2DRange(const geometry::ViewInformation2D& rViewInformation) const
+basegfx::B2DRange BasePrimitive2D::getB2DRange(VisitingParameters const& rParameters) const
 {
-    B2DRangeVisitor aVisitor(rViewInformation);
-    get2DDecomposition(aVisitor, rViewInformation);
+    B2DRangeVisitor aVisitor(rParameters);
+    get2DDecomposition(aVisitor, rParameters);
     return aVisitor.maRetval;
 }
 
-void BasePrimitive2D::get2DDecomposition(
-    Primitive2DDecompositionVisitor& /*rVisitor*/,
-    const geometry::ViewInformation2D& /*rViewInformation*/) const
+void BasePrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& /*rVisitor*/,
+                                         VisitingParameters const& /*rParameters*/) const
 {
 }
 
 css::uno::Sequence<::css::uno::Reference<::css::graphic::XPrimitive2D>> SAL_CALL
 BasePrimitive2D::getDecomposition(const uno::Sequence<beans::PropertyValue>& rViewParameters)
 {
-    const geometry::ViewInformation2D aViewInformation(rViewParameters);
     Primitive2DContainer aContainer;
-    get2DDecomposition(aContainer, aViewInformation);
+    geometry::ViewInformation2D aViewInformation2D(rViewParameters);
+    VisitingParameters aParameters(aViewInformation2D);
+    get2DDecomposition(aContainer, aParameters);
     return comphelper::containerToSequence(aContainer);
 }
 
 css::geometry::RealRectangle2D SAL_CALL
 BasePrimitive2D::getRange(const uno::Sequence<beans::PropertyValue>& rViewParameters)
 {
-    const geometry::ViewInformation2D aViewInformation(rViewParameters);
-    return basegfx::unotools::rectangle2DFromB2DRectangle(getB2DRange(aViewInformation));
+    geometry::ViewInformation2D aViewInformation2D(rViewParameters);
+    VisitingParameters aParameters(aViewInformation2D);
+    return basegfx::unotools::rectangle2DFromB2DRectangle(getB2DRange(aParameters));
 }
 
 sal_Int64 SAL_CALL BasePrimitive2D::estimateUsage()
@@ -111,17 +115,16 @@ BufferedDecompositionPrimitive2D::BufferedDecompositionPrimitive2D()
 }
 
 void BufferedDecompositionPrimitive2D::get2DDecomposition(
-    Primitive2DDecompositionVisitor& rVisitor,
-    const geometry::ViewInformation2D& rViewInformation) const
+    Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const& rParameters) const
 {
     ::osl::MutexGuard aGuard(m_aMutex);
 
     if (getBuffered2DDecomposition().empty())
     {
         Primitive2DContainer aNewSequence;
-        create2DDecomposition(aNewSequence, rViewInformation);
-        const_cast<BufferedDecompositionPrimitive2D*>(this)->setBuffered2DDecomposition(
-            aNewSequence);
+        create2DDecomposition(aNewSequence, rParameters);
+        auto* pMutableThis = const_cast<BufferedDecompositionPrimitive2D*>(this);
+        pMutableThis->setBuffered2DDecomposition(aNewSequence);
     }
 
     rVisitor.append(getBuffered2DDecomposition());
diff --git a/drawinglayer/source/primitive2d/bitmapprimitive2d.cxx b/drawinglayer/source/primitive2d/bitmapprimitive2d.cxx
index f495d531d8ff..74e7fb0c68a9 100644
--- a/drawinglayer/source/primitive2d/bitmapprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/bitmapprimitive2d.cxx
@@ -45,8 +45,7 @@ bool BitmapPrimitive2D::operator==(const BasePrimitive2D& rPrimitive) const
     return false;
 }
 
-basegfx::B2DRange
-BitmapPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+basegfx::B2DRange BitmapPrimitive2D::getB2DRange(VisitingParameters const& /*rParameters*/) const
 {
     basegfx::B2DRange aRetval(0.0, 0.0, 1.0, 1.0);
     aRetval.transform(maTransform);
diff --git a/drawinglayer/source/primitive2d/borderlineprimitive2d.cxx b/drawinglayer/source/primitive2d/borderlineprimitive2d.cxx
index b264e2c028af..ce6572831234 100644
--- a/drawinglayer/source/primitive2d/borderlineprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/borderlineprimitive2d.cxx
@@ -112,7 +112,7 @@ namespace drawinglayer::primitive2d
             return fRetval;
         }
 
-        void BorderLinePrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void BorderLinePrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & /*rParameters*/) const
         {
             if (getStart().equal(getEnd()) || getBorderLines().empty())
                 return;
diff --git a/drawinglayer/source/primitive2d/controlprimitive2d.cxx b/drawinglayer/source/primitive2d/controlprimitive2d.cxx
index 3f20baa1351f..1d947661054b 100644
--- a/drawinglayer/source/primitive2d/controlprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/controlprimitive2d.cxx
@@ -75,11 +75,13 @@ namespace drawinglayer::primitive2d
             }
         }
 
-        Primitive2DReference ControlPrimitive2D::createBitmapDecomposition(const geometry::ViewInformation2D& rViewInformation) const
+        Primitive2DReference ControlPrimitive2D::createBitmapDecomposition(VisitingParameters const & rParameters) const
         {
             Primitive2DReference xRetval;
             const uno::Reference< awt::XControl >& rXControl(getXControl());
 
+            auto const & rViewInformation = rParameters.getViewInformation();
+
             if(rXControl.is())
             {
                 uno::Reference< awt::XWindow > xControlWindow(rXControl, uno::UNO_QUERY);
@@ -236,11 +238,11 @@ namespace drawinglayer::primitive2d
             return xRetval;
         }
 
-        void ControlPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void ControlPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
             // try to create a bitmap decomposition. If that fails for some reason,
             // at least create a replacement decomposition.
-            Primitive2DReference xReference(createBitmapDecomposition(rViewInformation));
+            Primitive2DReference xReference(createBitmapDecomposition(rParameters));
 
             if(!xReference.is())
             {
@@ -320,7 +322,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange ControlPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+        basegfx::B2DRange ControlPrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             // simply derivate from unit range
             basegfx::B2DRange aRetval(0.0, 0.0, 1.0, 1.0);
@@ -328,12 +330,12 @@ namespace drawinglayer::primitive2d
             return aRetval;
         }
 
-        void ControlPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void ControlPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             // this primitive is view-dependent related to the scaling. If scaling has changed,
             // destroy existing decomposition. To detect change, use size of unit size in view coordinates
             ::osl::MutexGuard aGuard( m_aMutex );
-            const basegfx::B2DVector aNewScaling(rViewInformation.getObjectToViewTransformation() * basegfx::B2DVector(1.0, 1.0));
+            const basegfx::B2DVector aNewScaling(rParameters.getViewInformation().getObjectToViewTransformation() * basegfx::B2DVector(1.0, 1.0));
 
             if(!getBuffered2DDecomposition().empty())
             {
@@ -351,7 +353,7 @@ namespace drawinglayer::primitive2d
             }
 
             // use parent implementation
-            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rViewInformation);
+            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rParameters);
         }
 
         // provide unique ID
diff --git a/drawinglayer/source/primitive2d/cropprimitive2d.cxx b/drawinglayer/source/primitive2d/cropprimitive2d.cxx
index 2d780ac2645c..6ddfe46b7980 100644
--- a/drawinglayer/source/primitive2d/cropprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/cropprimitive2d.cxx
@@ -63,7 +63,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        void CropPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void CropPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & /*rParameters*/) const
         {
             if(getChildren().empty())
                 return;
diff --git a/drawinglayer/source/primitive2d/discretebitmapprimitive2d.cxx b/drawinglayer/source/primitive2d/discretebitmapprimitive2d.cxx
index 17d6f2301a43..f33a638077c0 100644
--- a/drawinglayer/source/primitive2d/discretebitmapprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/discretebitmapprimitive2d.cxx
@@ -25,7 +25,7 @@
 
 namespace drawinglayer::primitive2d
 {
-        void DiscreteBitmapPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void DiscreteBitmapPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & /*rParameters*/) const
         {
             // use getViewTransformation() and getObjectTransformation() from
             // ObjectAndViewTransformationDependentPrimitive2D to create a BitmapPrimitive2D
diff --git a/drawinglayer/source/primitive2d/discreteshadowprimitive2d.cxx b/drawinglayer/source/primitive2d/discreteshadowprimitive2d.cxx
index 3100db147345..d80f895f1b6b 100644
--- a/drawinglayer/source/primitive2d/discreteshadowprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/discreteshadowprimitive2d.cxx
@@ -157,7 +157,7 @@ namespace drawinglayer::primitive2d
 
 namespace drawinglayer::primitive2d
 {
-        void DiscreteShadowPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void DiscreteShadowPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & /*rParameters*/) const
         {
             Primitive2DContainer xRetval;
 
@@ -284,7 +284,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange DiscreteShadowPrimitive2D::getB2DRange(const geometry::ViewInformation2D& rViewInformation) const
+        basegfx::B2DRange DiscreteShadowPrimitive2D::getB2DRange(VisitingParameters const & rParameters) const
         {
             if(getDiscreteShadow().getBitmapEx().IsEmpty())
             {
@@ -298,7 +298,7 @@ namespace drawinglayer::primitive2d
                 aRetval.transform(getTransform());
 
                 // extract discrete shadow size and grow
-                const basegfx::B2DVector aScale(rViewInformation.getViewTransformation() * basegfx::B2DVector(1.0, 1.0));
+                const basegfx::B2DVector aScale(rParameters.getViewInformation().getViewTransformation() * basegfx::B2DVector(1.0, 1.0));
                 const sal_Int32 nQuarter((getDiscreteShadow().getBitmapEx().GetSizePixel().Width() - 3) >> 2);
                 const double fGrowX((1.0 / aScale.getX()) * nQuarter);
                 const double fGrowY((1.0 / aScale.getY()) * nQuarter);
diff --git a/drawinglayer/source/primitive2d/embedded3dprimitive2d.cxx b/drawinglayer/source/primitive2d/embedded3dprimitive2d.cxx
index e38afeb4d612..c7fbaace2d16 100644
--- a/drawinglayer/source/primitive2d/embedded3dprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/embedded3dprimitive2d.cxx
@@ -60,10 +60,10 @@ namespace drawinglayer::primitive2d
             return !maShadowPrimitives.empty();
         }
 
-        void Embedded3DPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void Embedded3DPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
             // use info to create a yellow 2d rectangle, similar to empty 3d scenes and/or groups
-            const basegfx::B2DRange aLocal2DRange(getB2DRange(rViewInformation));
+            const basegfx::B2DRange aLocal2DRange(getB2DRange(rParameters));
             const basegfx::B2DPolygon aOutline(basegfx::utils::createPolygonFromRect(aLocal2DRange));
             const basegfx::BColor aYellow(1.0, 1.0, 0.0);
             rContainer.push_back(new PolygonHairlinePrimitive2D(aOutline, aYellow));
@@ -107,7 +107,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange Embedded3DPrimitive2D::getB2DRange(const geometry::ViewInformation2D& rViewInformation) const
+        basegfx::B2DRange Embedded3DPrimitive2D::getB2DRange(VisitingParameters const & rParameters) const
         {
             if(maB2DRange.isEmpty())
             {
@@ -125,7 +125,7 @@ namespace drawinglayer::primitive2d
                 // taken into account
                 if(impGetShadow3D())
                 {
-                    const basegfx::B2DRange aShadow2DRange(maShadowPrimitives.getB2DRange(rViewInformation));
+                    const basegfx::B2DRange aShadow2DRange(maShadowPrimitives.getB2DRange(rParameters));
 
                     if(!aShadow2DRange.isEmpty())
                     {
diff --git a/drawinglayer/source/primitive2d/epsprimitive2d.cxx b/drawinglayer/source/primitive2d/epsprimitive2d.cxx
index b519547c00d7..f5bb98e4171d 100644
--- a/drawinglayer/source/primitive2d/epsprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/epsprimitive2d.cxx
@@ -23,7 +23,7 @@
 
 namespace drawinglayer::primitive2d
 {
-        void EpsPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void EpsPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & /*rParameters*/) const
         {
             const GDIMetaFile& rSubstituteContent = getMetaFile();
 
@@ -65,7 +65,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange EpsPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+        basegfx::B2DRange EpsPrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             // use own implementation to quickly answer the getB2DRange question.
             basegfx::B2DRange aRetval(0.0, 0.0, 1.0, 1.0);
diff --git a/drawinglayer/source/primitive2d/fillgradientprimitive2d.cxx b/drawinglayer/source/primitive2d/fillgradientprimitive2d.cxx
index fba740e833c5..0851223505ab 100644
--- a/drawinglayer/source/primitive2d/fillgradientprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/fillgradientprimitive2d.cxx
@@ -269,7 +269,7 @@ namespace drawinglayer::primitive2d
             }
         }
 
-        void FillGradientPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void FillGradientPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & /*rParameters*/) const
         {
             // default creates overlapping fill which works with AntiAliasing and without.
             // The non-overlapping version does not create single filled polygons, but
@@ -319,7 +319,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange FillGradientPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+        basegfx::B2DRange FillGradientPrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             // return the geometrically visible area
             return getOutputRange();
diff --git a/drawinglayer/source/primitive2d/fillgraphicprimitive2d.cxx b/drawinglayer/source/primitive2d/fillgraphicprimitive2d.cxx
index ee67bd305810..bf346c83a43d 100644
--- a/drawinglayer/source/primitive2d/fillgraphicprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/fillgraphicprimitive2d.cxx
@@ -33,7 +33,7 @@ using namespace com::sun::star;
 
 namespace drawinglayer::primitive2d
 {
-        void FillGraphicPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void FillGraphicPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & /*rParameters*/) const
         {
             const attribute::FillGraphicAttribute& rAttribute = getFillGraphic();
 
@@ -112,7 +112,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange FillGraphicPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+        basegfx::B2DRange FillGraphicPrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             // return range of it
             basegfx::B2DPolygon aPolygon(basegfx::utils::createUnitPolygon());
diff --git a/drawinglayer/source/primitive2d/fillhatchprimitive2d.cxx b/drawinglayer/source/primitive2d/fillhatchprimitive2d.cxx
index 9c4ef03bfba3..3802354e0c95 100644
--- a/drawinglayer/source/primitive2d/fillhatchprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/fillhatchprimitive2d.cxx
@@ -32,7 +32,7 @@ using namespace com::sun::star;
 
 namespace drawinglayer::primitive2d
 {
-        void FillHatchPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void FillHatchPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & /*rParameters*/) const
         {
             if(getFillHatch().isDefault())
                 return;
@@ -167,13 +167,13 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange FillHatchPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+        basegfx::B2DRange FillHatchPrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             // return the geometrically visible area
             return getOutputRange();
         }
 
-        void FillHatchPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void FillHatchPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             ::osl::MutexGuard aGuard( m_aMutex );
             bool bAdaptDistance(0 != getFillHatch().getMinimalDiscreteDistance());
@@ -181,12 +181,12 @@ namespace drawinglayer::primitive2d
             if(bAdaptDistance)
             {
                 // behave view-dependent
-                DiscreteMetricDependentPrimitive2D::get2DDecomposition(rVisitor, rViewInformation);
+                DiscreteMetricDependentPrimitive2D::get2DDecomposition(rVisitor, rParameters);
             }
             else
             {
                 // behave view-independent
-                BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rViewInformation);
+                BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rParameters);
             }
         }
 
diff --git a/drawinglayer/source/primitive2d/glowprimitive2d.cxx b/drawinglayer/source/primitive2d/glowprimitive2d.cxx
index f6dfab2b3c45..83c9aa223044 100644
--- a/drawinglayer/source/primitive2d/glowprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/glowprimitive2d.cxx
@@ -45,10 +45,9 @@ bool GlowPrimitive2D::operator==(const BasePrimitive2D& rPrimitive) const
     return false;
 }
 
-basegfx::B2DRange
-GlowPrimitive2D::getB2DRange(const geometry::ViewInformation2D& rViewInformation) const
+basegfx::B2DRange GlowPrimitive2D::getB2DRange(VisitingParameters const& rParameters) const
 {
-    basegfx::B2DRange aRetval(GroupPrimitive2D::getB2DRange(rViewInformation));
+    basegfx::B2DRange aRetval(GroupPrimitive2D::getB2DRange(rParameters));
     // We need additional space for the glow from all sides
     aRetval.grow(getGlowRadius());
     return aRetval;
diff --git a/drawinglayer/source/primitive2d/graphicprimitive2d.cxx b/drawinglayer/source/primitive2d/graphicprimitive2d.cxx
index 8805d99e49db..f25d70372163 100644
--- a/drawinglayer/source/primitive2d/graphicprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/graphicprimitive2d.cxx
@@ -31,7 +31,7 @@
 namespace drawinglayer::primitive2d
 {
 void GraphicPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer,
-                                               const geometry::ViewInformation2D&) const
+                                               VisitingParameters const& /*rParameters*/) const
 {
     if (0 == getGraphicAttr().GetAlpha())
     {
@@ -204,8 +204,7 @@ bool GraphicPrimitive2D::operator==(const BasePrimitive2D& rPrimitive) const
     return false;
 }
 
-basegfx::B2DRange
-GraphicPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+basegfx::B2DRange GraphicPrimitive2D::getB2DRange(VisitingParameters const& /*rParameters*/) const
 {
     basegfx::B2DRange aRetval(0.0, 0.0, 1.0, 1.0);
     aRetval.transform(getTransform());
diff --git a/drawinglayer/source/primitive2d/graphicprimitivehelper2d.cxx b/drawinglayer/source/primitive2d/graphicprimitivehelper2d.cxx
index 9c441dc0d876..858668d9e1b9 100644
--- a/drawinglayer/source/primitive2d/graphicprimitivehelper2d.cxx
+++ b/drawinglayer/source/primitive2d/graphicprimitivehelper2d.cxx
@@ -351,7 +351,7 @@ namespace drawinglayer::primitive2d
             virtual bool operator==(const BasePrimitive2D& rPrimitive) const override;
 
             /// override to deliver the correct expected frame dependent of timing
-            virtual void get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const override;
+            virtual void get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & /*rParameters*/) const override;
         };
 
         }
@@ -422,13 +422,13 @@ namespace drawinglayer::primitive2d
                 && maGraphic == pCompare->maGraphic);
         }
 
-        void AnimatedGraphicPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void AnimatedGraphicPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             if (!isValidData())
                 return;
 
             Primitive2DReference aRetval;
-            const double fState(getAnimationEntry().getStateAtTime(rViewInformation.getViewTime()));
+            const double fState(getAnimationEntry().getStateAtTime(rParameters.getViewInformation().getViewTime()));
             const sal_uInt32 nLen(maAnimation.Count());
             sal_uInt32 nIndex(basegfx::fround(fState * static_cast<double>(nLen)));
 
diff --git a/drawinglayer/source/primitive2d/gridprimitive2d.cxx b/drawinglayer/source/primitive2d/gridprimitive2d.cxx
index e1d0841678e2..1d553d542a75 100644
--- a/drawinglayer/source/primitive2d/gridprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/gridprimitive2d.cxx
@@ -30,8 +30,10 @@ using namespace com::sun::star;
 
 namespace drawinglayer::primitive2d
 {
-        void GridPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void GridPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
+            auto const & rViewInformation = rParameters.getViewInformation();
+
             if(!(!rViewInformation.getViewport().isEmpty() && getWidth() > 0.0 && getHeight() > 0.0))
                 return;
 
@@ -294,25 +296,27 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange GridPrimitive2D::getB2DRange(const geometry::ViewInformation2D& rViewInformation) const
+        basegfx::B2DRange GridPrimitive2D::getB2DRange(VisitingParameters const & rParameters) const
         {
             // get object's range
             basegfx::B2DRange aUnitRange(0.0, 0.0, 1.0, 1.0);
             aUnitRange.transform(getTransform());
 
             // intersect with visible part
-            aUnitRange.intersect(rViewInformation.getViewport());
+            aUnitRange.intersect(rParameters.getViewInformation().getViewport());
 
             return aUnitRange;
         }
 
-        void GridPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void GridPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             ::osl::MutexGuard aGuard( m_aMutex );
+            auto const & rViewInformation = rParameters.getViewInformation();
 
             if(!getBuffered2DDecomposition().empty())
             {
-                if(maLastViewport != rViewInformation.getViewport() || maLastObjectToViewTransformation != rViewInformation.getObjectToViewTransformation())
+                if( maLastViewport != rViewInformation.getViewport() ||
+                    maLastObjectToViewTransformation != rViewInformation.getObjectToViewTransformation())
                 {
                     // conditions of last local decomposition have changed, delete
                     const_cast< GridPrimitive2D* >(this)->setBuffered2DDecomposition(Primitive2DContainer());
@@ -327,7 +331,7 @@ namespace drawinglayer::primitive2d
             }
 
             // use parent implementation
-            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rViewInformation);
+            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rParameters);
         }
 
         // provide unique ID
diff --git a/drawinglayer/source/primitive2d/groupprimitive2d.cxx b/drawinglayer/source/primitive2d/groupprimitive2d.cxx
index 63f21f842b2b..73392f1449aa 100644
--- a/drawinglayer/source/primitive2d/groupprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/groupprimitive2d.cxx
@@ -49,7 +49,7 @@ namespace drawinglayer::primitive2d
         }
 
         /// default: just return children, so all renderers not supporting group will use its content
-        void GroupPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void GroupPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & /*rParameters*/) const
         {
             getChildren(rVisitor);
         }
diff --git a/drawinglayer/source/primitive2d/helplineprimitive2d.cxx b/drawinglayer/source/primitive2d/helplineprimitive2d.cxx
index 86c3b88ca6d5..405bd5afa112 100644
--- a/drawinglayer/source/primitive2d/helplineprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/helplineprimitive2d.cxx
@@ -30,8 +30,10 @@ using namespace com::sun::star;
 
 namespace drawinglayer::primitive2d
 {
-        void HelplinePrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void HelplinePrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
+            auto const & rViewInformation = rParameters.getViewInformation();
+
             if(rViewInformation.getViewport().isEmpty() || getDirection().equalZero())
                 return;
 
@@ -159,9 +161,10 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        void HelplinePrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void HelplinePrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             ::osl::MutexGuard aGuard( m_aMutex );
+            auto const & rViewInformation = rParameters.getViewInformation();
 
             if(!getBuffered2DDecomposition().empty())
             {
@@ -180,7 +183,7 @@ namespace drawinglayer::primitive2d
             }
 
             // use parent implementation
-            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rViewInformation);
+            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rParameters);
         }
 
         // provide unique ID
diff --git a/drawinglayer/source/primitive2d/hiddengeometryprimitive2d.cxx b/drawinglayer/source/primitive2d/hiddengeometryprimitive2d.cxx
index cdce8a750274..f06e006ce455 100644
--- a/drawinglayer/source/primitive2d/hiddengeometryprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/hiddengeometryprimitive2d.cxx
@@ -32,12 +32,13 @@ namespace drawinglayer::primitive2d
         {
         }
 
-        basegfx::B2DRange HiddenGeometryPrimitive2D::getB2DRange(const geometry::ViewInformation2D& rViewInformation) const
+        basegfx::B2DRange HiddenGeometryPrimitive2D::getB2DRange(VisitingParameters const & rParameters) const
         {
-            return getChildren().getB2DRange(rViewInformation);
+            return getChildren().getB2DRange(rParameters);
         }
 
-        void HiddenGeometryPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& /*rVisitor*/, const geometry::ViewInformation2D& /*rViewInformation*/) const
+        void HiddenGeometryPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& /*rVisitor*/,
+                                                           VisitingParameters const & /*rParameters*/) const
         {
         }
 
diff --git a/drawinglayer/source/primitive2d/markerarrayprimitive2d.cxx b/drawinglayer/source/primitive2d/markerarrayprimitive2d.cxx
index a95e42cfecad..d36983e16ec9 100644
--- a/drawinglayer/source/primitive2d/markerarrayprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/markerarrayprimitive2d.cxx
@@ -30,7 +30,7 @@ using namespace com::sun::star;
 
 namespace drawinglayer::primitive2d
 {
-        void MarkerArrayPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void MarkerArrayPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
             const std::vector< basegfx::B2DPoint >& rPositions = getPositions();
             const sal_uInt32 nMarkerCount(rPositions.size());
@@ -45,7 +45,7 @@ namespace drawinglayer::primitive2d
                 return;
 
             // get logic half pixel size
-            basegfx::B2DVector aLogicHalfSize(rViewInformation.getInverseObjectToViewTransformation() *
+            basegfx::B2DVector aLogicHalfSize(rParameters.getViewInformation().getInverseObjectToViewTransformation() *
                 basegfx::B2DVector(aBitmapSize.getWidth() - 1.0, aBitmapSize.getHeight() - 1.0));
 
             // use half size for expand
@@ -91,7 +91,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange MarkerArrayPrimitive2D::getB2DRange(const geometry::ViewInformation2D& rViewInformation) const
+        basegfx::B2DRange MarkerArrayPrimitive2D::getB2DRange(VisitingParameters const & rParameters) const
         {
             basegfx::B2DRange aRetval;
 
@@ -111,7 +111,7 @@ namespace drawinglayer::primitive2d
                     if(aBitmapSize.Width() && aBitmapSize.Height())
                     {
                         // get logic half size
-                        basegfx::B2DVector aLogicHalfSize(rViewInformation.getInverseObjectToViewTransformation() *
+                        basegfx::B2DVector aLogicHalfSize(rParameters.getViewInformation().getInverseObjectToViewTransformation() *
                             basegfx::B2DVector(aBitmapSize.getWidth(), aBitmapSize.getHeight()));
 
                         // use half size for expand
diff --git a/drawinglayer/source/primitive2d/maskprimitive2d.cxx b/drawinglayer/source/primitive2d/maskprimitive2d.cxx
index 1e8af509c157..4c3a60338f92 100644
--- a/drawinglayer/source/primitive2d/maskprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/maskprimitive2d.cxx
@@ -46,7 +46,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange MaskPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+        basegfx::B2DRange MaskPrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             return getMask().getB2DRange();
         }
diff --git a/drawinglayer/source/primitive2d/mediaprimitive2d.cxx b/drawinglayer/source/primitive2d/mediaprimitive2d.cxx
index 5158c6822492..c754b11a8f3c 100644
--- a/drawinglayer/source/primitive2d/mediaprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/mediaprimitive2d.cxx
@@ -31,7 +31,7 @@
 
 namespace drawinglayer::primitive2d
 {
-        void MediaPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void MediaPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
             Primitive2DContainer xRetval;
             xRetval.resize(1);
@@ -55,7 +55,7 @@ namespace drawinglayer::primitive2d
 
             if(getDiscreteBorder())
             {
-                const basegfx::B2DVector aDiscreteInLogic(rViewInformation.getInverseObjectToViewTransformation() *
+                const basegfx::B2DVector aDiscreteInLogic(rParameters.getViewInformation().getInverseObjectToViewTransformation() *
                     basegfx::B2DVector(static_cast<double>(getDiscreteBorder()), static_cast<double>(getDiscreteBorder())));
                 const double fDiscreteSize(aDiscreteInLogic.getX() + aDiscreteInLogic.getY());
 
@@ -120,14 +120,14 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange MediaPrimitive2D::getB2DRange(const geometry::ViewInformation2D& rViewInformation) const
+        basegfx::B2DRange MediaPrimitive2D::getB2DRange(VisitingParameters const & rParameters) const
         {
             basegfx::B2DRange aRetval(0.0, 0.0, 1.0, 1.0);
             aRetval.transform(getTransform());
 
             if(getDiscreteBorder())
             {
-                const basegfx::B2DVector aDiscreteInLogic(rViewInformation.getInverseObjectToViewTransformation() *
+                const basegfx::B2DVector aDiscreteInLogic(rParameters.getViewInformation().getInverseObjectToViewTransformation() *
                     basegfx::B2DVector(static_cast<double>(getDiscreteBorder()), static_cast<double>(getDiscreteBorder())));
                 const double fDiscreteSize(aDiscreteInLogic.getX() + aDiscreteInLogic.getY());
 
diff --git a/drawinglayer/source/primitive2d/metafileprimitive2d.cxx b/drawinglayer/source/primitive2d/metafileprimitive2d.cxx
index 362ae446fd99..3fa9ac2e096a 100644
--- a/drawinglayer/source/primitive2d/metafileprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/metafileprimitive2d.cxx
@@ -30,11 +30,11 @@ using namespace com::sun::star;
 
 namespace drawinglayer::primitive2d
 {
-        void MetafilePrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void MetafilePrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
             // Interpret the Metafile and get the content. There should be only one target, as in the start condition,
             // but iterating will be the right thing to do when some push/pop is not closed
-            Primitive2DContainer xRetval(wmfemfhelper::interpretMetafile(getMetaFile(), rViewInformation));
+            Primitive2DContainer xRetval(wmfemfhelper::interpretMetafile(getMetaFile(), rParameters.getViewInformation()));
 
             if(!xRetval.empty())
             {
@@ -46,7 +46,7 @@ namespace drawinglayer::primitive2d
                 // defined target range (aMtfRange)
                 if (!aMtfRange.isEmpty())
                 {
-                    const basegfx::B2DRange aContentRange(xRetval.getB2DRange(rViewInformation));
+                    const basegfx::B2DRange aContentRange(xRetval.getB2DRange(rParameters));
 
                     // also test equal since isInside gives also true for equal
                     if (!aMtfRange.equal(aContentRange) && !aMtfRange.isInside(aContentRange))
@@ -107,7 +107,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange MetafilePrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+        basegfx::B2DRange MetafilePrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             // use own implementation to quickly answer the getB2DRange question. The
             // MetafilePrimitive2D assumes that all geometry is inside of the shape. If
diff --git a/drawinglayer/source/primitive2d/pagepreviewprimitive2d.cxx b/drawinglayer/source/primitive2d/pagepreviewprimitive2d.cxx
index b7c67bf8fd0c..d44e253d7546 100644
--- a/drawinglayer/source/primitive2d/pagepreviewprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/pagepreviewprimitive2d.cxx
@@ -31,7 +31,7 @@ using namespace com::sun::star;
 
 namespace drawinglayer::primitive2d
 {
-        void PagePreviewPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void PagePreviewPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
             Primitive2DContainer aContent(getPageContent());
 
@@ -50,7 +50,7 @@ namespace drawinglayer::primitive2d
 
             // check if content overlaps with target size and needs to be embedded with a
             // clipping primitive
-            const basegfx::B2DRange aRealContentRange(aContent.getB2DRange(rViewInformation));
+            const basegfx::B2DRange aRealContentRange(aContent.getB2DRange(rParameters));
             const basegfx::B2DRange aAllowedContentRange(0.0, 0.0, getContentWidth(), getContentHeight());
 
             if(!aAllowedContentRange.isInside(aRealContentRange))
@@ -131,7 +131,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange PagePreviewPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation`*/) const
+        basegfx::B2DRange PagePreviewPrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             // nothing is allowed to stick out of a PagePreviewPrimitive, thus we
             // can quickly deliver our range here
diff --git a/drawinglayer/source/primitive2d/patternfillprimitive2d.cxx b/drawinglayer/source/primitive2d/patternfillprimitive2d.cxx
index ec1f9621452a..91cfdaf1861d 100644
--- a/drawinglayer/source/primitive2d/patternfillprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/patternfillprimitive2d.cxx
@@ -93,7 +93,7 @@ namespace drawinglayer::primitive2d
             }
         }
 
-        Primitive2DContainer PatternFillPrimitive2D::createContent(const geometry::ViewInformation2D& rViewInformation) const
+        Primitive2DContainer PatternFillPrimitive2D::createContent(VisitingParameters const & rParameters) const
         {
             Primitive2DContainer aContent;
 
@@ -142,7 +142,7 @@ namespace drawinglayer::primitive2d
 
                 // check if content needs to be clipped
                 const basegfx::B2DRange aUnitRange(0.0, 0.0, 1.0, 1.0);
-                const basegfx::B2DRange aContentRange(getChildren().getB2DRange(rViewInformation));
+                const basegfx::B2DRange aContentRange(getChildren().getB2DRange(rParameters));
 
                 if(!aUnitRange.isInside(aContentRange))
                 {
@@ -158,7 +158,7 @@ namespace drawinglayer::primitive2d
             return aContent;
         }
 
-        void PatternFillPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const
+        void PatternFillPrimitive2D::create2DDecomposition(Primitive2DContainer& rContainer, VisitingParameters const & rParameters) const
         {
             Primitive2DContainer aRetval;
 
@@ -180,7 +180,7 @@ namespace drawinglayer::primitive2d
             aTiling.appendTransformations(aMatrices);
 
             // create content
-            const Primitive2DContainer aContent(createContent(rViewInformation));
+            const Primitive2DContainer aContent(createContent(rParameters));
 
             // resize result
             aRetval.resize(aMatrices.size());
@@ -244,12 +244,12 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange PatternFillPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /* rViewInformation */ ) const
+        basegfx::B2DRange PatternFillPrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             return getMask().getB2DRange();
         }
 
-        void PatternFillPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const
+        void PatternFillPrimitive2D::get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, VisitingParameters const & rParameters) const
         {
             // The existing buffered decomposition uses a buffer in the remembered
             // size or none if sizes are zero. Get new needed sizes which depend on
@@ -257,7 +257,7 @@ namespace drawinglayer::primitive2d
             bool bResetBuffering = false;
             sal_uInt32 nW(0);
             sal_uInt32 nH(0);
-            calculateNeededDiscreteBufferSize(nW, nH, rViewInformation);
+            calculateNeededDiscreteBufferSize(nW, nH, rParameters.getViewInformation());
             const bool bBufferingCurrentlyUsed(0 != mnDiscreteWidth && 0 != mnDiscreteHeight);
             const bool bBufferingNextUsed(0 != nW && 0 != nH);
 
@@ -305,7 +305,7 @@ namespace drawinglayer::primitive2d
             }
 
             // call parent
-            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rViewInformation);
+            BufferedDecompositionPrimitive2D::get2DDecomposition(rVisitor, rParameters);
         }
 
         sal_Int64 SAL_CALL PatternFillPrimitive2D::estimateUsage()
diff --git a/drawinglayer/source/primitive2d/pointarrayprimitive2d.cxx b/drawinglayer/source/primitive2d/pointarrayprimitive2d.cxx
index 7e527487eb85..0825ca46c00b 100644
--- a/drawinglayer/source/primitive2d/pointarrayprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/pointarrayprimitive2d.cxx
@@ -49,7 +49,7 @@ namespace drawinglayer::primitive2d
             return false;
         }
 
-        basegfx::B2DRange PointArrayPrimitive2D::getB2DRange(const geometry::ViewInformation2D& /*rViewInformation*/) const
+        basegfx::B2DRange PointArrayPrimitive2D::getB2DRange(VisitingParameters const & /*rParameters*/) const
         {
             if(maB2DRange.isEmpty())
             {

... etc. - the rest is truncated


More information about the Libreoffice-commits mailing list