diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2019-02-05 09:32:35 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2019-02-05 10:43:30 +0100 |
commit | cfc1f4ea4889f768d689a0df71519e9bcb707bc0 (patch) | |
tree | 07055482cc4e9ea589bec6e2f7570c88f9e80ce8 /oox/source/export | |
parent | 11a2809e369b2a6fcbb2d7f0db131a945557c6e2 (diff) |
oox: disable gradient fill grab-bag for PPTX
This was added in commit 2fcf3a871c94feeca11619ef5c8c0466ce61eb74
(ooxml: preserve gradient shape fill, 2014-01-31), and assumes that the
theme colors can be preserved, as the theme definition is grab-bagged as
well.
But the theme is grab-bagged only for DOCX, not for PPTX, so skip
gradient grab-bag for PPTX, otherwise the gradient would refer to
incorrect colors in the theme.
Change-Id: I98e1c67d4b10e68916f81dd7fc508eb4146d506b
Reviewed-on: https://gerrit.libreoffice.org/67386
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'oox/source/export')
-rw-r--r-- | oox/source/export/drawingml.cxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/oox/source/export/drawingml.cxx b/oox/source/export/drawingml.cxx index d1f6e16c7e33..361a17cd7ea4 100644 --- a/oox/source/export/drawingml.cxx +++ b/oox/source/export/drawingml.cxx @@ -417,7 +417,9 @@ void DrawingML::WriteGradientFill( const Reference< XPropertySet >& rXPropSet ) } // check if an ooxml gradient had been imported and if the user has modified it - if( EqualGradients( aOriginalGradient, aGradient ) ) + // Gradient grab-bag depends on theme grab-bag, which is implemented + // only for DOCX. + if( EqualGradients( aOriginalGradient, aGradient ) && GetDocumentType() == DOCUMENT_DOCX) { // If we have no gradient stops that means original gradient were defined by a theme. if( aGradientStops.hasElements() ) |