--- svx/source/unodraw/unoshap2.cxx	27 Jun 2007 19:26:23 -0000	1.63
+++ svx/source/unodraw/unoshap2.cxx	12 Jul 2007 13:07:34 -0000
@@ -1746,6 +1746,15 @@
 				}
 			}
 		}
+		else if( aValue.getValueType() == INTERFACE_TYPE( graphic::XGraphic ))
+		{
+			Reference< graphic::XGraphic > xGraphic( aValue, UNO_QUERY );
+			if( xGraphic.is() )
+			{
+				Graphic aGraphic( xGraphic );
+				((SdrGrafObj*)mpObj.get())->SetGraphic(aGraphic);
+			}
+		}
 	}
 	else if( mpObj.is() && aPropertyName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM(UNO_NAME_GRAPHOBJ_GRAFURL)))
 	{
@@ -2168,6 +2177,7 @@
 
 	if ( bCustomShapeGeometry )
 	{
+		((SdrObjCustomShape*)pObject)->MergeDefaultAttributes(0);
 		Rectangle aRect( pObject->GetSnapRect() );
 
 		// #i38892#
--- svx/source/xoutdev/xattrbmp.cxx	27 Jun 2007 19:33:53 -0000	1.16
+++ svx/source/xoutdev/xattrbmp.cxx	12 Jul 2007 13:07:38 -0000
@@ -36,6 +36,7 @@
 // MARKER(update_precomp.py): autogen include statement, do not remove
 #include "precompiled_svx.hxx"
 #include <com/sun/star/awt/XBitmap.hpp>
+#include <com/sun/star/graphic/XGraphic.hpp>
 #include <tools/stream.hxx>
 #include <vcl/window.hxx>
 #include <vcl/virdev.hxx>
@@ -802,6 +803,7 @@
     ::rtl::OUString aName;
     ::rtl::OUString aURL;
     ::com::sun::star::uno::Reference< ::com::sun::star::awt::XBitmap > xBmp;
+    ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > xGraphic;
 
     bool bSetName   = false;
     bool bSetURL    = false;
@@ -812,7 +814,11 @@
     else if( nMemberId == MID_GRAFURL )
 		bSetURL = (rVal >>= aURL);
 	else if( nMemberId == MID_BITMAP )
+	{
         bSetBitmap = (rVal >>= xBmp);
+		if ( !bSetBitmap )
+			bSetBitmap = (rVal >>= xGraphic );
+	}
     else
     {
         DBG_ASSERT( nMemberId == 0, "invalid member-id" );
@@ -843,8 +849,17 @@
     }
     if( bSetBitmap )
     {
-        BitmapEx aInputEx( VCLUnoHelper::GetBitmap( xBmp ) );
-        Bitmap aInput( aInputEx.GetBitmap() );
+		Bitmap aInput;
+		if ( xBmp.is() )
+		{
+	        BitmapEx aInputEx( VCLUnoHelper::GetBitmap( xBmp ) );
+		    aInput = aInputEx.GetBitmap();
+		}
+		else if ( xGraphic.is() )
+		{
+			Graphic aGraphic( xGraphic );
+		    aInput = aGraphic.GetBitmap();
+		}
 
         // note: aXOBitmap is the member bitmap
         aXOBitmap.SetBitmap( aInput );
