svx/source/unodraw/unobrushitemhelper.cxx |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

New commits:
commit fc1727cb321e452cc2289315009f27243d6245a1
Author: Miklos Vajna <vmik...@collabora.co.uk>
Date:   Mon Jun 30 18:04:18 2014 +0200

    getSvxBrushItemFromSourceSet: add fix for JunitTest_sw_complex
    
    Change-Id: I826cd15923ecb2088161e4cf9650b2f388fd84b5

diff --git a/svx/source/unodraw/unobrushitemhelper.cxx 
b/svx/source/unodraw/unobrushitemhelper.cxx
index c95c200..f6fe915 100644
--- a/svx/source/unodraw/unobrushitemhelper.cxx
+++ b/svx/source/unodraw/unobrushitemhelper.cxx
@@ -191,7 +191,15 @@ SvxBrushItem getSvxBrushItemFromSourceSet(const 
SfxItemSet& rSourceSet, sal_uInt
 
     if(!pXFillStyleItem || XFILL_NONE == pXFillStyleItem->GetValue())
     {
-        Color aFillColor(COL_AUTO);
+        // no fill, still need to rescue the evtl. set RGB color, but use as 
transparent color (we have XFILL_NONE)
+        Color aFillColor(static_cast< const XFillColorItem& 
>(rSourceSet.Get(XATTR_FILLCOLOR, bSearchInParents)).GetColorValue());
+
+        // when fill style is none, then don't allow anything other than 0 or 
auto.
+        if (aFillColor.GetColor() != 0)
+            aFillColor.SetColor(COL_AUTO);
+
+        aFillColor.SetTransparency(0xff);
+
         return SvxBrushItem(aFillColor, nBackgroundID);
     }
 
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to