diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2020-12-02 14:09:31 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2020-12-11 17:33:54 +0100 |
commit | 3d851b56d288f8e9fd547848ec93dc450937edcf (patch) | |
tree | 7b24552fec145bff64043c159ebc242a52dd6cf0 /svx/source/sdr/primitive2d/sdrdecompositiontools.cxx | |
parent | cc53e7c2ee3d1fa2fb55c02e6f37ece316c7a6cd (diff) |
tdf#129961 svx: add rendering for table shadow as direct format
There was already shadow support in
ViewContactOfTableObj::createViewIndependentPrimitive2DSequence(), but
the UNO API and UI could only set the shadow properties on a shape
style, so shadow-as-direct-format is new.
One difference between the PowerPoint shadow and our shadow is that we
draw shadow for table text as well, while PowerPoint only does it for
the borders / cell fill style.
This means we're either backwards-compatible or compatible with
PowerPoint. Solve this problem by leaving the style case unchanged, but
render direct formatting like PowerPoint.
(cherry picked from commit a75bf43a8d6c5dec6dcc86908c142ceec541aa8c)
Conflicts:
svx/inc/sdr/primitive2d/sdrdecompositiontools.hxx
svx/source/sdr/primitive2d/sdrdecompositiontools.cxx
Change-Id: I2bc64fea8062f9d8162b95d1eaccb49c3466b5c5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107594
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'svx/source/sdr/primitive2d/sdrdecompositiontools.cxx')
-rw-r--r-- | svx/source/sdr/primitive2d/sdrdecompositiontools.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/svx/source/sdr/primitive2d/sdrdecompositiontools.cxx b/svx/source/sdr/primitive2d/sdrdecompositiontools.cxx index 48575d3b4917..1112230b78ba 100644 --- a/svx/source/sdr/primitive2d/sdrdecompositiontools.cxx +++ b/svx/source/sdr/primitive2d/sdrdecompositiontools.cxx @@ -483,7 +483,8 @@ namespace drawinglayer Primitive2DContainer createEmbeddedShadowPrimitive( const Primitive2DContainer& rContent, const attribute::SdrShadowAttribute& rShadow, - const basegfx::B2DHomMatrix& rObjectMatrix) + const basegfx::B2DHomMatrix& rObjectMatrix, + const Primitive2DContainer* pContentForShadow) { if(!rContent.empty()) { @@ -522,7 +523,7 @@ namespace drawinglayer new ShadowPrimitive2D( aShadowOffset, rShadow.getColor(), - rContent)); + (pContentForShadow ? *pContentForShadow : rContent))); if(0.0 != rShadow.getTransparence()) { |