diff options
author | Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de> | 2022-06-13 08:53:22 +0200 |
---|---|---|
committer | Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de> | 2022-06-16 15:44:53 +0200 |
commit | c4cf2e82e8d0aaef9b1daedc033d6edf647e5284 (patch) | |
tree | 86baca7fce89d0527d8177a7c4bb9a0e804cfc64 /include/svx | |
parent | 3d2e26d8b7a99d0a622741ef4327e8cbc93bbe02 (diff) |
tdf#128150 Add OOXML import/export for "use background fill"
and allow editing this fill property in area dlg
Change-Id: Ic63ba11e9d499d4a0fb22f6739587e3e25140b8f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134406
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
Diffstat (limited to 'include/svx')
-rw-r--r-- | include/svx/strings.hrc | 1 | ||||
-rw-r--r-- | include/svx/unoshprp.hxx | 4 | ||||
-rw-r--r-- | include/svx/xdef.hxx | 4 | ||||
-rw-r--r-- | include/svx/xfilluseslidebackgrounditem.hxx | 32 |
4 files changed, 39 insertions, 2 deletions
diff --git a/include/svx/strings.hrc b/include/svx/strings.hrc index 17f2b17d6081..6df58387733f 100644 --- a/include/svx/strings.hrc +++ b/include/svx/strings.hrc @@ -347,6 +347,7 @@ #define SIP_XA_FILLBMP_POSOFFSETX NC_("SIP_XA_FILLBMP_POSOFFSETX", "Tile position X in %") #define SIP_XA_FILLBMP_POSOFFSETY NC_("SIP_XA_FILLBMP_POSOFFSETY", "Tile position Y in %") #define SIP_XA_FILLBACKGROUND NC_("SIP_XA_FILLBACKGROUND", "Background fill") +#define SIP_XA_FILLUSESLIDEBACKGROUND NC_("SIP_XA_FILLUSESLIDEBACKGROUND", "Use slide background fill") #define SIP_XATTRSET_FILL NC_("SIP_XATTRSET_FILL", "Area attributes") #define SIP_XA_FORMTXTSTYLE NC_("SIP_XA_FORMTXTSTYLE", "Fontwork style") #define SIP_XA_FORMTXTADJUST NC_("SIP_XA_FORMTXTADJUST", "Fontwork alignment") diff --git a/include/svx/unoshprp.hxx b/include/svx/unoshprp.hxx index bd08927d5039..b32b8672c77c 100644 --- a/include/svx/unoshprp.hxx +++ b/include/svx/unoshprp.hxx @@ -292,7 +292,9 @@ { UNO_NAME_FILLCOLOR_THEME, XATTR_FILLCOLOR, ::cppu::UnoType<sal_Int16>::get(), 0, MID_COLOR_THEME_INDEX}, \ { UNO_NAME_FILLCOLOR_LUM_MOD, XATTR_FILLCOLOR, ::cppu::UnoType<sal_Int16>::get(), 0, MID_COLOR_LUM_MOD}, \ { UNO_NAME_FILLCOLOR_LUM_OFF, XATTR_FILLCOLOR, ::cppu::UnoType<sal_Int16>::get(), 0, MID_COLOR_LUM_OFF}, \ - { UNO_NAME_GRAPHIC_GRAPHICCROP, SDRATTR_GRAFCROP , ::cppu::UnoType<css::text::GraphicCrop>::get(), 0, 0 }, + { UNO_NAME_GRAPHIC_GRAPHICCROP, SDRATTR_GRAFCROP , ::cppu::UnoType<css::text::GraphicCrop>::get(), 0, 0 }, \ + { UNO_NAME_FILLUSESLIDEBACKGROUND, XATTR_FILLUSESLIDEBACKGROUND, cppu::UnoType<bool>::get(), 0, 0}, + #define EDGERADIUS_PROPERTIES \ { UNO_NAME_EDGERADIUS, SDRATTR_CORNER_RADIUS , ::cppu::UnoType<sal_Int32>::get() , 0, 0, PropertyMoreFlags::METRIC_ITEM}, diff --git a/include/svx/xdef.hxx b/include/svx/xdef.hxx index e7740ee15ddc..906b566caa78 100644 --- a/include/svx/xdef.hxx +++ b/include/svx/xdef.hxx @@ -49,6 +49,7 @@ class XFillGradientItem; class XFillHatchItem; class XFillStyleItem; class XFillTransparenceItem; +class XFillUseSlideBackgroundItem; class XFormTextAdjustItem; class XFormTextDistanceItem; class XFormTextHideFormItem; @@ -124,7 +125,8 @@ constexpr TypedWhichId<XFillBmpStretchItem> XATTR_FILLBMP_STRETCH ( constexpr TypedWhichId<XFillBmpPosOffsetXItem> XATTR_FILLBMP_POSOFFSETX (XATTR_FILL_FIRST + 17); /* V3: 1041 */ constexpr TypedWhichId<XFillBmpPosOffsetYItem> XATTR_FILLBMP_POSOFFSETY (XATTR_FILL_FIRST + 18); /* V3: 1042 */ constexpr TypedWhichId<XFillBackgroundItem> XATTR_FILLBACKGROUND (XATTR_FILL_FIRST + 19); /* V3: 1043 */ -constexpr sal_uInt16 XATTR_FILL_LAST (XATTR_FILLBACKGROUND); +constexpr TypedWhichId<XFillUseSlideBackgroundItem> XATTR_FILLUSESLIDEBACKGROUND (XATTR_FILL_FIRST + 20); +constexpr sal_uInt16 XATTR_FILL_LAST (XATTR_FILLUSESLIDEBACKGROUND); constexpr TypedWhichId<XFillAttrSetItem> XATTRSET_FILL (XATTR_FILL_LAST + 1); /* V3: 1047 V2: 1030 */ constexpr sal_uInt16 XATTR_TEXT_FIRST (XATTRSET_FILL + 1); diff --git a/include/svx/xfilluseslidebackgrounditem.hxx b/include/svx/xfilluseslidebackgrounditem.hxx new file mode 100644 index 000000000000..5a5cba891554 --- /dev/null +++ b/include/svx/xfilluseslidebackgrounditem.hxx @@ -0,0 +1,32 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ + +#pragma once + +#include <svl/eitem.hxx> +#include <svx/svxdllapi.h> + +/** Item to enable slide background for filled objects */ + +class SVXCORE_DLLPUBLIC XFillUseSlideBackgroundItem final : public SfxBoolItem +{ +public: + XFillUseSlideBackgroundItem(bool bFill = false); + + SVX_DLLPRIVATE virtual XFillUseSlideBackgroundItem* Clone(SfxItemPool* pPool + = nullptr) const override; + + SVX_DLLPRIVATE virtual bool GetPresentation(SfxItemPresentation ePres, MapUnit eCoreMetric, + MapUnit ePresMetric, OUString& rText, + const IntlWrapper&) const override; + + void dumpAsXml(xmlTextWriterPtr pWriter) const override; +}; + +/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */ |