summaryrefslogtreecommitdiffstats
path: root/sw
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@suse.cz>2013-01-27 20:52:55 +0100
committerMiklos Vajna <vmiklos@suse.cz>2013-01-28 13:49:40 +0100
commit06de72bea24a83e4a4efbc235853a40781bce168 (patch)
tree3351637a0b50509ebfabd65120cccfc3500b3375 /sw
parentrestore javafilters' registration under Windows (diff)
downloadcore-06de72bea24a83e4a4efbc235853a40781bce168.tar.gz
core-06de72bea24a83e4a4efbc235853a40781bce168.zip
SwXTextFrame: use XFillStyleItem instead of extending SvxBrushItem
Change-Id: I03b841ed703503425c9f1a2045d6399c8899815f
Diffstat (limited to 'sw')
-rw-r--r--sw/inc/frmatr.hxx2
-rw-r--r--sw/inc/hintids.hxx1
-rw-r--r--sw/inc/swatrset.hxx2
-rw-r--r--sw/source/core/access/accpara.cxx3
-rw-r--r--sw/source/core/bastyp/init.cxx3
-rw-r--r--sw/source/core/doc/notxtfrm.cxx6
-rw-r--r--sw/source/core/inc/frame.hxx2
-rw-r--r--sw/source/core/inc/frmtool.hxx3
-rw-r--r--sw/source/core/layout/paintfrm.cxx25
-rw-r--r--sw/source/core/text/inftxt.cxx5
-rw-r--r--sw/source/core/text/porfld.cxx2
-rw-r--r--sw/source/core/text/txtfly.cxx2
-rw-r--r--sw/source/core/txtnode/fntcache.cxx3
-rw-r--r--sw/source/core/unocore/unoframe.cxx18
-rw-r--r--sw/source/core/unocore/unomap.cxx4
15 files changed, 57 insertions, 24 deletions
diff --git a/sw/inc/frmatr.hxx b/sw/inc/frmatr.hxx
index f456e6f3492d..2266c14932a5 100644
--- a/sw/inc/frmatr.hxx
+++ b/sw/inc/frmatr.hxx
@@ -44,6 +44,8 @@ inline const SvxFmtKeepItem &SwAttrSet::GetKeep(sal_Bool bInP) const
{ return (const SvxFmtKeepItem&)Get( RES_KEEP,bInP); }
inline const SvxBrushItem &SwAttrSet::GetBackground(sal_Bool bInP) const
{ return (const SvxBrushItem&)Get( RES_BACKGROUND,bInP); }
+inline const XFillStyleItem &SwAttrSet::GetFillStyle(sal_Bool bInP) const
+ { return (const XFillStyleItem&)Get( RES_FILL_STYLE,bInP); }
inline const SvxShadowItem &SwAttrSet::GetShadow(sal_Bool bInP) const
{ return (const SvxShadowItem&)Get( RES_SHADOW,bInP); }
inline const SvxFmtBreakItem &SwAttrSet::GetBreak(sal_Bool bInP) const
diff --git a/sw/inc/hintids.hxx b/sw/inc/hintids.hxx
index 3c522a587aca..8c27a86286e1 100644
--- a/sw/inc/hintids.hxx
+++ b/sw/inc/hintids.hxx
@@ -220,6 +220,7 @@ RES_FRMATR_BEGIN = RES_PARATR_LIST_END,
RES_AUTO_STYLE, // 119
RES_FRMATR_STYLE_NAME, // 120
RES_FRMATR_CONDITIONAL_STYLE_NAME, // 121
+ RES_FILL_STYLE,
RES_FRMATR_END
};
diff --git a/sw/inc/swatrset.hxx b/sw/inc/swatrset.hxx
index 0f502e2a42e7..48893466e532 100644
--- a/sw/inc/swatrset.hxx
+++ b/sw/inc/swatrset.hxx
@@ -74,6 +74,7 @@ class SwFmtHoriOrient;
class SwFmtAnchor;
class SvxBoxItem;
class SvxBrushItem;
+class XFillStyleItem;
class SvxShadowItem;
class SwFmtPageDesc;
class SvxFmtBreakItem;
@@ -270,6 +271,7 @@ public:
inline const SvxBoxItem &GetBox( sal_Bool = sal_True ) const;
inline const SvxFmtKeepItem &GetKeep( sal_Bool = sal_True ) const;
inline const SvxBrushItem &GetBackground( sal_Bool = sal_True ) const;
+ inline const XFillStyleItem &GetFillStyle( sal_Bool = sal_True ) const;
inline const SvxShadowItem &GetShadow( sal_Bool = sal_True ) const;
inline const SwFmtPageDesc &GetPageDesc( sal_Bool = sal_True ) const;
inline const SvxFmtBreakItem &GetBreak( sal_Bool = sal_True ) const;
diff --git a/sw/source/core/access/accpara.cxx b/sw/source/core/access/accpara.cxx
index a66aeb5e4abb..983fb29e9664 100644
--- a/sw/source/core/access/accpara.cxx
+++ b/sw/source/core/access/accpara.cxx
@@ -913,10 +913,11 @@ static bool lcl_GetBackgroundColor( Color & rColor,
SwCrsrShell* pCrsrSh )
{
const SvxBrushItem* pBackgrdBrush = 0;
+ const XFillStyleItem* pFillStyleItem = 0;
const Color* pSectionTOXColor = 0;
SwRect aDummyRect;
if ( pFrm &&
- pFrm->GetBackgroundBrush( pBackgrdBrush, pSectionTOXColor, aDummyRect, false ) )
+ pFrm->GetBackgroundBrush( pBackgrdBrush, pFillStyleItem, pSectionTOXColor, aDummyRect, false ) )
{
if ( pSectionTOXColor )
{
diff --git a/sw/source/core/bastyp/init.cxx b/sw/source/core/bastyp/init.cxx
index 73bc1df0070f..77829f440931 100644
--- a/sw/source/core/bastyp/init.cxx
+++ b/sw/source/core/bastyp/init.cxx
@@ -110,6 +110,7 @@
#include <rtl/instance.hxx>
#include <svl/macitem.hxx>
#include <svx/dialogs.hrc>
+#include <svx/xfillit0.hxx>
#include <swcalwrp.hxx>
#include <SwStyleNameMapper.hxx>
#include <tblafmt.hxx>
@@ -379,6 +380,7 @@ SfxItemInfo aSlotTab[] =
{ 0, 0 }, // RES_AUTO_STYLE
{ 0, SFX_ITEM_POOLABLE }, // RES_FRMATR_STYLE_NAME
{ 0, SFX_ITEM_POOLABLE }, // RES_FRMATR_CONDITIONAL_STYLE_NAME
+ { 0, SFX_ITEM_POOLABLE }, // RES_FILL_STYLE
{ 0, SFX_ITEM_POOLABLE }, // RES_GRFATR_MIRRORGRF
{ SID_ATTR_GRAF_CROP, SFX_ITEM_POOLABLE }, // RES_GRFATR_CROPGRF
@@ -594,6 +596,7 @@ void _InitCore()
aAttrTab[ RES_AUTO_STYLE - POOLATTR_BEGIN ] = new SwFmtAutoFmt( RES_AUTO_STYLE );
aAttrTab[ RES_FRMATR_STYLE_NAME - POOLATTR_BEGIN ] = new SfxStringItem( RES_FRMATR_STYLE_NAME, aEmptyStr );
aAttrTab[ RES_FRMATR_CONDITIONAL_STYLE_NAME - POOLATTR_BEGIN ] = new SfxStringItem( RES_FRMATR_CONDITIONAL_STYLE_NAME, aEmptyStr );
+ aAttrTab[ RES_FILL_STYLE - POOLATTR_BEGIN ] = new XFillStyleItem(XFILL_SOLID, RES_FILL_STYLE);
aAttrTab[ RES_GRFATR_MIRRORGRF- POOLATTR_BEGIN ] = new SwMirrorGrf;
aAttrTab[ RES_GRFATR_CROPGRF- POOLATTR_BEGIN ] = new SwCropGrf;
diff --git a/sw/source/core/doc/notxtfrm.cxx b/sw/source/core/doc/notxtfrm.cxx
index e87c9bf26a32..84fc446483c8 100644
--- a/sw/source/core/doc/notxtfrm.cxx
+++ b/sw/source/core/doc/notxtfrm.cxx
@@ -209,10 +209,10 @@ static void lcl_ClearArea( const SwFrm &rFrm,
if ( !aRegion.empty() )
{
- const SvxBrushItem *pItem; const Color *pCol; SwRect aOrigRect;
- if ( rFrm.GetBackgroundBrush( pItem, pCol, aOrigRect, sal_False ) )
+ const SvxBrushItem *pItem; const XFillStyleItem* pFillStyleItem; const Color *pCol; SwRect aOrigRect;
+ if ( rFrm.GetBackgroundBrush( pItem, pFillStyleItem, pCol, aOrigRect, sal_False ) )
for( sal_uInt16 i = 0; i < aRegion.size(); ++i )
- ::DrawGraphic( pItem, &rOut, aOrigRect, aRegion[i] );
+ ::DrawGraphic( pItem, pFillStyleItem, &rOut, aOrigRect, aRegion[i] );
else
{
rOut.Push( PUSH_FILLCOLOR|PUSH_LINECOLOR );
diff --git a/sw/source/core/inc/frame.hxx b/sw/source/core/inc/frame.hxx
index 857a666f8e34..96d59bf6d0a8 100644
--- a/sw/source/core/inc/frame.hxx
+++ b/sw/source/core/inc/frame.hxx
@@ -48,6 +48,7 @@ class Color;
class SwBorderAttrs;
class SwCache;
class SvxBrushItem;
+class XFillStyleItem;
class SwSelectionList;
struct SwPosition;
struct SwCrsrMoveState;
@@ -501,6 +502,7 @@ public:
void Retouche( const SwPageFrm *pPage, const SwRect &rRect ) const;
sal_Bool GetBackgroundBrush( const SvxBrushItem*& rpBrush,
+ const XFillStyleItem* & rpFillStyle,
const Color*& rpColor,
SwRect &rOrigRect,
sal_Bool bLowerMode ) const;
diff --git a/sw/source/core/inc/frmtool.hxx b/sw/source/core/inc/frmtool.hxx
index ce2756739a4f..78af6f009085 100644
--- a/sw/source/core/inc/frmtool.hxx
+++ b/sw/source/core/inc/frmtool.hxx
@@ -36,6 +36,7 @@ class SwAttrSet;
class SdrObject;
class BigInt;
class SvxBrushItem;
+class XFillStyleItem;
class SdrMarkList;
class SwNodeIndex;
class OutputDevice;
@@ -50,7 +51,7 @@ class SwPageDesc;
// draw background with brush or graphics
// The 6th parameter indicates that the method should consider background
// transparency, saved in the color of the brush item.
-void DrawGraphic( const SvxBrushItem *, OutputDevice *,
+void DrawGraphic( const SvxBrushItem *, const XFillStyleItem*, OutputDevice *,
const SwRect &rOrg, const SwRect &rOut, const sal_uInt8 nGrfNum = GRFNUM_NO,
const sal_Bool bConsiderBackgroundTransparency = sal_False );
diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx
index 40cf3523b647..94dedda3386e 100644
--- a/sw/source/core/layout/paintfrm.cxx
+++ b/sw/source/core/layout/paintfrm.cxx
@@ -1785,6 +1785,7 @@ static void lcl_DrawGraphic( const SvxBrushItem& rBrush, OutputDevice *pOut,
} // end of method <lcl_DrawGraphic>
void DrawGraphic( const SvxBrushItem *pBrush,
+ const XFillStyleItem* pFillStyleItem,
OutputDevice *pOutDev,
const SwRect &rOrg,
const SwRect &rOut,
@@ -2076,7 +2077,7 @@ void DrawGraphic( const SvxBrushItem *pBrush,
/// draw poly-polygon transparent
pOutDev->DrawTransparent( aDrawPoly, nTransparencyPercent );
}
- else if (!pBrush || pBrush->GetFillStyle() != drawing::FillStyle_GRADIENT)
+ else if (!pFillStyleItem || pFillStyleItem->GetValue() != XFILL_GRADIENT)
{
SwRegionRects aRegion( rOut, 4 );
if ( !bGrfIsTransparent )
@@ -3710,9 +3711,10 @@ sal_Bool SwFlyFrm::IsBackgroundTransparent() const
static_cast<const SwFlyFrmFmt*>(GetFmt())->IsBackgroundBrushInherited() )
{
const SvxBrushItem* pBackgrdBrush = 0;
+ const XFillStyleItem* pFillStyleItem = 0;
const Color* pSectionTOXColor = 0;
SwRect aDummyRect;
- if ( GetBackgroundBrush( pBackgrdBrush, pSectionTOXColor, aDummyRect, false) )
+ if ( GetBackgroundBrush( pBackgrdBrush, pFillStyleItem, pSectionTOXColor, aDummyRect, false) )
{
if ( pSectionTOXColor &&
(pSectionTOXColor->GetTransparency() != 0) &&
@@ -6083,6 +6085,7 @@ void SwFrm::PaintBackground( const SwRect &rRect, const SwPageFrm *pPage,
SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pSh->GetOut() );
const SvxBrushItem* pItem;
+ const XFillStyleItem* pFillStyleItem;
/// OD 05.09.2002 #102912#
/// temporary background brush for a fly frame without a background brush
SvxBrushItem* pTmpBackBrush = 0;
@@ -6091,7 +6094,7 @@ void SwFrm::PaintBackground( const SwRect &rRect, const SwPageFrm *pPage,
const bool bPageFrm = IsPageFrm();
sal_Bool bLowMode = sal_True;
- sal_Bool bBack = GetBackgroundBrush( pItem, pCol, aOrigBackRect, bLowerMode );
+ sal_Bool bBack = GetBackgroundBrush( pItem, pFillStyleItem, pCol, aOrigBackRect, bLowerMode );
//- Output if a separate background is used.
bool bNoFlyBackground = !bFlyMetafile && !bBack && IsFlyFrm();
if ( bNoFlyBackground )
@@ -6101,7 +6104,7 @@ void SwFrm::PaintBackground( const SwRect &rRect, const SwPageFrm *pPage,
// <GetBackgroundBrush> disabled this option with the parameter <bLowerMode>
if ( bLowerMode )
{
- bBack = GetBackgroundBrush( pItem, pCol, aOrigBackRect, false );
+ bBack = GetBackgroundBrush( pItem, pFillStyleItem, pCol, aOrigBackRect, false );
}
// If still no background found for the fly frame, initialize the
// background brush <pItem> with global retouche color and set <bBack>
@@ -6192,7 +6195,7 @@ void SwFrm::PaintBackground( const SwRect &rRect, const SwPageFrm *pPage,
/// Set missing 5th parameter to the default value GRFNUM_NO
/// - see declaration in /core/inc/frmtool.hxx.
if (IsTxtFrm() || !bOnlyTxtBackground)
- ::DrawGraphic( pItem, pOut, aOrigBackRect, aRegion[i], GRFNUM_NO,
+ ::DrawGraphic( pItem, pFillStyleItem, pOut, aOrigBackRect, aRegion[i], GRFNUM_NO,
bConsiderBackgroundTransparency );
}
}
@@ -6869,9 +6872,10 @@ void SwLayoutFrm::RefreshExtraData( const SwRect &rRect ) const
const Color& SwPageFrm::GetDrawBackgrdColor() const
{
const SvxBrushItem* pBrushItem;
+ const XFillStyleItem* pFillStyleItem;
const Color* pDummyColor;
SwRect aDummyRect;
- if ( GetBackgroundBrush( pBrushItem, pDummyColor, aDummyRect, true) )
+ if ( GetBackgroundBrush( pBrushItem, pFillStyleItem, pDummyColor, aDummyRect, true) )
return pBrushItem->GetColor();
else
return aGlobalRetoucheColor;
@@ -6996,6 +7000,9 @@ void SwFrm::Retouche( const SwPageFrm * pPage, const SwRect &rRect ) const
@param rpBrush
output parameter - constant reference pointer the found background brush
+ @param rpFillStyle
+ output parameter - constant reference pointer the found background fill style
+
@param rpCol
output parameter - constant reference pointer to the color of the index shading
set under special conditions, if background brush is taken from an index section.
@@ -7012,6 +7019,7 @@ void SwFrm::Retouche( const SwPageFrm * pPage, const SwRect &rRect ) const
@return true, if a background brush for the frame is found
*/
sal_Bool SwFrm::GetBackgroundBrush( const SvxBrushItem* & rpBrush,
+ const XFillStyleItem* & rpFillStyle,
const Color*& rpCol,
SwRect &rOrigRect,
sal_Bool bLowerMode ) const
@@ -7020,12 +7028,14 @@ sal_Bool SwFrm::GetBackgroundBrush( const SvxBrushItem* & rpBrush,
ViewShell *pSh = getRootFrm()->GetCurrShell();
const SwViewOption *pOpt = pSh->GetViewOptions();
rpBrush = 0;
+ rpFillStyle = 0;
rpCol = NULL;
do
{ if ( pFrm->IsPageFrm() && !pOpt->IsPageBack() )
return sal_False;
const SvxBrushItem &rBack = pFrm->GetAttrSet()->GetBackground();
+ const XFillStyleItem &rFillStyle = pFrm->GetAttrSet()->GetFillStyle();
if( pFrm->IsSctFrm() )
{
const SwSection* pSection = ((SwSectionFrm*)pFrm)->GetSection();
@@ -7067,10 +7077,11 @@ sal_Bool SwFrm::GetBackgroundBrush( const SvxBrushItem* & rpBrush,
if ( !rBack.GetColor().GetTransparency() ||
rBack.GetGraphicPos() != GPOS_NONE ||
rpCol ||
- (bConsiderBackgroundTransparency && (rBack.GetColor() != COL_TRANSPARENT || rBack.GetFillStyle() == drawing::FillStyle_GRADIENT))
+ (bConsiderBackgroundTransparency && (rBack.GetColor() != COL_TRANSPARENT || rFillStyle.GetValue() == XFILL_GRADIENT))
)
{
rpBrush = &rBack;
+ rpFillStyle = &rFillStyle;
if ( pFrm->IsPageFrm() &&
pSh->GetViewOptions()->getBrowseMode() )
rOrigRect = pFrm->Frm();
diff --git a/sw/source/core/text/inftxt.cxx b/sw/source/core/text/inftxt.cxx
index e37128db691b..8d8543d9ab3c 100644
--- a/sw/source/core/text/inftxt.cxx
+++ b/sw/source/core/text/inftxt.cxx
@@ -513,13 +513,14 @@ static sal_Bool lcl_IsDarkBackground( const SwTxtPaintInfo& rInf )
if( ! pCol || COL_TRANSPARENT == pCol->GetColor() )
{
const SvxBrushItem* pItem;
+ const XFillStyleItem* pFillStyleItem;
SwRect aOrigBackRect;
// Consider, that [GetBackgroundBrush(...)] can set <pCol>
// See implementation in /core/layout/paintfrm.cxx
// There is a background color, if there is a background brush and
// its color is *not* "no fill"/"auto fill".
- if( rInf.GetTxtFrm()->GetBackgroundBrush( pItem, pCol, aOrigBackRect, sal_False ) )
+ if( rInf.GetTxtFrm()->GetBackgroundBrush( pItem, pFillStyleItem, pCol, aOrigBackRect, sal_False ) )
{
if ( !pCol )
pCol = &pItem->GetColor();
@@ -884,7 +885,7 @@ void SwTxtPaintInfo::DrawRect( const SwRect &rRect, sal_Bool bNoGraphic,
else
{
OSL_ENSURE( ((SvxBrushItem*)-1) != pBrushItem, "DrawRect: Uninitialized BrushItem!" );
- ::DrawGraphic( pBrushItem, pOut, aItemRect, rRect );
+ ::DrawGraphic( pBrushItem, 0, pOut, aItemRect, rRect );
}
}
}
diff --git a/sw/source/core/text/porfld.cxx b/sw/source/core/text/porfld.cxx
index 94d39866ceb5..9217a05ee512 100644
--- a/sw/source/core/text/porfld.cxx
+++ b/sw/source/core/text/porfld.cxx
@@ -1021,7 +1021,7 @@ void SwGrfNumPortion::Paint( const SwTxtPaintInfo &rInf ) const
}
if( bDraw && aTmp.HasArea() )
- DrawGraphic( pBrush, (OutputDevice*)rInf.GetOut(),
+ DrawGraphic( pBrush, 0, (OutputDevice*)rInf.GetOut(),
aTmp, aRepaint, bReplace ? GRFNUM_REPLACE : GRFNUM_YES );
}
diff --git a/sw/source/core/text/txtfly.cxx b/sw/source/core/text/txtfly.cxx
index b6653dbc27bb..bc9ee742f51c 100644
--- a/sw/source/core/text/txtfly.cxx
+++ b/sw/source/core/text/txtfly.cxx
@@ -658,7 +658,7 @@ void SwTxtFly::DrawFlyRect( OutputDevice* pOut, const SwRect &rRect,
{
OSL_ENSURE( ((SvxBrushItem*)-1) != rInf.GetBrushItem(),
"DrawRect: Uninitialized BrushItem!" );
- ::DrawGraphic( rInf.GetBrushItem(), pOut, rInf.GetBrushRect(),
+ ::DrawGraphic( rInf.GetBrushItem(), 0, pOut, rInf.GetBrushRect(),
aRegion[i] );
}
}
diff --git a/sw/source/core/txtnode/fntcache.cxx b/sw/source/core/txtnode/fntcache.cxx
index a0ef06a38740..030e3efa4278 100644
--- a/sw/source/core/txtnode/fntcache.cxx
+++ b/sw/source/core/txtnode/fntcache.cxx
@@ -2539,6 +2539,7 @@ sal_Bool SwDrawTextInfo::ApplyAutoColor( Font* pFont )
if( ! pCol || COL_TRANSPARENT == pCol->GetColor() )
{
const SvxBrushItem* pItem;
+ const XFillStyleItem* pFillStyleItem;
SwRect aOrigBackRect;
/// OD 21.08.2002
@@ -2547,7 +2548,7 @@ sal_Bool SwDrawTextInfo::ApplyAutoColor( Font* pFont )
/// OD 21.08.2002 #99657#
/// There is a user defined setting for the background, if there
/// is a background brush and its color is *not* "no fill"/"auto fill".
- if( GetFrm()->GetBackgroundBrush( pItem, pCol, aOrigBackRect, sal_False ) )
+ if( GetFrm()->GetBackgroundBrush( pItem, pFillStyleItem, pCol, aOrigBackRect, sal_False ) )
{
if ( !pCol )
{
diff --git a/sw/source/core/unocore/unoframe.cxx b/sw/source/core/unocore/unoframe.cxx
index b289c7df7ccc..07362cad3e3b 100644
--- a/sw/source/core/unocore/unoframe.cxx
+++ b/sw/source/core/unocore/unoframe.cxx
@@ -19,6 +19,7 @@
#include <com/sun/star/embed/NoVisualAreaSizeException.hpp>
#include <com/sun/star/container/XChild.hpp>
+#include <com/sun/star/drawing/FillStyle.hpp>
#include <com/sun/star/embed/XClassifiedObject.hpp>
#include <com/sun/star/embed/XVisualObject.hpp>
#include <com/sun/star/embed/XComponentSupplier.hpp>
@@ -26,6 +27,7 @@
#include <com/sun/star/embed/Aspects.hpp>
#include <com/sun/star/graphic/XGraphicProvider.hpp>
#include <svx/svxids.hrc>
+#include <svx/xfillit0.hxx>
#include <editeng/memberids.hrc>
#include <swtypes.hxx>
@@ -173,8 +175,6 @@ bool BaseFrameProperties_Impl::FillBaseProperties(SfxItemSet& rToSet, const SfxI
GetProperty(RES_BACKGROUND, MID_BACK_COLOR_R_G_B, pRGBCol );
const ::uno::Any* pColTrans = 0;
GetProperty(RES_BACKGROUND, MID_BACK_COLOR_TRANSPARENCY, pColTrans);
- const ::uno::Any* pFillStyle = 0;
- GetProperty(RES_BACKGROUND, MID_FILL_STYLE, pFillStyle);
const ::uno::Any* pGradient = 0;
GetProperty(RES_BACKGROUND, MID_FILL_GRADIENT, pGradient);
const ::uno::Any* pTrans = 0;
@@ -189,15 +189,13 @@ bool BaseFrameProperties_Impl::FillBaseProperties(SfxItemSet& rToSet, const SfxI
GetProperty(RES_BACKGROUND, MID_GRAPHIC_TRANSPARENCY, pGrTranparency );
if(pCol || pTrans || pGrURL || pGrFilter || pGrLoc ||
- pGrTranparency || pColTrans || pRGBCol || pFillStyle || pGradient)
+ pGrTranparency || pColTrans || pRGBCol || pGradient)
{
SvxBrushItem aBrush ( static_cast < const :: SvxBrushItem & > ( rFromSet.Get ( RES_BACKGROUND ) ) );
if(pCol )
bRet &= ((SfxPoolItem&)aBrush).PutValue(*pCol,MID_BACK_COLOR );
if(pColTrans)
bRet &= ((SfxPoolItem&)aBrush).PutValue(*pColTrans, MID_BACK_COLOR_TRANSPARENCY);
- if(pFillStyle)
- bRet &= ((SfxPoolItem&)aBrush).PutValue(*pFillStyle, MID_FILL_STYLE);
if(pGradient)
bRet &= ((SfxPoolItem&)aBrush).PutValue(*pGradient, MID_FILL_GRADIENT);
if(pRGBCol)
@@ -221,6 +219,16 @@ bool BaseFrameProperties_Impl::FillBaseProperties(SfxItemSet& rToSet, const SfxI
}
}
{
+ const ::uno::Any* pFillStyle = 0;
+ GetProperty(RES_FILL_STYLE, 0, pFillStyle);
+ if (pFillStyle)
+ {
+ XFillStyleItem aFillStyle( static_cast <const :: XFillStyleItem & > ( rFromSet.Get ( RES_FILL_STYLE ) ) );
+ bRet &= ((SfxPoolItem&)aFillStyle).PutValue(*pFillStyle);
+ rToSet.Put(aFillStyle);
+ }
+ }
+ {
const ::uno::Any* pCont = 0;
GetProperty(RES_PROTECT, MID_PROTECT_CONTENT, pCont );
const ::uno::Any* pPos = 0;
diff --git a/sw/source/core/unocore/unomap.cxx b/sw/source/core/unocore/unomap.cxx
index f4903431884a..e80c7cbe8b82 100644
--- a/sw/source/core/unocore/unomap.cxx
+++ b/sw/source/core/unocore/unomap.cxx
@@ -288,7 +288,7 @@ SwUnoPropertyMapProvider::~SwUnoPropertyMapProvider()
{ SW_PROP_NMID(UNO_NAME_BACK_COLOR), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_INT32), PROPERTY_NONE ,MID_BACK_COLOR }, \
{ SW_PROP_NMID(UNO_NAME_BACK_COLOR_R_G_B), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_INT32), PROPERTY_NONE ,MID_BACK_COLOR_R_G_B}, \
{ SW_PROP_NMID(UNO_NAME_BACK_COLOR_TRANSPARENCY), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_INT8), PROPERTY_NONE ,MID_BACK_COLOR_TRANSPARENCY}, \
- { SW_PROP_NMID(UNO_NAME_FILL_STYLE), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_FILLSTYLE), PROPERTY_NONE ,MID_FILL_STYLE}, \
+ { SW_PROP_NMID(UNO_NAME_FILL_STYLE), RES_FILL_STYLE, CPPU_E2T(CPPUTYPE_FILLSTYLE), PROPERTY_NONE ,0}, \
{ SW_PROP_NMID(UNO_NAME_FILL_GRADIENT), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_GRADIENT), PROPERTY_NONE ,MID_FILL_GRADIENT}, \
{ SW_PROP_NMID(UNO_NAME_CONTENT_PROTECTED), RES_PROTECT, CPPU_E2T(CPPUTYPE_BOOLEAN), PROPERTY_NONE, MID_PROTECT_CONTENT }, \
{ SW_PROP_NMID(UNO_NAME_FRAME_STYLE_NAME), FN_UNO_FRAME_STYLE_NAME,CPPU_E2T(CPPUTYPE_OUSTRING), PROPERTY_NONE, 0}, \
@@ -666,7 +666,7 @@ const SfxItemPropertyMapEntry* SwUnoPropertyMapProvider::GetPropertyMapEntries(s
{ SW_PROP_NMID(UNO_NAME_BACK_COLOR), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_INT32), PROPERTY_NONE ,MID_BACK_COLOR },
{ SW_PROP_NMID(UNO_NAME_BACK_COLOR_R_G_B), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_INT32), PROPERTY_NONE ,MID_BACK_COLOR_R_G_B},
{ SW_PROP_NMID(UNO_NAME_BACK_COLOR_TRANSPARENCY), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_INT8), PROPERTY_NONE ,MID_BACK_COLOR_TRANSPARENCY}, \
- { SW_PROP_NMID(UNO_NAME_FILL_STYLE), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_FILLSTYLE), PROPERTY_NONE ,MID_FILL_STYLE},
+ { SW_PROP_NMID(UNO_NAME_FILL_STYLE), RES_FILL_STYLE, CPPU_E2T(CPPUTYPE_FILLSTYLE), PROPERTY_NONE ,0},
{ SW_PROP_NMID(UNO_NAME_FILL_GRADIENT), RES_BACKGROUND, CPPU_E2T(CPPUTYPE_GRADIENT), PROPERTY_NONE ,MID_FILL_GRADIENT},
// { SW_PROP_NMID(UNO_NAME_CHAIN_NEXT_NAME), RES_CHAIN, CPPU_E2T(CPPUTYPE_OUSTRING), PROPERTY_NONE ,MID_CHAIN_NEXTNAME},
// { SW_PROP_NMID(UNO_NAME_CHAIN_PREV_NAME), RES_CHAIN, CPPU_E2T(CPPUTYPE_OUSTRING), PROPERTY_NONE ,MID_CHAIN_PREVNAME},