diff options
author | Armin Le Grand <alg@apache.org> | 2014-06-02 15:00:50 +0000 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-07-01 13:30:09 +0200 |
commit | 7d9bb549d498d6beed2c4050c402d09643febdfa (patch) | |
tree | 2caf67e36c9ccd058268b003cf2bc39b9b102b53 /sw/inc | |
parent | a5e137eb1d37361c60175e8fba780fc46b377a23 (diff) |
Related: #i124638# Second step of DrawingLayer FillAttributes...
for Writer objects, now added support for Paragraph and PageStyle (including
Header and Footer) for direct attributes and style attributes
(cherry picked from commit cc25c58f7052827bfebdc9fbeec668c8fa29ed1b)
Conflicts:
cui/source/factory/dlgfact.cxx
cui/source/factory/dlgfact.hxx
cui/source/inc/bbdlg.hxx
cui/source/inc/cuires.hrc
cui/source/tabpages/bbdlg.cxx
cui/source/tabpages/bbdlg.src
cui/source/tabpages/page.cxx
cui/source/tabpages/tparea.cxx
include/svx/pagectrl.hxx
include/svx/svxdlg.hxx
include/svx/svxids.hrc
include/xmloff/PageMasterStyleMap.hxx
include/xmloff/prstylei.hxx
include/xmloff/txtprmap.hxx
svx/Package_inc.mk
svx/inc/svx/hdft.hxx
svx/source/dialog/hdft.cxx
svx/source/dialog/pagectrl.cxx
svx/source/tbxctrls/tbxcolorupdate.cxx
svx/source/unodraw/unobrushitemhelper.cxx
sw/Library_sw.mk
sw/inc/fillattributes.hxx
sw/inc/format.hxx
sw/inc/frmatr.hxx
sw/inc/frmfmt.hxx
sw/inc/hintids.hxx
sw/inc/hints.hxx
sw/inc/ndtxt.hxx
sw/inc/node.hxx
sw/inc/swunohelper.hxx
sw/inc/unobrushitemhelper.hxx
sw/inc/unoprnms.hxx
sw/source/core/attr/format.cxx
sw/source/core/attr/hints.cxx
sw/source/core/doc/docdesc.cxx
sw/source/core/doc/docdraw.cxx
sw/source/core/doc/docfmt.cxx
sw/source/core/doc/docnew.cxx
sw/source/core/doc/docredln.cxx
sw/source/core/doc/poolfmt.cxx
sw/source/core/doc/visiturl.cxx
sw/source/core/docnode/node.cxx
sw/source/core/inc/frame.hxx
sw/source/core/inc/frmtool.hxx
sw/source/core/inc/rolbck.hxx
sw/source/core/layout/atrfrm.cxx
sw/source/core/layout/fillattributes.cxx
sw/source/core/layout/findfrm.cxx
sw/source/core/layout/paintfrm.cxx
sw/source/core/txtnode/ndtxt.cxx
sw/source/core/txtnode/thints.cxx
sw/source/core/txtnode/txtedt.cxx
sw/source/core/undo/rolbck.cxx
sw/source/core/unocore/swunohelper.cxx
sw/source/core/unocore/unoframe.cxx
sw/source/core/unocore/unomap.cxx
sw/source/core/unocore/unoparagraph.cxx
sw/source/core/unocore/unoprnms.cxx
sw/source/core/unocore/unostyle.cxx
sw/source/ui/chrdlg/paradlg.src
sw/source/ui/chrdlg/pardlg.cxx
sw/source/ui/fmtui/tmpdlg.cxx
sw/source/ui/fmtui/tmpdlg.src
sw/source/uibase/app/docst.cxx
sw/source/uibase/app/docstyle.cxx
sw/source/uibase/frmdlg/colex.cxx
sw/source/uibase/shells/basesh.cxx
sw/source/uibase/shells/textsh1.cxx
sw/source/uibase/uiview/viewstat.cxx
sw/source/uibase/utlui/uitool.cxx
xmloff/inc/PageMasterImportContext.hxx
xmloff/inc/xmloff/XMLShapeStyleContext.hxx
xmloff/source/draw/XMLShapeStyleContext.cxx
xmloff/source/draw/sdpropls.hxx
xmloff/source/style/PageMasterExportPropMapper.cxx
xmloff/source/style/PageMasterImportContext.cxx
xmloff/source/style/PageMasterPropHdlFactory.cxx
xmloff/source/style/PageMasterStyleMap.cxx
xmloff/source/style/prstylei.cxx
xmloff/source/text/txtexppr.cxx
xmloff/source/text/txtprhdl.cxx
xmloff/source/text/txtprmap.cxx
xmloff/source/text/txtstyli.cxx
Conflicts:
svx/source/dialog/hdft.cxx
sw/source/core/doc/visiturl.cxx
sw/source/core/txtnode/thints.cxx
sw/source/core/txtnode/txtatr2.cxx
sw/source/core/unocore/unostyle.cxx
Change-Id: I7e8779db6c0cbd1e242b63eab888f468f2de509a
Diffstat (limited to 'sw/inc')
-rw-r--r-- | sw/inc/cmdid.h | 20 | ||||
-rw-r--r-- | sw/inc/fillattributes.hxx | 70 | ||||
-rw-r--r-- | sw/inc/format.hxx | 25 | ||||
-rw-r--r-- | sw/inc/frmatr.hxx | 2 | ||||
-rw-r--r-- | sw/inc/frmfmt.hxx | 8 | ||||
-rw-r--r-- | sw/inc/hintids.hxx | 8 | ||||
-rw-r--r-- | sw/inc/hints.hxx | 26 | ||||
-rw-r--r-- | sw/inc/ndtxt.hxx | 6 | ||||
-rw-r--r-- | sw/inc/node.hxx | 9 | ||||
-rw-r--r-- | sw/inc/swatrset.hxx | 6 | ||||
-rw-r--r-- | sw/inc/swunohelper.hxx | 9 | ||||
-rw-r--r-- | sw/inc/unobrushitemhelper.hxx | 36 | ||||
-rw-r--r-- | sw/inc/unoframe.hxx | 5 | ||||
-rw-r--r-- | sw/inc/unoprnms.hxx | 54 | ||||
-rw-r--r-- | sw/inc/unostyle.hxx | 7 |
15 files changed, 130 insertions, 161 deletions
diff --git a/sw/inc/cmdid.h b/sw/inc/cmdid.h index 46c84b19ee50..fd119ce570ac 100644 --- a/sw/inc/cmdid.h +++ b/sw/inc/cmdid.h @@ -528,24 +528,6 @@ #define FN_UNO_FOOTER (FN_EXTRA2 + 38) #define FN_UNO_FOOTER_LEFT (FN_EXTRA2 + 39) #define FN_UNO_FOOTER_RIGHT (FN_EXTRA2 + 40) -#define FN_UNO_HEADER_BACKGROUND (FN_EXTRA2 + 41) -#define FN_UNO_HEADER_BOX (FN_EXTRA2 + 42) -#define FN_UNO_HEADER_LR_SPACE (FN_EXTRA2 + 43) -#define FN_UNO_HEADER_SHADOW (FN_EXTRA2 + 44) -#define FN_UNO_FOOTER_BACKGROUND (FN_EXTRA2 + 45) -#define FN_UNO_FOOTER_BOX (FN_EXTRA2 + 46) -#define FN_UNO_FOOTER_LR_SPACE (FN_EXTRA2 + 47) -#define FN_UNO_FOOTER_SHADOW (FN_EXTRA2 + 48) -#define FN_UNO_HEADER_BODY_DISTANCE (FN_EXTRA2 + 49) -#define FN_UNO_HEADER_IS_DYNAMIC_DISTANCE (FN_EXTRA2 + 50) -#define FN_UNO_FOOTER_BODY_DISTANCE (FN_EXTRA2 + 51) -#define FN_UNO_FOOTER_IS_DYNAMIC_DISTANCE (FN_EXTRA2 + 52) -#define FN_UNO_HEADER_SHARE_CONTENT (FN_EXTRA2 + 53) -#define FN_UNO_FOOTER_SHARE_CONTENT (FN_EXTRA2 + 54) -#define FN_UNO_HEADER_HEIGHT (FN_EXTRA2 + 55) -#define FN_UNO_FOOTER_HEIGHT (FN_EXTRA2 + 56) -#define FN_UNO_HEADER_ON (FN_EXTRA2 + 57) -#define FN_UNO_FOOTER_ON (FN_EXTRA2 + 58) #define FN_UNO_FOLLOW_STYLE (FN_EXTRA2 + 59) #define FN_API_CALL (FN_EXTRA2 + 60) @@ -584,8 +566,6 @@ #define FN_NEW_GLOSSARY (FN_EXTRA2 + 90) #define FN_SET_ACT_GLOSSARY (FN_EXTRA2 + 91) -#define FN_UNO_HEADER_EAT_SPACING (FN_EXTRA2 + 92) -#define FN_UNO_FOOTER_EAT_SPACING (FN_EXTRA2 + 93) #define FN_UNO_CHARFMT_SEQUENCE (FN_EXTRA2 + 94) #define FN_UNO_CLSID (FN_EXTRA2 + 95) #define FN_UNO_MODEL (FN_EXTRA2 + 96) diff --git a/sw/inc/fillattributes.hxx b/sw/inc/fillattributes.hxx deleted file mode 100644 index 05624c4a8de5..000000000000 --- a/sw/inc/fillattributes.hxx +++ /dev/null @@ -1,70 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * 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/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ - -#ifndef INCLUDED_SW_INC_FILLATTRIBUTES_HXX -#define INCLUDED_SW_INC_FILLATTRIBUTES_HXX - -#include <drawinglayer/attribute/fillgradientattribute.hxx> -#include <drawinglayer/attribute/sdrfillattribute.hxx> -#include <drawinglayer/primitive2d/baseprimitive2d.hxx> -#include <boost/shared_ptr.hpp> - -////////////////////////////////////////////////////////////////////////////// - -class Color; -class SfxItemSet; -class FillAttributes -{ -private: - basegfx::B2DRange maLastPaintRange; - basegfx::B2DRange maLastDefineRange; - boost::shared_ptr< drawinglayer::attribute::SdrFillAttribute > maFillAttribute; - boost::shared_ptr< drawinglayer::attribute::FillGradientAttribute > maFillGradientAttribute; - drawinglayer::primitive2d::Primitive2DSequence maPrimitives; - - void createPrimitive2DSequence( - const basegfx::B2DRange& rPaintRange, - const basegfx::B2DRange& rDefineRange); - -protected: -public: - FillAttributes(const Color& rColor); - FillAttributes(const SfxItemSet& rSet); - ~FillAttributes(); - - bool isUsed() const; - bool hasSdrFillAttribute() const { return maFillAttribute.get(); } - bool hasFillGradientAttribute() const { return maFillGradientAttribute.get(); } - bool isTransparent() const; - - const drawinglayer::attribute::SdrFillAttribute& getFillAttribute() const; - const drawinglayer::primitive2d::Primitive2DSequence& getPrimitive2DSequence( - const basegfx::B2DRange& rPaintRange, - const basegfx::B2DRange& rDefineRange) const; -}; - -////////////////////////////////////////////////////////////////////////////// - -typedef boost::shared_ptr< FillAttributes > FillAttributesPtr; - -////////////////////////////////////////////////////////////////////////////// - -#endif // INCLUDED_SW_INC_FILLATTRIBUTES_HXX - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/inc/format.hxx b/sw/inc/format.hxx index 325893105c0f..191a755dc740 100644 --- a/sw/inc/format.hxx +++ b/sw/inc/format.hxx @@ -25,8 +25,6 @@ #include <calbck.hxx> #include <hintids.hxx> #include <boost/shared_ptr.hpp> -//UUUU -#include <fillattributes.hxx> class IDocumentSettingAccess; class IDocumentDrawModelAccess; @@ -37,6 +35,11 @@ class IDocumentChartDataProviderAccess; class SwDoc; class SfxGrabBagItem; +namespace drawinglayer { namespace attribute { + class SdrAllFillAttributesHelper; + typedef boost::shared_ptr< SdrAllFillAttributesHelper > SdrAllFillAttributesHelperPtr; +}} + /// Base class for various Writer styles. class SW_DLLPUBLIC SwFmt : public SwModify { @@ -241,7 +244,7 @@ public: inline const SvxBoxItem &GetBox( bool = true ) const; inline const SvxFmtKeepItem &GetKeep( bool = true ) const; - //UUUU + //UUUU Get SvxBrushItem for Background fill (partially for backwards compatibility) const SvxBrushItem& GetBackground( bool = true ) const; inline const SvxShadowItem &GetShadow( bool = true ) const; @@ -327,28 +330,16 @@ public: */ virtual bool IsShadowTransparent() const; - //UUUU - virtual FillAttributesPtr getFillAttributes() const; + //UUUU Access to DrawingLayer FillAttributes in a preprocessed form for primitive usage + virtual drawinglayer::attribute::SdrAllFillAttributesHelperPtr getSdrAllFillAttributesHelper() const; }; -//UUUUinline const SfxPoolItem& SwFmt::GetFmtAttr( sal_uInt16 nWhich, -//UUUU bool bInParents ) const -//UUUU{ -//UUUU return aSet.Get( nWhich, bInParents ); -//UUUU} - inline void SwFmt::SetName( const sal_Char* pNewName, bool bBroadcast ) { SetName(OUString::createFromAscii(pNewName), bBroadcast); } -//UUUUinline SfxItemState SwFmt::GetItemState( sal_uInt16 nWhich, bool bSrchInParent, -//UUUU const SfxPoolItem **ppItem ) const -//UUUU{ -//UUUU return aSet.GetItemState( nWhich, bSrchInParent, ppItem ); -//UUUU} - #endif // INCLUDED_SW_INC_FORMAT_HXX /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/inc/frmatr.hxx b/sw/inc/frmatr.hxx index adde000b9c84..c3937dff459b 100644 --- a/sw/inc/frmatr.hxx +++ b/sw/inc/frmatr.hxx @@ -71,8 +71,6 @@ inline const SvxBoxItem &SwFmt::GetBox(bool bInP) const { return aSet.GetBox(bInP); } inline const SvxFmtKeepItem &SwFmt::GetKeep(bool bInP) const { return aSet.GetKeep(bInP); } -//UUUUinline const SvxBrushItem &SwFmt::GetBackground(sal_Bool bInP) const -//UUUU { return aSet.GetBackground(bInP); } inline const SvxShadowItem &SwFmt::GetShadow(bool bInP) const { return aSet.GetShadow(bInP); } inline const SvxFmtBreakItem &SwFmt::GetBreak(bool bInP) const diff --git a/sw/inc/frmfmt.hxx b/sw/inc/frmfmt.hxx index 1b063ff4a077..ebf23173387e 100644 --- a/sw/inc/frmfmt.hxx +++ b/sw/inc/frmfmt.hxx @@ -43,8 +43,8 @@ class SW_DLLPUBLIC SwFrmFmt: public SwFmt ::com::sun::star::uno::WeakReference< ::com::sun::star::uno::XInterface> m_wXObject; - //UUUU - FillAttributesPtr maFillAttributes; + //UUUU DrawingLayer FillAttributes in a preprocessed form for primitive usage + drawinglayer::attribute::SdrAllFillAttributesHelperPtr maFillAttributes; protected: SwFrmFmt( @@ -134,8 +134,8 @@ public: DECL_FIXEDMEMPOOL_NEWDEL_DLL(SwFrmFmt) void RegisterToFormat( SwFmt& rFmt ); - //UUUU - virtual FillAttributesPtr getFillAttributes() const SAL_OVERRIDE; + //UUUU Access to DrawingLayer FillAttributes in a preprocessed form for primitive usage + virtual drawinglayer::attribute::SdrAllFillAttributesHelperPtr getSdrAllFillAttributesHelper() const SAL_OVERRIDE; }; // The FlyFrame-Format diff --git a/sw/inc/hintids.hxx b/sw/inc/hintids.hxx index 4a0840d52e0b..4e481936bfc6 100644 --- a/sw/inc/hintids.hxx +++ b/sw/inc/hintids.hxx @@ -21,6 +21,7 @@ #include <tools/solar.h> #include <sal/types.h> +#include <svx/xdef.hxx> #include "swdllapi.h" // For SwTxtHints without end index the following char is added: @@ -398,11 +399,16 @@ inline bool isPARATR(const sal_uInt16 nWhich) } inline bool isPARATR_LIST(const sal_uInt16 nWhich) { - return (RES_PARATR_LIST_BEGIN <= nWhich) && (RES_PARATR_LIST_END > nWhich); } + return (RES_PARATR_LIST_BEGIN <= nWhich) && (RES_PARATR_LIST_END > nWhich); +} inline bool isFRMATR(const sal_uInt16 nWhich) { return (RES_FRMATR_BEGIN <= nWhich) && (RES_FRMATR_END > nWhich); } +inline bool isDrawingLayerAttribute(const sal_uInt16 nWhich) //UUUU +{ + return (XATTR_FILL_FIRST <= nWhich) && (XATTR_FILL_LAST >= nWhich); +} inline bool isGRFATR(const sal_uInt16 nWhich) { return (RES_GRFATR_BEGIN <= nWhich) && (RES_GRFATR_END > nWhich); diff --git a/sw/inc/hints.hxx b/sw/inc/hints.hxx index be1f1ac2fad7..a971b15f2928 100644 --- a/sw/inc/hints.hxx +++ b/sw/inc/hints.hxx @@ -93,15 +93,37 @@ public: SwDelTxt( sal_Int32 nS, sal_Int32 nL ); }; -class SwUpdateAttr: public SwMsgPoolItem +class SwUpdateAttr : public SwMsgPoolItem { -public: +private: sal_Int32 nStart; sal_Int32 nEnd; sal_uInt16 nWhichAttr; std::vector<sal_uInt16> aWhichFmtAttr; // attributes changed inside RES_TXTATR_AUTOFMT + +public: SwUpdateAttr( sal_Int32 nS, sal_Int32 nE, sal_uInt16 nW ); SwUpdateAttr( sal_Int32 nS, sal_Int32 nE, sal_uInt16 nW, std::vector<sal_uInt16> aW ); + + sal_Int32 getStart() const + { + return nStart; + } + + sal_Int32 getEnd() const + { + return nEnd; + } + + sal_uInt16 getWhichAttr() const + { + return nWhichAttr; + } + + const std::vector<sal_uInt16>& getFmtAttr() const + { + return aWhichFmtAttr; + } }; /** SwRefMarkFldUpdate is sent when the referencemarks should be updated. diff --git a/sw/inc/ndtxt.hxx b/sw/inc/ndtxt.hxx index 46ef40180a5f..113ff62c021d 100644 --- a/sw/inc/ndtxt.hxx +++ b/sw/inc/ndtxt.hxx @@ -115,6 +115,9 @@ class SW_DLLPUBLIC SwTxtNode: public SwCntntNode, public ::sfx2::Metadatable ::com::sun::star::uno::WeakReference< ::com::sun::star::text::XTextContent> m_wXParagraph; + //UUUU DrawingLayer FillAttributes in a preprocessed form for primitive usage + drawinglayer::attribute::SdrAllFillAttributesHelperPtr maFillAttributes; + SAL_DLLPRIVATE SwTxtNode( const SwNodeIndex &rWhere, SwTxtFmtColl *pTxtColl, const SfxItemSet* pAutoAttr = 0 ); @@ -797,6 +800,9 @@ public: bool CompareParRsid( const SwTxtNode &rTxtNode ) const; DECL_FIXEDMEMPOOL_NEWDEL(SwTxtNode) + + //UUUU Access to DrawingLayer FillAttributes in a preprocessed form for primitive usage + virtual drawinglayer::attribute::SdrAllFillAttributesHelperPtr getSdrAllFillAttributesHelper() const; }; inline SwpHints & SwTxtNode::GetSwpHints() diff --git a/sw/inc/node.hxx b/sw/inc/node.hxx index be64d454d690..4de9d182c952 100644 --- a/sw/inc/node.hxx +++ b/sw/inc/node.hxx @@ -75,6 +75,12 @@ class IDocumentListItems; class SwOLENodes; class Point; +//UUUU +namespace drawinglayer { namespace attribute { + class SdrAllFillAttributesHelper; + typedef boost::shared_ptr< SdrAllFillAttributesHelper > SdrAllFillAttributesHelperPtr; +}} + /// Base class of the Writer document model elements. class SW_DLLPUBLIC SwNode : private BigPtrEntry @@ -479,6 +485,9 @@ public: static SwOLENodes* CreateOLENodesArray( const SwFmtColl& rColl, bool bOnlyWithInvalidSize ); + //UUUU Access to DrawingLayer FillAttributes in a preprocessed form for primitive usage + virtual drawinglayer::attribute::SdrAllFillAttributesHelperPtr getSdrAllFillAttributesHelper() const; + private: /// Private constructor because copying is never allowed!! SwCntntNode( const SwCntntNode & rNode ); diff --git a/sw/inc/swatrset.hxx b/sw/inc/swatrset.hxx index fbd6c6d2e23b..b60bc45c02cc 100644 --- a/sw/inc/swatrset.hxx +++ b/sw/inc/swatrset.hxx @@ -138,8 +138,10 @@ class SwTblBoxValue; class SwAttrPool : public SfxItemPool { private: - ///UUUU helpers to add/rmove DrawingLayer ItemPool, used in constructor - /// and destructor; still isolated to evtl. allow other use later + //UUUU helpers to add/rmove DrawingLayer ItemPool, used in constructor + // and destructor; still isolated to evtl. allow other use later, but + // used bz default now to have it instantly as needed for DrawingLayer + // FillStyle support void createAndAddSecondaryPools(); void removeAndDeleteSecondaryPools(); diff --git a/sw/inc/swunohelper.hxx b/sw/inc/swunohelper.hxx index 7856360130b8..6ebc335b2ae4 100644 --- a/sw/inc/swunohelper.hxx +++ b/sw/inc/swunohelper.hxx @@ -35,6 +35,9 @@ namespace rtl {class OUString;} class DateTime; +//UUUU +class SfxItemSet; + namespace SWUnoHelper { // calls over the compherl the getEnumAsInt32 function and handle the @@ -70,6 +73,12 @@ SW_DLLPUBLIC bool UCB_IsFile( const OUString& rURL ); // is the URL a existing directory? bool UCB_IsDirectory( const OUString& rURL ); + +///UUUU helper to check if fill style is set to color or bitmap +/// and thus formally used SvxBrushItem parts need to be mapped +/// for backwards compatibility +bool needToMapFillItemsToSvxBrushItemTypes(const SfxItemSet& rSet); + } #endif diff --git a/sw/inc/unobrushitemhelper.hxx b/sw/inc/unobrushitemhelper.hxx deleted file mode 100644 index fd141e51d248..000000000000 --- a/sw/inc/unobrushitemhelper.hxx +++ /dev/null @@ -1,36 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * 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/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ - -#ifndef INCLUDED_SW_INC_UNOBRUSHITEMHELPER_HXX -#define INCLUDED_SW_INC_UNOBRUSHITEMHELPER_HXX - -#include <swdllapi.h> -#include <editeng/brushitem.hxx> - -namespace sw { - -//UUUU helper function definintions for UNO API fallbacks to replace SvxBrushItem -void setSvxBrushItemAsFillAttributesToTargetSet(const SvxBrushItem& rBrush, SfxItemSet& rToSet); -SW_DLLPUBLIC SvxBrushItem getSvxBrushItemFromSourceSet(const SfxItemSet& rSourceSet, bool bSearchInParents = true); - -} // namespace sw - -#endif // INCLUDED_SW_INC_UNOBRUSHITEMHELPER_HXX - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/inc/unoframe.hxx b/sw/inc/unoframe.hxx index 0d9c761a8ce7..afd243736a44 100644 --- a/sw/inc/unoframe.hxx +++ b/sw/inc/unoframe.hxx @@ -72,11 +72,6 @@ private: SwPaM* m_pCopySource; - ///UUUU helper to check if fill style is set to color or bitmap - /// and thus formally used SvxBrushItem parts need to be mapped - /// for backwards compatibility - bool needToMapFillItemsToSvxBrushItemTypes() const; - protected: com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > mxStyleData; com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > mxStyleFamily; diff --git a/sw/inc/unoprnms.hxx b/sw/inc/unoprnms.hxx index 9f0267e872e2..197430400f7d 100644 --- a/sw/inc/unoprnms.hxx +++ b/sw/inc/unoprnms.hxx @@ -663,6 +663,60 @@ #define UNO_NAME_SW_FILLTRANSPARENCEGRADIENTNAME UNO_NAME_FILLTRANSPARENCEGRADIENTNAME #define UNO_NAME_SW_FILLCOLOR_2 UNO_NAME_FILLCOLOR_2 +#define UNO_NAME_HEADER_FILLBMP_LOGICAL_SIZE "Header" UNO_NAME_FILLBMP_LOGICAL_SIZE +#define UNO_NAME_HEADER_FILLBMP_OFFSET_X "Header" UNO_NAME_FILLBMP_OFFSET_X +#define UNO_NAME_HEADER_FILLBMP_OFFSET_Y "Header" UNO_NAME_FILLBMP_OFFSET_Y +#define UNO_NAME_HEADER_FILLBMP_POSITION_OFFSET_X "Header" UNO_NAME_FILLBMP_POSITION_OFFSET_X +#define UNO_NAME_HEADER_FILLBMP_POSITION_OFFSET_Y "Header" UNO_NAME_FILLBMP_POSITION_OFFSET_Y +#define UNO_NAME_HEADER_FILLBMP_RECTANGLE_POINT "Header" UNO_NAME_FILLBMP_RECTANGLE_POINT +#define UNO_NAME_HEADER_FILLBMP_SIZE_X "Header" UNO_NAME_FILLBMP_SIZE_X +#define UNO_NAME_HEADER_FILLBMP_SIZE_Y "Header" UNO_NAME_FILLBMP_SIZE_Y +#define UNO_NAME_HEADER_FILLBMP_STRETCH "Header" UNO_NAME_FILLBMP_STRETCH +#define UNO_NAME_HEADER_FILLBMP_TILE "Header" UNO_NAME_FILLBMP_TILE +#define UNO_NAME_HEADER_FILLBMP_MODE "Header" UNO_NAME_FILLBMP_MODE +#define UNO_NAME_HEADER_FILLCOLOR "Header" UNO_NAME_FILLCOLOR +#define UNO_NAME_HEADER_FILLBACKGROUND "Header" UNO_NAME_FILLBACKGROUND +#define UNO_NAME_HEADER_FILLBITMAP "Header" UNO_NAME_FILLBITMAP +#define UNO_NAME_HEADER_FILLBITMAPNAME "Header" UNO_NAME_FILLBITMAPNAME +#define UNO_NAME_HEADER_FILLBITMAPURL "Header" UNO_NAME_FILLBITMAPURL +#define UNO_NAME_HEADER_FILLGRADIENTSTEPCOUNT "Header" UNO_NAME_FILLGRADIENTSTEPCOUNT +#define UNO_NAME_HEADER_FILLGRADIENT "Header" UNO_NAME_FILLGRADIENT +#define UNO_NAME_HEADER_FILLGRADIENTNAME "Header" UNO_NAME_FILLGRADIENTNAME +#define UNO_NAME_HEADER_FILLHATCH "Header" UNO_NAME_FILLHATCH +#define UNO_NAME_HEADER_FILLHATCHNAME "Header" UNO_NAME_FILLHATCHNAME +#define UNO_NAME_HEADER_FILLSTYLE "Header" UNO_NAME_FILLSTYLE +#define UNO_NAME_HEADER_FILL_TRANSPARENCE "Header" UNO_NAME_FILL_TRANSPARENCE +#define UNO_NAME_HEADER_FILLTRANSPARENCEGRADIENT "Header" UNO_NAME_FILLTRANSPARENCEGRADIENT +#define UNO_NAME_HEADER_FILLTRANSPARENCEGRADIENTNAME "Header" UNO_NAME_FILLTRANSPARENCEGRADIENTNAME +#define UNO_NAME_HEADER_FILLCOLOR_2 "Header" UNO_NAME_FILLCOLOR_2 + +#define UNO_NAME_FOOTER_FILLBMP_LOGICAL_SIZE "Footer" UNO_NAME_FILLBMP_LOGICAL_SIZE +#define UNO_NAME_FOOTER_FILLBMP_OFFSET_X "Footer" UNO_NAME_FILLBMP_OFFSET_X +#define UNO_NAME_FOOTER_FILLBMP_OFFSET_Y "Footer" UNO_NAME_FILLBMP_OFFSET_Y +#define UNO_NAME_FOOTER_FILLBMP_POSITION_OFFSET_X "Footer" UNO_NAME_FILLBMP_POSITION_OFFSET_X +#define UNO_NAME_FOOTER_FILLBMP_POSITION_OFFSET_Y "Footer" UNO_NAME_FILLBMP_POSITION_OFFSET_Y +#define UNO_NAME_FOOTER_FILLBMP_RECTANGLE_POINT "Footer" UNO_NAME_FILLBMP_RECTANGLE_POINT +#define UNO_NAME_FOOTER_FILLBMP_SIZE_X "Footer" UNO_NAME_FILLBMP_SIZE_X +#define UNO_NAME_FOOTER_FILLBMP_SIZE_Y "Footer" UNO_NAME_FILLBMP_SIZE_Y +#define UNO_NAME_FOOTER_FILLBMP_STRETCH "Footer" UNO_NAME_FILLBMP_STRETCH +#define UNO_NAME_FOOTER_FILLBMP_TILE "Footer" UNO_NAME_FILLBMP_TILE +#define UNO_NAME_FOOTER_FILLBMP_MODE "Footer" UNO_NAME_FILLBMP_MODE +#define UNO_NAME_FOOTER_FILLCOLOR "Footer" UNO_NAME_FILLCOLOR +#define UNO_NAME_FOOTER_FILLBACKGROUND "Footer" UNO_NAME_FILLBACKGROUND +#define UNO_NAME_FOOTER_FILLBITMAP "Footer" UNO_NAME_FILLBITMAP +#define UNO_NAME_FOOTER_FILLBITMAPNAME "Footer" UNO_NAME_FILLBITMAPNAME +#define UNO_NAME_FOOTER_FILLBITMAPURL "Footer" UNO_NAME_FILLBITMAPURL +#define UNO_NAME_FOOTER_FILLGRADIENTSTEPCOUNT "Footer" UNO_NAME_FILLGRADIENTSTEPCOUNT +#define UNO_NAME_FOOTER_FILLGRADIENT "Footer" UNO_NAME_FILLGRADIENT +#define UNO_NAME_FOOTER_FILLGRADIENTNAME "Footer" UNO_NAME_FILLGRADIENTNAME +#define UNO_NAME_FOOTER_FILLHATCH "Footer" UNO_NAME_FILLHATCH +#define UNO_NAME_FOOTER_FILLHATCHNAME "Footer" UNO_NAME_FILLHATCHNAME +#define UNO_NAME_FOOTER_FILLSTYLE "Footer" UNO_NAME_FILLSTYLE +#define UNO_NAME_FOOTER_FILL_TRANSPARENCE "Footer" UNO_NAME_FILL_TRANSPARENCE +#define UNO_NAME_FOOTER_FILLTRANSPARENCEGRADIENT "Footer" UNO_NAME_FILLTRANSPARENCEGRADIENT +#define UNO_NAME_FOOTER_FILLTRANSPARENCEGRADIENTNAME "Footer" UNO_NAME_FILLTRANSPARENCEGRADIENTNAME +#define UNO_NAME_FOOTER_FILLCOLOR_2 "Footer" UNO_NAME_FILLCOLOR_2 + #define UNO_NAME_PARA_STYLEHEADING "ParaStyleHeading" #define UNO_NAME_PARA_STYLELEVEL1 "ParaStyleLevel1" #define UNO_NAME_PARA_STYLELEVEL10 "ParaStyleLevel10" diff --git a/sw/inc/unostyle.hxx b/sw/inc/unostyle.hxx index 0a661b4e75fd..7d210402e5d9 100644 --- a/sw/inc/unostyle.hxx +++ b/sw/inc/unostyle.hxx @@ -376,6 +376,7 @@ public: virtual sal_Bool SAL_CALL SAL_CALL hasElements( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; }; + class SwXAutoStylesEnumerator : public cppu::WeakImplHelper1< ::com::sun::star::container::XEnumeration >, public SwClient { @@ -400,8 +401,10 @@ class SwXAutoStyle : public cppu::WeakImplHelper3 >, public SwClient { - SfxItemSet_Pointer_t pSet; - IStyleAccess::SwAutoStyleFamily eFamily; +private: + SfxItemSet_Pointer_t mpSet; + IStyleAccess::SwAutoStyleFamily meFamily; + SwDoc& mrDoc; ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any > SAL_CALL GetPropertyValues_Impl( const ::com::sun::star::uno::Sequence< OUString >& aPropertyNames ) throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); |