summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2024-08-11 20:05:14 +0200
committerSzymon Kłos <szymon.klos@collabora.com>2024-09-04 14:34:07 +0200
commit30a5734a365a99470c485462b18ddb2cfb9f0471 (patch)
tree7ef6f8adfe239f52ccc724d138ce5ecd8bf70513 /svx
parent51d99782ddbddd5f5492c27a7150839a80b93dc2 (diff)
render master and slide content separately (drawinglayer render)
This renders master and the main slide as 2 separate layers, which is useful because in a huge slideshow we can reuse the master slide and only render the rest of the slide, which should be more compact in size as the master slide is the one that usually contains the (complex) background. Change-Id: I5e86d718b7ab3b03bd0b6146ce4df218a4dd72d4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171962 Reviewed-by: Szymon Kłos <szymon.klos@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/sdr/contact/viewobjectcontactofmasterpagedescriptor.cxx7
-rw-r--r--svx/source/svdraw/svdpntv.cxx1
2 files changed, 6 insertions, 2 deletions
diff --git a/svx/source/sdr/contact/viewobjectcontactofmasterpagedescriptor.cxx b/svx/source/sdr/contact/viewobjectcontactofmasterpagedescriptor.cxx
index baa039b1bb0f..2cd4b64c2fe8 100644
--- a/svx/source/sdr/contact/viewobjectcontactofmasterpagedescriptor.cxx
+++ b/svx/source/sdr/contact/viewobjectcontactofmasterpagedescriptor.cxx
@@ -23,6 +23,8 @@
#include <svx/sdr/contact/displayinfo.hxx>
#include <svx/sdr/contact/objectcontact.hxx>
#include <svx/svdpage.hxx>
+#include <svx/svdpagv.hxx>
+#include <svx/svdview.hxx>
#include <drawinglayer/primitive2d/maskprimitive2d.hxx>
#include <basegfx/polygon/b2dpolygontools.hxx>
#include <basegfx/polygon/b2dpolygon.hxx>
@@ -78,12 +80,13 @@ namespace sdr::contact
aPreprocessedLayers &= rDescriptor.GetVisibleLayers();
rDisplayInfo.SetProcessLayers(aPreprocessedLayers);
rDisplayInfo.SetSubContentActive(true);
-
+ const SdrPageView* pSdrPageView = GetObjectContact().TryToGetSdrPageView();
+ bool bHideBackground = pSdrPageView ? pSdrPageView->GetView().getHideBackground() : false;
// check layer visibility (traditionally was member of layer 1)
if(aPreprocessedLayers.IsSet(SdrLayerID(1)))
{
// hide PageBackground for special DrawModes; historical reasons
- if(!GetObjectContact().isDrawModeGray() && !GetObjectContact().isDrawModeHighContrast())
+ if (!bHideBackground && !GetObjectContact().isDrawModeGray() && !GetObjectContact().isDrawModeHighContrast())
{
// if visible, create the default background primitive sequence
static_cast< ViewContactOfMasterPageDescriptor& >(GetViewContact()).getViewIndependentPrimitive2DContainer(rVisitor);
diff --git a/svx/source/svdraw/svdpntv.cxx b/svx/source/svdraw/svdpntv.cxx
index 5fcea85745f5..1aa512072586 100644
--- a/svx/source/svdraw/svdpntv.cxx
+++ b/svx/source/svdraw/svdpntv.cxx
@@ -165,6 +165,7 @@ SdrPaintView::SdrPaintView(SdrModel& rSdrModel, OutputDevice* pOut)
, mbHideChart(false)
, mbHideDraw(false)
, mbHideFormControl(false)
+ , mbHideBackground(false)
, mbPaintTextEdit(true)
, maGridColor(COL_BLACK)
{