diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2022-06-20 09:46:44 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2022-06-20 11:58:33 +0200 |
commit | 486810603fb3f84847bb549004ed0394a2e22d0b (patch) | |
tree | 9c2f16df46a239ab3d5ea99cb4a218ce457961be /svx/sdi | |
parent | fd916f4eed3f04f345159347a35a2af4d18dbb9a (diff) |
sd theme: consider accent1 color when inserting shape with solid fill
Once a theme is defined for the master page of the current slide,
PowerPoint inserts a shapes with their fill color & line color set based
on that theme (so this color is master-page-specific), while Impress
sets the fill & line color based on the default shape style.
The Impress behavior has the benefit of doing the usual style-based
formatting, but now a document-level style overwrites a
(master-)slide-specific theme, which is inconsistent.
Fix the problem by extending sd::FuConstruct::SetStyleSheet(): if we
construct a shape with fill, then not only apply the style sheet, but
also set the fill & line color based on the theme (if there is any).
Note that this works both in case the shape is instantly created on
click (LOK case) or when the user first draws a top-left -> bottom-right
point pair to define the position / size of the shape. At the same time
line colors don't support themes yet, so that color is just a plain value
for now.
Change-Id: Ic6ae8f91bd719bd80f2b56f12b001d29b0961e6e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136138
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'svx/sdi')
-rw-r--r-- | svx/sdi/svx.sdi | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/svx/sdi/svx.sdi b/svx/sdi/svx.sdi index 3c8a3642c04a..de7ef9914b4c 100644 --- a/svx/sdi/svx.sdi +++ b/svx/sdi/svx.sdi @@ -10512,7 +10512,7 @@ SfxVoidItem SbaBrwInsert SID_SBA_BRW_INSERT SfxStringItem BasicShapes SID_DRAWTBX_CS_BASIC -(SfxStringItem BasicShapes SID_DRAWTBX_CS_BASIC) +(SfxStringItem BasicShapes SID_DRAWTBX_CS_BASIC, SfxBoolItem CreateDirectly FN_PARAM_1) [ AutoUpdate = TRUE, FastCall = FALSE, |