Commits

Anonymous committed 0f38b2c

CWS-TOOLING: integrate CWS os132
2009-07-21 15:24:18 +0200 os r274201 : #i103696# SwXTextPortion/SwXParagraph excluded
2009-07-15 13:19:17 +0200 os r274007 : #i103564# typo
2009-07-15 13:09:30 +0200 os r274005 : #i103564# SwFrames::hasElements
2009-07-15 13:02:16 +0200 os r274003 : #i103564# SwXBookmark::getPropertySetInfo fixed
2009-06-26 10:11:00 +0200 os r273395 : CWS-TOOLING: rebase CWS os132 to trunk@272827 (milestone: DEV300:m50)
2009-06-23 08:52:24 +0200 os r273256 : #i102764# patch: attribute ListBoxes correctly handled in ::Reset()
2009-06-23 08:51:31 +0200 os r273255 : #i102764# ResetColor() added to remove background color
2009-06-22 14:57:38 +0200 os r273233 : #i102619# prevent access to already destroyed shell
2009-06-18 13:26:51 +0200 os r273112 : #i99508# ::insertTextContent: re-route to ::attach()
2009-06-18 10:59:53 +0200 os r273107 : #i85405# patch to enable 'Print grid' CheckBox correctly
2009-06-18 10:54:02 +0200 os r273106 : #i85133# dispose connection in GetColumnFmt to prevent connection locking
2009-06-18 10:24:31 +0200 os r273104 : #99535# ExportGraphic changed
2009-06-18 10:24:03 +0200 os r273103 : #99535# ExportGraphic changed
2009-06-18 10:23:11 +0200 os r273102 : #i102841# redlining mode switches to insert mode (cmc)
2009-06-17 14:05:42 +0200 os r273070 : #i102111# do not save already saved HTML documents before switching to source veiw
2009-06-17 13:18:20 +0200 os r273063 : #i101825# set rembered start position at the real start not at the initial start
2009-06-17 08:24:10 +0200 os r273048 : #99535# no dierect access to the file picker interface
2009-06-16 15:00:12 +0200 os r273020 : #i99937# notification of user options changes re-introduced
2009-06-15 14:36:03 +0200 os r272987 : #i98032# unreplaced text in protected areas must not be attributed either
2009-06-15 14:20:26 +0200 os r272985 : #i98032# replace list has to be initialised
2009-06-04 13:29:02 +0200 os r272624 : #i97810# set focus into column page
2009-06-04 11:01:14 +0200 os r272617 : #i98164# dialog resize to ease localisation
2009-06-04 10:59:44 +0200 os r272616 : #i98164# dialog resize to ease localisation
2009-05-28 16:05:03 +0200 os r272413 : #i98172# ConvertFieldsToText: take care of tabs with attributes
2009-05-28 11:12:45 +0200 os r272385 : #i59361# dialog controls resized
2009-05-28 11:03:14 +0200 os r272383 : #i59174# dialog controls moved

Comments (0)

Files changed (33)

sfx2/source/control/unoctitm.cxx

         sal_Bool bFailure = sal_False;
         const SfxPoolItem* pItem = NULL;
         SfxShell* pShell( 0 );
+        // #i102619# Retrieve metric from shell before execution - the shell could be destroyed after execution 
+        SfxMapUnit eMapUnit( SFX_MAPUNIT_100TH_MM );
         if ( pDispatcher->GetBindings() )
         {
             if ( !pDispatcher->IsLocked( GetId() ) )
                         lNewArgs[nIndex].Value  = makeAny( SfxDispatchController_Impl::getSlaveCommand( aDispatchURL ));
                     }
 
+                    eMapUnit = GetCoreMetric( pShell->GetPool(), GetId() );
                     SfxAllItemSet aSet( pShell->GetPool() );
                     TransformParameters( GetId(), lNewArgs, aSet, pSlot );
                     if ( aSet.Count() )
         }
         else
         {
+            eMapUnit = GetCoreMetric( SFX_APP()->GetPool(), GetId() );
             // AppDispatcher
             SfxAllItemSet aSet( SFX_APP()->GetPool() );
             TransformParameters( GetId(), lNewArgs, aSet );
             aEvent.Source = (::com::sun::star::frame::XDispatch*) pDispatch;
             if ( bSuccess && pItem && !pItem->ISA(SfxVoidItem) )
             {
-                // Retrieve metric from pool to have correct sub ID when calling QueryValue
-                SfxMapUnit eMapUnit( SFX_MAPUNIT_100TH_MM );
-                if ( pShell )
-                    eMapUnit = GetCoreMetric( pShell->GetPool(), GetId() );
-                else
-                    eMapUnit = GetCoreMetric( SFX_APP()->GetPool(), GetId() );
-
                 USHORT nSubId( 0 );
                 if ( eMapUnit == SFX_MAPUNIT_TWIP )
                     nSubId |= CONVERT_TWIPS;

svtools/source/config/useroptions.cxx

 #include <rtl/logfile.hxx>
 #include "itemholder2.hxx"
 
-#ifndef _COM_SUN_STAR_BEANS_PROPERTY_HPP_ 
 #include <com/sun/star/beans/Property.hpp>
-#endif
-
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_ 
 #include <com/sun/star/beans/XPropertySet.hpp> 
-#endif
-
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
 #include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_ 
 #include <com/sun/star/container/XNameAccess.hpp> 
-#endif
-
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_ 
 #include <com/sun/star/container/XNameContainer.hpp> 
-#endif
-
-#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_ 
 #include <com/sun/star/lang/XSingleServiceFactory.hpp> 
-#endif
-
-#ifndef _COMPHELPER_CONFIGURATIONHELPER_HXX_ 
+#include <com/sun/star/util/XChangesListener.hpp>
+#include <com/sun/star/util/XChangesNotifier.hpp>
+#include <com/sun/star/util/ChangesEvent.hpp>
 #include <comphelper/configurationhelper.hxx> 
-#endif
-
-#ifndef _UNOTOOLS_PROCESSFACTORY_HXX_ 
 #include <unotools/processfactory.hxx> 
-#endif
-
-#ifndef _SVT_LOGHELPER_HXX 
-#include "loghelper.hxx" 
-#endif
+#include <loghelper.hxx>
 
 using namespace utl;
 using namespace rtl;
+using namespace com::sun::star;
 using namespace com::sun::star::uno;
 
 namespace css = ::com::sun::star;
 
 // class SvtUserOptions_Impl ---------------------------------------------
+class SvtUserOptions_Impl;
+class SvtUserConfigChangeListener_Impl : public cppu::WeakImplHelper1
+<
+    com::sun::star::util::XChangesListener
+>
+{
+        SvtUserOptions_Impl&    m_rParent;
+    public:
+        SvtUserConfigChangeListener_Impl(SvtUserOptions_Impl& rParent);
+        ~SvtUserConfigChangeListener_Impl();
 
-class SvtUserOptions_Impl
+    //XChangesListener
+    virtual void SAL_CALL changesOccurred( const util::ChangesEvent& Event ) throw(RuntimeException);
+    //XEventListener
+    virtual void SAL_CALL disposing( const lang::EventObject& Source ) throw(RuntimeException);
+};
+
+class SvtUserOptions_Impl : public SfxBroadcaster
 {
 public:
 	SvtUserOptions_Impl();
 
 	sal_Bool 		  IsTokenReadonly( USHORT nToken ) const;
     ::rtl::OUString   GetToken(USHORT nToken) const;
+    void              Notify();
 
 private:
-	css::uno::Reference< css::container::XNameAccess > m_xCfg;
+    uno::Reference< util::XChangesListener >           m_xChangeListener;
+    css::uno::Reference< css::container::XNameAccess > m_xCfg;
 	css::uno::Reference< css::beans::XPropertySet >    m_xData;
 	::rtl::OUString m_aLocale;
 };
 
 #define READONLY_DEFAULT	sal_False
 
-// functions -------------------------------------------------------------
+/*-- 16.06.2009 14:22:56---------------------------------------------------
 
-namespace
+  -----------------------------------------------------------------------*/
+SvtUserConfigChangeListener_Impl::SvtUserConfigChangeListener_Impl(SvtUserOptions_Impl& rParent) :
+    m_rParent( rParent )
 {
-    struct PropertyNames
-        : public rtl::Static< Sequence< rtl::OUString >, PropertyNames> {};
+}    
+/*-- 16.06.2009 14:22:56---------------------------------------------------
+
+  -----------------------------------------------------------------------*/
+SvtUserConfigChangeListener_Impl::~SvtUserConfigChangeListener_Impl()
+{
+}
+/*-- 16.06.2009 14:22:56---------------------------------------------------
+
+  -----------------------------------------------------------------------*/
+void SvtUserConfigChangeListener_Impl::changesOccurred( const util::ChangesEvent& rEvent ) throw(RuntimeException)
+{
+    if(rEvent.Changes.getLength())
+        m_rParent.Notify();
+}
+/*-- 16.06.2009 14:22:56---------------------------------------------------
+
+  -----------------------------------------------------------------------*/
+void SvtUserConfigChangeListener_Impl::disposing( const lang::EventObject& rSource ) throw(RuntimeException)
+{
+    try
+    {
+        uno::Reference< util::XChangesNotifier > xChgNot( rSource.Source, UNO_QUERY_THROW);
+        xChgNot->removeChangesListener(this);
+    }
+    catch(Exception& )
+    {
+    }
 }
 
 // class SvtUserOptions_Impl ---------------------------------------------
 
 // -----------------------------------------------------------------------
-SvtUserOptions_Impl::SvtUserOptions_Impl()
+SvtUserOptions_Impl::SvtUserOptions_Impl() :
+    m_xChangeListener( new SvtUserConfigChangeListener_Impl(*this) )
 {
-	try
+    try
 	{
 		m_xCfg = Reference< css::container::XNameAccess > ( 
 			::comphelper::ConfigurationHelper::openConfig( 
 			css::uno::UNO_QUERY ); 
 
 		m_xData = css::uno::Reference< css::beans::XPropertySet >(m_xCfg, css::uno::UNO_QUERY);
+        uno::Reference< util::XChangesNotifier > xChgNot( m_xCfg, UNO_QUERY);
+        try
+        {
+            xChgNot->addChangesListener( m_xChangeListener );
+        }
+        catch(RuntimeException& )
+        {
+        }
 	}
 	catch(const css::uno::Exception& ex) 
 	{ 
 
 // -----------------------------------------------------------------------
 
+void SvtUserOptions_Impl::Notify()
+{
+    Broadcast( SfxSimpleHint( SFX_HINT_USER_OPTIONS_CHANGED ) );
+}
+// -----------------------------------------------------------------------
+
 sal_Bool SvtUserOptions_Impl::IsTokenReadonly( USHORT nToken ) const
 {
 	css::uno::Reference< css::beans::XPropertySet >     xData(m_xCfg, css::uno::UNO_QUERY);
     }
     ++nRefCount;
     pImp = pOptions;
-    //StartListening( *pImp);
+    StartListening( *pImp);
 }
 
 // -----------------------------------------------------------------------

svx/inc/optgenrl.hrc

 #define LINEH		12
 #define FLINEH		8
 #define	LEFT		12
-#define MID         96
+#define MID         100
 #define RIGHT		248
 #define TOP			10
 #define LINE(y)		(14+y*15)

svx/inc/svx/fntctrl.hxx

     SvxFont&            GetCJKFont();
 	SvxFont&			GetCTLFont();
 	void  				SetColor( const Color& rColor );
+    void                ResetColor();
     void                SetBackColor( const Color& rColor );
     void                UseResourceText( BOOL bUse = TRUE );
 	void  				Paint( const Rectangle& );

svx/source/cui/commonlingui.src

 	{
 		HelpId=HID_SPELLDLG_SETWORD;
 		Pos = MAP_APPFONT( 51, 9 );
-		Size = MAP_APPFONT( 149, 10 );
+        Size = MAP_APPFONT( 164, 10 );
 		Border =FALSE;
 		TabStop = TRUE;
 	};
 	Edit ED_NEWWORD
 	{
 		Pos = MAP_APPFONT( 51, 24 );
-		Size = MAP_APPFONT( 122, 12 );
+        Size = MAP_APPFONT( 137, 12 );
 		Border = TRUE;
 	};
 
 
 	PushButton BTN_IGNORE
 	{
-		Pos = MAP_APPFONT( 209, 6 );
+        Pos = MAP_APPFONT( 224, 6 );
 		Size = MAP_APPFONT( 55, 14 );
 		Text [ en-US ] = "~Ignore" ;
 	};
 
 	PushButton BTN_IGNOREALL
 	{
-		Pos = MAP_APPFONT( 209, 22 );
+        Pos = MAP_APPFONT( 224, 22 );
 		Size = MAP_APPFONT( 55, 14 );
 		Text [ en-US ] = "Always I~gnore" ;
 	};
 
 	PushButton BTN_CHANGE
 	{
-		Pos = MAP_APPFONT( 209, 40 );
+        Pos = MAP_APPFONT( 224, 40 );
 		Size = MAP_APPFONT( 55, 14 );
 		Text [ en-US ] = "~Replace" ;
 		DefButton = TRUE ;
 
 	PushButton BTN_CHANGEALL
 	{
-		Pos = MAP_APPFONT( 209, 56 );
+        Pos = MAP_APPFONT( 224, 56 );
 		Size = MAP_APPFONT( 55, 14 );
 		Text [ en-US ] = "Always R~eplace" ;
 	};
 
 	PushButton BTN_OPTIONS
 	{
-		Pos = MAP_APPFONT( 209, 129 );
+        Pos = MAP_APPFONT( 224, 129 );
 		Size = MAP_APPFONT( 55, 14 );
 		Hide = TRUE ;
 		Text [ en-US ] = "Options..." ;
 	GroupBox GB_AUDIT
 	{
 		Pos = MAP_APPFONT( 1, 1 );
-		Size = MAP_APPFONT( 268, 148 );
+        Size = MAP_APPFONT( 283, 148 );
 		Hide=TRUE;
 	};
 
 	HelpButton BTN_SPL_HELP
 	{
-		Pos = MAP_APPFONT( 145, 153 );
+        Pos = MAP_APPFONT( 160, 153 );
 		Size = MAP_APPFONT( 55, 14 );
 	};
 
 	CancelButton BTN_SPL_CANCEL
 	{
-		Pos = MAP_APPFONT ( 209 , 153 ) ;
+        Pos = MAP_APPFONT ( 224 , 153 ) ;
 		Size = MAP_APPFONT ( 55 , 14 ) ;
 		TabStop = TRUE ;
 		Text [ en-US ] = "~Close" ;

svx/source/cui/hangulhanjadlg.src

 ModalDialog RID_SVX_MDLG_HANGULHANJA
 {
 	HelpId = HID_DIALOG_HANGULHANJA;
-	Size = MAP_APPFONT( 287, 175 );
+    Size = MAP_APPFONT( 302, 175 );
 	OutputSize = TRUE;
 	Closeable = TRUE ;
 	Moveable = TRUE ;
 
 	PushButton PB_FIND
 	{
-		Pos = MAP_APPFONT( 192, 23 );
+        Pos = MAP_APPFONT( 207, 23 );
 		Size = MAP_APPFONT( 30, 14 );
 
 		Text [ en-US ] = "~Find";
 	Control CTL_SUGGESTIONS
 	{
 		Pos = MAP_APPFONT( 51, 46 );
-		Size = MAP_APPFONT( 171, 30 );
+        Size = MAP_APPFONT( 186, 30 );
 		TabStop = TRUE ;
 	};
 
 	RadioButton RB_SIMPLE_CONVERSION
 	{
 		Pos = MAP_APPFONT( 51, 81 );
-		Size = MAP_APPFONT( 55, 8 );
+        Size = MAP_APPFONT( 60, 8 );
 
 		Group = TRUE;
 
 
 	RadioButton RB_HANJA_HANGUL_BRACKETED
 	{
-		Pos = MAP_APPFONT( 109, 81 );
-		Size = MAP_APPFONT( 55, 8 );
+        Pos = MAP_APPFONT( 114, 81 );
+        Size = MAP_APPFONT( 60, 8 );
 
 		Text [ en-US ] = "Hanja (Han~gul)";
 	};
 
 	RadioButton RB_HANGUL_HANJA_BRACKETED
 	{
-		Pos = MAP_APPFONT( 167, 81 );
-		Size = MAP_APPFONT( 55, 8 );
+        Pos = MAP_APPFONT( 177, 81 );
+        Size = MAP_APPFONT( 60, 8 );
 
 		Text [ en-US ] = "Hang~ul (Hanja)";
 	};
 	RadioButton RB_HANGUL_HANJA_ABOVE
 	{
 		Pos = MAP_APPFONT( 51, 95 );
-		Size = MAP_APPFONT( 55, 16 );
+        Size = MAP_APPFONT( 60, 16 );
 
 		// this is the _primary_ text
 		Text [ en-US ] = "Hangu~l";
 
 	RadioButton RB_HANGUL_HANJA_BELOW
 	{
-		Pos = MAP_APPFONT( 109, 95 );
-		Size = MAP_APPFONT( 55, 16 );
+        Pos = MAP_APPFONT( 114, 95 );
+        Size = MAP_APPFONT( 60, 16 );
 
 		// this is the _primary_ text
 		Text [ en-US ] = "Hang~ul";
 
 	RadioButton RB_HANJA_HANGUL_ABOVE
 	{
-		Pos = MAP_APPFONT( 51, 114 );
-		Size = MAP_APPFONT( 55, 16 );
+        Pos = MAP_APPFONT( 56, 114 );
+        Size = MAP_APPFONT( 60, 16 );
 
 		// this is the _primary_ text
 		Text [ en-US ] = "Han~ja";
 
 	RadioButton RB_HANJA_HANGUL_BELOW
 	{
-		Pos = MAP_APPFONT( 109, 114 );
-		Size = MAP_APPFONT( 55, 16 );
+        Pos = MAP_APPFONT( 114, 114 );
+        Size = MAP_APPFONT( 60, 16 );
 
 		// this is the _primary_ text
 		Text [ en-US ] = "Ha~nja";
 	CheckBox CB_HANGUL_ONLY
 	{
 		Pos = MAP_APPFONT( 51, 134 );
-		Size = MAP_APPFONT( 55, 8 );
+        Size = MAP_APPFONT( 60, 8 );
 
 		Text [ en-US ] = "Hangul ~only";
 	};
 
 	CheckBox CB_HANJA_ONLY
 	{
-		Pos = MAP_APPFONT( 109, 134 );
+        Pos = MAP_APPFONT( 114, 134 );
 		Size = MAP_APPFONT( 55, 8 );
 
 		Text [ en-US ] = "Hanja onl~y";
 	// this element is only for determining where our radio button group ends (in both directions)
 	FixedText FT_RESIZE_ANCHOR
 	{
-		Pos = MAP_APPFONT( 226, 133 );
+        Pos = MAP_APPFONT( 241, 133 );
 	};
 
 	CheckBox CB_REPLACE_BY_CHARACTER
 	{
-		Pos = MAP_APPFONT( 226, 81 );
+        Pos = MAP_APPFONT( 241, 81 );
 		Size = MAP_APPFONT( 55, 24 );
 
 		WordBreak = TRUE;

svx/source/cui/svuidlg.src

 	};
 	CancelButton 1
 	{
-		Pos = MAP_APPFONT ( 275 , 6 ) ;
-		Size = MAP_APPFONT ( 50 , 14 ) ;
+        Pos = MAP_APPFONT ( 270 , 6 ) ;
+        Size = MAP_APPFONT ( 60 , 14 ) ;
 		Text [ en-US ] = "~Close" ;
 	};
 	HelpButton 1
 	{
-		Pos = MAP_APPFONT ( 275 , 26 ) ;
-		Size = MAP_APPFONT ( 50 , 14 ) ;
+        Pos = MAP_APPFONT ( 270 , 26 ) ;
+        Size = MAP_APPFONT ( 60 , 14 ) ;
 	};
 	PushButton PB_UPDATE_NOW
 	{
-		Pos = MAP_APPFONT ( 275 , 43 ) ;
-		Size = MAP_APPFONT ( 50 , 14 ) ;
+        Pos = MAP_APPFONT ( 270 , 43 ) ;
+        Size = MAP_APPFONT ( 60 , 14 ) ;
 		Text [ en-US ] = "~Update" ;
 	};
 	PushButton PB_OPEN_SOURCE
 	{
-		Pos = MAP_APPFONT ( 275 , 60 ) ;
-		Size = MAP_APPFONT ( 50 , 14 ) ;
+        Pos = MAP_APPFONT ( 270 , 60 ) ;
+        Size = MAP_APPFONT ( 60 , 14 ) ;
 		Text [ en-US ] = "~Open" ;
 	};
 	PushButton PB_CHANGE_SOURCE
 	{
-		Pos = MAP_APPFONT ( 275 , 77 ) ;
-		Size = MAP_APPFONT ( 50 , 14 ) ;
+        Pos = MAP_APPFONT ( 270 , 77 ) ;
+        Size = MAP_APPFONT ( 60 , 14 ) ;
 		Text [ en-US ] = "~Modify..." ;
 	};
 	PushButton PB_BREAK_LINK
 	{
-		Pos = MAP_APPFONT ( 275 , 94 ) ;
-		Size = MAP_APPFONT ( 50 , 14 ) ;
+        Pos = MAP_APPFONT ( 270 , 94 ) ;
+        Size = MAP_APPFONT ( 60 , 14 ) ;
 		Text [ en-US ] = "~Break Link" ;
 	};
 	FixedText FT_FILES2

svx/source/cui/zoom.src

 	HelpId = SID_ATTR_ZOOM ;
 	OutputSize = TRUE ;
 	SvLook = TRUE ;
-    Size = MAP_APPFONT ( 218 , 112 ) ;
+    Size = MAP_APPFONT ( 242 , 112 ) ;
 	Moveable = TRUE ;
     Text [ en-US ] = "Zoom & View Layout";
     FixedLine FL_ZOOM
     {
         Pos = MAP_APPFONT ( 6 , 3 ) ;
-        Size = MAP_APPFONT ( 100 , 8 ) ;
+        Size = MAP_APPFONT ( 112 , 8 ) ;
         Text [ en-US ] = "Zoom factor";
     };
     RadioButton BTN_OPTIMAL
     {
         Pos = MAP_APPFONT ( 12 , 14 ) ;
-        Size = MAP_APPFONT ( 91 , 10 ) ;
+        Size = MAP_APPFONT ( 105 , 10 ) ;
         Text [ en-US ] = "~Optimal" ;
     };
     RadioButton BTN_WHOLE_PAGE
 	{
         Pos = MAP_APPFONT ( 12 , 27 ) ;
-        Size = MAP_APPFONT ( 91 , 10 ) ;
+        Size = MAP_APPFONT ( 105 , 10 ) ;
         Text [ en-US ] = "~Fit width and height" ;
 	};
 	RadioButton BTN_PAGE_WIDTH
 	{
         Pos = MAP_APPFONT ( 12 , 40 ) ;
-        Size = MAP_APPFONT ( 91 , 10 ) ;
+        Size = MAP_APPFONT ( 105, 10 ) ;
         Text [ en-US ] = "Fit ~width" ;
 	};
     RadioButton BTN_100
 	{
         Pos = MAP_APPFONT ( 12 , 53 ) ;
-        Size = MAP_APPFONT ( 91 , 10 ) ;
+        Size = MAP_APPFONT ( 105, 10 ) ;
         Text = "~100 %" ;
 	};
     RadioButton BTN_USER
 	{
         Pos = MAP_APPFONT ( 12 , 67 ) ;
-        Size = MAP_APPFONT ( 59 , 10 ) ;
+        Size = MAP_APPFONT ( 72 , 10 ) ;
 		Text [ en-US ] = "~Variable" ;
 	};
 	MetricField ED_USER
 	{
-        Pos = MAP_APPFONT ( 74 , 66 ) ;
+        Pos = MAP_APPFONT ( 86 , 66 ) ;
         Size = MAP_APPFONT ( 32 , 12 ) ;
 		Border = TRUE ;
 		Group = TRUE ;
 	};
     FixedLine FL_VIEWLAYOUT
     {
-        Pos = MAP_APPFONT ( 112 , 3 ) ;
-        Size = MAP_APPFONT ( 100 , 8 ) ;
+        Pos = MAP_APPFONT ( 124 , 3 ) ;
+        Size = MAP_APPFONT ( 112 , 8 ) ;
         Text [ en-US ] = "View layout";
     };
     RadioButton BTN_AUTOMATIC
     {
-        Pos = MAP_APPFONT ( 118 , 14 ) ;
-        Size = MAP_APPFONT ( 91 , 10 ) ;
+        Pos = MAP_APPFONT ( 130 , 14 ) ;
+        Size = MAP_APPFONT ( 106 , 10 ) ;
         Text [ en-US ] = "~Automatic" ;
     };
     RadioButton BTN_SINGLE
     {
-        Pos = MAP_APPFONT ( 118 , 27 ) ;
-        Size = MAP_APPFONT ( 91 , 10 ) ;
+        Pos = MAP_APPFONT ( 130, 27 ) ;
+        Size = MAP_APPFONT ( 106, 10 ) ;
         Text [ en-US ] = "~Single page" ;
     };
     RadioButton BTN_COLUMNS
     {
-        Pos = MAP_APPFONT ( 118 , 41 ) ;
-        Size = MAP_APPFONT ( 64 , 10 ) ;
+        Pos = MAP_APPFONT ( 130, 41 ) ;
+        Size = MAP_APPFONT ( 75 , 10 ) ;
         Text [ en-US ] = "~Columns" ;
     };
     MetricField ED_COLUMNS
     {
-        Pos = MAP_APPFONT ( 185 , 40 ) ;
+        Pos = MAP_APPFONT ( 209 , 40 ) ;
         Size = MAP_APPFONT ( 24 , 12 ) ;
         Border = TRUE ;
         Group = TRUE ;
     };
     CheckBox CHK_BOOK
     {
-        Pos = MAP_APPFONT ( 124 , 55 ) ;
+        Pos = MAP_APPFONT ( 136 , 55 ) ;
         Size = MAP_APPFONT ( 85 , 10 ) ;
         Text [ en-US ] = "~Book mode" ;
     };
     FixedLine FL_BOTTOM
     {
         Pos = MAP_APPFONT ( 6 , 81 ) ;
-        Size = MAP_APPFONT ( 206 , 8 ) ;
+        Size = MAP_APPFONT ( 230 , 8 ) ;
     };
 	OKButton BTN_ZOOM_OK
 	{
-        Pos = MAP_APPFONT ( 53 , 92 ) ;
+        Pos = MAP_APPFONT ( 77 , 92 ) ;
 		Size = MAP_APPFONT ( 50 , 14 ) ;
 		DefButton = TRUE ;
 	};
 	CancelButton BTN_ZOOM_CANCEL
 	{
-        Pos = MAP_APPFONT ( 106 , 92 ) ;
+        Pos = MAP_APPFONT ( 130 , 92 ) ;
 		Size = MAP_APPFONT ( 50 , 14 ) ;
 	};
 	HelpButton BTN_ZOOM_HELP
 	{
-        Pos = MAP_APPFONT ( 162 , 92 ) ;
+        Pos = MAP_APPFONT ( 186 , 92 ) ;
 		Size = MAP_APPFONT ( 50 , 14 ) ;
 	};
 };

svx/source/dialog/fntctrl.cxx

 	pImpl->pColor = new Color( rColor );
 	Invalidate();
 }
+// -----------------------------------------------------------------------
+
+void SvxFontPrevWindow::ResetColor()
+{
+    delete pImpl->pColor;
+    pImpl->pColor = 0;
+    Invalidate();
+}
 
 // -----------------------------------------------------------------------
 

svx/source/dialog/srchdlg.cxx

     aCalcStr        ( THIS_SVX_RES( STR_WORDCALC ) ),                       \
     pImpl           ( NULL ),                                               \
 	pSearchList 	( NULL ),												\
-	pReplaceList	( NULL ),												\
+	pReplaceList	( new SearchAttrItemList ),                             \
 	pSearchItem 	( NULL ),												\
 	pSearchController		( NULL ),										\
 	pOptionsController		( NULL ),										\

svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.src

 
 #define FULL_WIDTH (220)
 #define FULL_HEIGHT (120)
-#define EDITBUTTON_WIDTH (70)
+#define EDITBUTTON_WIDTH (75)
 
 #define COL_1 (RSC_SP_DLG_INNERBORDER_LEFT)
 #define COL_2 (COL_1+RSC_SP_FLGR_SPACE_X)
 
 class Graphic;
 //implemented in source/ui/docvw/romenu.cxx
-String ExportGraphic( const Graphic &rGraphic, const String &rGrfName, const String &rName );
+String ExportGraphic( const Graphic &rGraphic, const String &rGrfName );
 
 #endif

sw/qa/unoapi/sw.sce

 #i85640 -o sw.SwXMailMerge
 -o sw.SwXModule
 -o sw.SwXNumberingRules
--o sw.SwXParagraph
+#i103696 -o sw.SwXParagraph
 -o sw.SwXParagraphEnumeration
 -o sw.SwXPrintSettings
 -o sw.SwXPropertySet
 -o sw.SwXTextFrameText
 -o sw.SwXTextGraphicObject
 -o sw.SwXTextGraphicObjects
--o sw.SwXTextPortion
+#i103696 -o sw.SwXTextPortion
 -o sw.SwXTextPortionEnumeration
 -o sw.SwXTextRange
 -o sw.SwXTextRanges

sw/source/core/crsr/findtxt.cxx

 				p->MoveTo( (Ring*)pRegion );
 			} while( p != pPrev );
 		}
-		rSttCntIdx = nSttCnt;
+		pCrsr->Start()->nContent = nSttCnt;
 		return FIND_NO_RING;
 	}
 	return bFnd ? FIND_FOUND : FIND_NOT_FOUND;

sw/source/core/doc/doc.cxx

                         sText.Erase();
 
                     //now remove the field and insert the string
-                    SwPaM aPam(*pTxtFld->GetpTxtNode(), *pTxtFld->GetStart());
-                    aPam.SetMark();
-                    aPam.Move();
-                    DeleteAndJoin(aPam);
-                    Insert( aPam, sText, true );
+                    SwPaM aPam1(*pTxtFld->GetpTxtNode(), *pTxtFld->GetStart());
+                    aPam1.Move();
+                    Insert( aPam1, sText, true );//insert first to keep the field's attributes
+                    SwPaM aPam2(*pTxtFld->GetpTxtNode(), *pTxtFld->GetStart());
+                    aPam2.SetMark();
+                    aPam2.Move();
+                    DeleteAndJoin(aPam2);//remove the field 
                 }
             }
             ++aBegin;

sw/source/core/unocore/unobkm.cxx

     static uno::Reference< beans::XPropertySetInfo >  aRef;
     if(!aRef.is())
     {
-        uno::Reference< beans::XPropertySetInfo >  xInfo = aSwMapProvider.GetPropertySet(PROPERTY_MAP_BOOKMARK)->getPropertySetInfo();
+        aRef = aSwMapProvider.GetPropertySet(PROPERTY_MAP_BOOKMARK)->getPropertySetInfo();
     }
     return aRef;
 }

sw/source/core/unocore/unocoll.cxx

 	throw(IndexOutOfBoundsException, WrappedTargetException, uno::RuntimeException )
 {
 	vos::OGuard aGuard(Application::GetSolarMutex());
-	if(!IsValid()) throw uno::RuntimeException();
+	if(!IsValid()) 
+		throw uno::RuntimeException();
     if(nIndex < 0 || nIndex >= USHRT_MAX) throw IndexOutOfBoundsException();
     const Reference<XEnumeration> xEnum = createEnumeration();
     while(xEnum->hasMoreElements())
 	throw(NoSuchElementException, WrappedTargetException, uno::RuntimeException )
 {
 	vos::OGuard aGuard(Application::GetSolarMutex());
-    if(!IsValid()) throw uno::RuntimeException();
+    if(!IsValid()) 
+	    throw uno::RuntimeException();
     const Reference<XEnumeration> xEnum = createEnumeration();
     while(xEnum->hasMoreElements())
     {
 uno::Sequence<OUString> SwXFrames::getElementNames(void) throw( uno::RuntimeException )
 {
 	vos::OGuard aGuard(Application::GetSolarMutex());
-	if(!IsValid()) throw uno::RuntimeException();
+	if(!IsValid()) 
+		throw uno::RuntimeException();
     const Reference<XEnumeration> xEnum = createEnumeration();
     ::std::vector<OUString> vNames;
     while(xEnum->hasMoreElements())
 sal_Bool SwXFrames::hasElements(void) throw(uno::RuntimeException)
 {
 	vos::OGuard aGuard(Application::GetSolarMutex());
-	if(IsValid()) throw uno::RuntimeException();
+	if(!IsValid()) 
+		throw uno::RuntimeException();
     return createEnumeration()->hasMoreElements();
 }
 

sw/source/core/unocore/unotext.cxx

 				xTempRange = xRange;
 			else
 				xTempRange = xRange->getStart();
-			SwXTextTable* pTable = reinterpret_cast< SwXTextTable * >(
-					sal::static_int_cast< sal_IntPtr >( xContentTunnel->getSomething( SwXTextTable::getUnoTunnelId()) ));
-
-			if(pTable)
-				pTable->attachToRange(xTempRange);
-			else
-			{
-				if(pBookmark)
-					pBookmark ->attachToRange(xTempRange);
-				else
-				{
-					if(pSection)
-						pSection ->attachToRange(xTempRange);
-					else
-					{
-						SwXFootnote* pFootnote = reinterpret_cast< SwXFootnote * >(
-								sal::static_int_cast< sal_IntPtr >( xContentTunnel->getSomething( SwXFootnote::getUnoTunnelId()) ));
-
-						if(pFootnote)
-							pFootnote->attachToRange(xTempRange);
-						else
-						{
-							if(pReferenceMark)
-								pReferenceMark->attachToRange(xTempRange);
-							else
-							{
-								SwXFrame* pFrame = reinterpret_cast< SwXFrame * >(
-										sal::static_int_cast< sal_IntPtr >( xContentTunnel->getSomething( SwXFrame::getUnoTunnelId()) ));
-
-								if(pFrame)
-									pFrame->attachToRange(xTempRange);
-								else
-								{
-									SwXDocumentIndex* pDocumentIndex = reinterpret_cast< SwXDocumentIndex * >(
-											sal::static_int_cast< sal_IntPtr >( xContentTunnel->getSomething( SwXDocumentIndex::getUnoTunnelId()) ));
-
-									if(pDocumentIndex)
-										pDocumentIndex->attachToRange(xTempRange);
-									else
-									{
-										if(pDocumentIndexMark)
-											pDocumentIndexMark->attachToRange(xTempRange);
-										else
-										{
-											SwXTextField* pTextField = reinterpret_cast< SwXTextField * >(
-													sal::static_int_cast< sal_IntPtr >( xContentTunnel->getSomething( SwXTextField::getUnoTunnelId()) ));
-
-											if(pTextField)
-												pTextField->attachToRange(xTempRange);
-											else
-											{
-												uno::Reference<beans::XPropertySet> xShapeProperties(xContent, uno::UNO_QUERY);
-												SwXShape* pShape = 0;
-												if(xShapeProperties.is())
-													pShape = reinterpret_cast< SwXShape * >(
-															sal::static_int_cast< sal_IntPtr >( xContentTunnel->getSomething( SwXShape::getUnoTunnelId()) ));
-												if(pShape)
-												{
-													uno::Any aPos(&xRange,
-														::getCppuType((uno::Reference<text::XTextRange>*)0));
-													pShape->setPropertyValue(C2U("TextRange"), aPos);
-
-													uno::Reference<frame::XModel> xModel =
-																	pDoc->GetDocShell()->GetBaseModel();
-													uno::Reference<drawing::XDrawPageSupplier> xPageSupp(
-																xModel, uno::UNO_QUERY);
-
-													uno::Reference<drawing::XDrawPage> xPage = xPageSupp->getDrawPage();
-
-													uno::Reference<drawing::XShape> xShape((cppu::OWeakObject*)pShape,
-																											uno::UNO_QUERY);
-													//nuer die XShapes haengen an der Sw-Drawpage
-													uno::Reference<drawing::XShapes> xShps(xPage, uno::UNO_QUERY);
-													xShps->add(xShape);
-												}
-												else
-												{
-													lang::IllegalArgumentException aArgException;
-													aArgException.Message = C2U("unknown text content");
-													throw aArgException;
-												}
-											}
-										}
-									}
-								}
-							}
-						}
-					}
-				}
-			}
+            xContent->attach(xTempRange);
 		}
 		else
 		{

sw/source/ui/app/docsh2.cxx

 						if(!pBool || !pBool->GetValue())
                             break;
 					}
-					else
-                    {
-                        // try to store the document
-                        sal_uInt32 nErrorCode = ERRCODE_NONE;
-                        try
-                        {
-                            uno::Reference< frame::XStorable > xStorable( GetModel(), uno::UNO_QUERY_THROW );
-                            xStorable->store();
-                        }
-                        catch( task::ErrorCodeIOException& aErrEx )
-                        {
-                            nErrorCode = (sal_uInt32)aErrEx.ErrCode;
-                        }
-                        catch( uno::Exception& )
-                        {
-                            nErrorCode = ERRCODE_IO_GENERAL;
-                        }
-
-                        if ( nErrorCode != ERRCODE_NONE )
-                        {
-                            // if the saving has failed show the error and break the action
-                            if ( nErrorCode != ERRCODE_ABORT )
-                                ErrorHandler::HandleError( nErrorCode );
-
-                            break;
-                        }
-                    }
 				}
 #ifdef DBG_UTIL
 				{

sw/source/ui/config/optdlg.src

     CheckBox CB_CROSS
 	{
         Pos = MAP_APPFONT ( 12 , 14 ) ;
-		Size = MAP_APPFONT ( 108 , 10 ) ;
+        Size = MAP_APPFONT ( 118 , 10 ) ;
     	Text [ en-US ] = "Guides ~while moving";
 	};
 	CheckBox CB_HANDLE
 	{
         Pos = MAP_APPFONT ( 12 , 27 ) ;
-		Size = MAP_APPFONT ( 108 , 10 ) ;
+        Size = MAP_APPFONT ( 118 , 10 ) ;
     	Text [ en-US ] = "Sim~ple handles";
 	};
 	CheckBox CB_BIGHANDLE
 	{
         Pos = MAP_APPFONT ( 12 , 40 ) ;
-		Size = MAP_APPFONT ( 108 , 10 ) ;
+        Size = MAP_APPFONT ( 118 , 10 ) ;
     	Text [ en-US ] = "Large handles";
 	};
     FixedLine FL_WINDOW
     CheckBox CB_HRULER
 	{
         Pos = MAP_APPFONT ( 142 , 53 ) ;
-        Size = MAP_APPFONT ( 61 , 10 ) ;
+        Size = MAP_APPFONT ( 62 , 10 ) ;
 		Text [ en-US ] = "Hori~zontal ruler" ;
 	};
     ListBox LB_HMETRIC
     CheckBox CB_VRULER
 	{
         Pos = MAP_APPFONT ( 142 , 66 ) ;
-        Size = MAP_APPFONT ( 61 , 10 ) ;
+        Size = MAP_APPFONT ( 62 , 10 ) ;
 		Text [ en-US ] = "Verti~cal ruler" ;
 	};
     CheckBox CB_VRULER_RIGHT

sw/source/ui/config/optpage.cxx

 };
 
 // Editieren entspricht Einfuegen-Attributen
-static CharAttr __FAR_DATA aInsertAttr[] =
+static CharAttr __FAR_DATA aRedlineAttr[] =
 {
 	{ SID_ATTR_CHAR_CASEMAP,		SVX_CASEMAP_NOT_MAPPED },
 	{ SID_ATTR_CHAR_WEIGHT,			WEIGHT_BOLD },
 	{ SID_ATTR_CHAR_CASEMAP,      	SVX_CASEMAP_TITEL },
 	{ SID_ATTR_BRUSH,				0 }
 };
+// Items from aRedlineAttr relevant for InsertAttr: strikethrough is
+// not used
+static USHORT aInsertAttrMap[] = { 0, 1, 2, 3, 4, 6, 7, 8, 9, 10 };
 
+// Items from aRedlineAttr relevant for DeleteAttr: underline and
+// double underline is not used
+static USHORT aDeletedAttrMap[] = { 0, 1, 2, 5, 6, 7, 8, 9, 10 };
+
+// Items from aRedlineAttr relevant for ChangeAttr: strikethrough is
+// not used
+static USHORT aChangedAttrMap[] = { 0, 1, 2, 3, 4, 6, 7, 8, 9, 10 };
 
 /*-----------------------------------------------------------------------
 	Beschreibung: Markierungsvorschau
 	Window::DrawRect(rRect);
 }
 
+namespace
+{
+    void lcl_FillRedlineAttrListBox(
+            ListBox& rLB, const AuthorCharAttr& rAttrToSelect,
+            const USHORT* pAttrMap, const USHORT nAttrMapSize)
+    {
+        for (USHORT i = 0; i != nAttrMapSize; ++i)
+        {
+            CharAttr& rAttr(aRedlineAttr[pAttrMap[i]]);
+            rLB.SetEntryData(i, &rAttr);
+            if (rAttr.nItemId == rAttrToSelect.nItemId &&
+                rAttr.nAttr == rAttrToSelect.nAttr)
+                rLB.SelectEntryPos(i);
+        }
+    }
+}
+
 SwRedlineOptionsTabPage::SwRedlineOptionsTabPage( Window* pParent,
 													const SfxItemSet& rSet )
 	: SfxTabPage(pParent, SW_RES(TP_REDLINE_OPT), rSet),
         aChangedLB.InsertEntry(sEntry);
     };
 
+    // remove strikethrough from insert and change and underline + double
+    // underline from delete
+    aInsertLB.RemoveEntry(5);
+    aChangedLB.RemoveEntry(5);
+    aDeletedLB.RemoveEntry(4);
+    aDeletedLB.RemoveEntry(3);
+    
     Link aLk = LINK(this, SwRedlineOptionsTabPage, AttribHdl);
 	aInsertLB.SetSelectHdl( aLk );
 	aDeletedLB.SetSelectHdl( aLk );
 
 	aMarkColorLB.SelectEntry(pOpt->GetMarkAlignColor());
 
-	// Attributlistboxen initialisieren
-	USHORT nNum = sizeof(aInsertAttr) / sizeof(CharAttr);
-
 	aInsertLB.SelectEntryPos(0);
 	aDeletedLB.SelectEntryPos(0);
 	aChangedLB.SelectEntryPos(0);
-	for (i = 0; i < nNum; i++)
-	{
-		aInsertLB.SetEntryData(i, &aInsertAttr[i]);
-		if (aInsertAttr[i].nItemId == rInsertAttr.nItemId &&
-			aInsertAttr[i].nAttr == rInsertAttr.nAttr)
-			aInsertLB.SelectEntryPos(i);
-	}
-
-	for (i = 0; i < nNum; i++)
-	{
-        aDeletedLB.SetEntryData(i, &aInsertAttr[i]);
-        if (aInsertAttr[i].nItemId == rDeletedAttr.nItemId &&
-            aInsertAttr[i].nAttr == rDeletedAttr.nAttr)
-			aDeletedLB.SelectEntryPos(i);
-	}
-
-	for (i = 0; i < nNum; i++)
-	{
-        aChangedLB.SetEntryData(i, &aInsertAttr[i]);
-        if (aInsertAttr[i].nItemId == rChangedAttr.nItemId &&
-            aInsertAttr[i].nAttr == rChangedAttr.nAttr)
-			aChangedLB.SelectEntryPos(i);
-	}
-    //remove strikethrough from insert and delete and underline+double underline from delete
-    aInsertLB.RemoveEntry(5);
-    aChangedLB.RemoveEntry(5);
-    aDeletedLB.RemoveEntry(4);
-    aDeletedLB.RemoveEntry(3);
-
-
+    
+    lcl_FillRedlineAttrListBox(aInsertLB, rInsertAttr, aInsertAttrMap,
+            sizeof(aInsertAttrMap) / sizeof(USHORT));
+    lcl_FillRedlineAttrListBox(aDeletedLB, rDeletedAttr, aDeletedAttrMap,
+            sizeof(aDeletedAttrMap) / sizeof(USHORT));
+    lcl_FillRedlineAttrListBox(aChangedLB, rChangedAttr, aChangedAttrMap,
+            sizeof(aChangedAttrMap) / sizeof(USHORT));
+    
 	USHORT nPos = 0;
 	switch (pOpt->GetMarkAlignMode())
 	{
 		nPos = 0;
 
 	CharAttr*	pAttr = ( CharAttr* ) pLB->GetEntryData( nPos );
-
+    //switch off preview background color
+    pPrev->ResetColor();
 	switch (pAttr->nItemId)
 	{
 		case SID_ATTR_CHAR_WEIGHT:

sw/source/ui/dbui/dbmgr.cxx

         uno::Reference< XConnection> xConnection;
         sal_Bool bUseMergeData = sal_False;
         uno::Reference< XColumnsSupplier> xColsSupp;
+        bool bDisposeConnection = false;
         if(pImpl->pMergeData &&
             pImpl->pMergeData->sDataSource.equals(rDBName) && pImpl->pMergeData->sCommand.equals(rTableName))
 		{
             {
                 rtl::OUString sDBName(rDBName);
                 xConnection = RegisterConnection( sDBName );
+                bDisposeConnection = true;
             }
             if(bUseMergeData)
                 pImpl->pMergeData->xConnection = xConnection;
             {
                 ::comphelper::disposeComponent( xColsSupp );
             }
+            if(bDisposeConnection)
+            {
+                ::comphelper::disposeComponent( xConnection );
+            }
         }
         else
 			nRet = pNFmtr->GetFormatIndex( NF_NUMBER_STANDARD, LANGUAGE_SYSTEM );

sw/source/ui/docvw/romenu.cxx

 
 
 #include <tools/urlobj.hxx>
-#ifndef _GRAPH_HXX //autogen
 #include <vcl/graph.hxx>
-#endif
-#ifndef _MSGBOX_HXX //autogen
 #include <vcl/msgbox.hxx>
-#endif
 #include <sot/formats.hxx>
 #include <svtools/eitem.hxx>
 #include <svtools/stritem.hxx>
 #include <fmturl.hxx>
 #include <fmtinfmt.hxx>
 #include <docsh.hxx>
-#ifndef _VIEW_HXX
 #include <view.hxx>
-#endif
 #include <wrtsh.hxx>
 #include <viewopt.hxx>
 #include <swmodule.hxx>
 #include <romenu.hxx>
 #include <pagedesc.hxx>
-#ifndef _MODCFG_HXX
 #include <modcfg.hxx>
-#endif
 
-#ifndef _CMDID_H
 #include <cmdid.h>
-#endif
-#ifndef _HELPID_H
 #include <helpid.h>
-#endif
-#ifndef _DOCVW_HRC
 #include <docvw.hrc>
-#endif
-#ifndef _DOCVW_HRC
 #include <docvw.hrc>
-#endif
 #include <com/sun/star/ui/dialogs/XFilePicker.hpp>
 #include <com/sun/star/ui/dialogs/XFilterManager.hpp>
 #include <com/sun/star/ui/dialogs/TemplateDescription.hpp>
 
 using namespace ::com::sun::star::lang;
 using namespace ::com::sun::star::uno;
+using namespace ::com::sun::star;
 using namespace ::com::sun::star::ui::dialogs;
 using namespace ::sfx2;
 
 
 String SwReadOnlyPopup::SaveGraphic( USHORT nId )
 {
-/*	SvtPathOptions aPathOpt;
-	String sGrfPath( aPathOpt.GetGraphicPath() );
-
-    FileDialogHelper aDlgHelper( TemplateDescription::FILESAVE_SIMPLE, 0 );
-    Reference < XFilePicker > xFP = aDlgHelper.GetFilePicker();
-
-//    aExpDlg.SetHelpId(HID_FILEDLG_ROMENU);
-	INetURLObject aPath;
-	aPath.SetSmartURL( sGrfPath);*/
 
 	//Namen der Grafik herausfischen.
 	String aName;
 	if ( MN_READONLY_SAVEBACKGROUND == nId )
 	{
 		if ( pItem->GetGraphicLink() )
-			aName = *pItem->GetGraphicLink();
+            sGrfName = *pItem->GetGraphicLink();
 		((SvxBrushItem*)pItem)->SetDoneLink( Link() );
 		const Graphic *pGrf = pItem->GetGraphic( rView.GetDocShell() );
 		if ( pGrf )
 		else
 			return aEmptyStr;
 	}
-	else
-		aName = sGrfName;
-	return ExportGraphic( aGraphic, sGrfName, aName );
+    return ExportGraphic( aGraphic, sGrfName );
 }
 
-String ExportGraphic( const Graphic &rGraphic, const String &rGrfName, const String &rName )
+String ExportGraphic( const Graphic &rGraphic, const String &rGrfName )
 {
 	SvtPathOptions aPathOpt;
 	String sGrfPath( aPathOpt.GetGraphicPath() );
 
 //    aExpDlg.SetHelpId(HID_FILEDLG_ROMENU);
 	INetURLObject aPath;
-	aPath.SetSmartURL( rName );
+	aPath.SetSmartURL( sGrfPath );
 
 	//Namen der Grafik herausfischen.
 	String aName = rGrfName;
 
-	INetURLObject aURL;
-	aURL.SetSmartURL( aName );
-	aPath.Append( aURL.GetName() );
-    xFP->setDisplayDirectory( aPath.GetMainURL(INetURLObject::DECODE_TO_IURI) );
-    xFP->setTitle( SW_RESSTR(STR_EXPORT_GRAFIK_TITLE));
+	aDlgHelper.SetTitle( SW_RESSTR(STR_EXPORT_GRAFIK_TITLE));
+	aDlgHelper.SetDisplayDirectory( aPath.GetMainURL(INetURLObject::DECODE_TO_IURI) );
+    INetURLObject aURL;
+    aURL.SetSmartURL( aName );
+    aDlgHelper.SetFileName( aURL.GetName() );
 
 	GraphicFilter& rGF = *GetGrfFilter();
 	const USHORT nCount = rGF.GetExportFormatCount();

sw/source/ui/frmdlg/column.cxx

     //#i80458# if no columns can be set then disable OK
     if( !aApplyToLB.GetEntryCount() )
         aOK.Enable( sal_False );
+    //#i97810# set focus to the TabPage
+    pTabPage->ActivateColumnControl();
 }
 
 /*--------------------------------------------------------------------

sw/source/ui/inc/column.hxx

 	void ShowBalance(BOOL bShow) {aBalanceColsCB.Show(bShow);}
     void SetInSection(BOOL bSet);
 
+    void ActivateColumnControl() {aCLNrEdt.GrabFocus();}
 };
 
 #endif

sw/source/ui/inc/wrtsh.hxx

 	void	SetInsMode( BOOL bOn = TRUE );
 	void	ToggleInsMode() { SetInsMode( !bIns ); }
 	BOOL	IsInsMode() const { return bIns; }
+    void    SetRedlineModeAndCheckInsMode( USHORT eMode );
 
 	void	EnterSelFrmMode(const Point *pStartDrag = 0);
 	void	LeaveSelFrmMode();

sw/source/ui/index/cnttab.src

 	CheckBox	CB_FROMFILE
 	{
         Pos = MAP_APPFONT ( 136 , 124 ) ;
-        Size = MAP_APPFONT ( 63 , 10 ) ;
+        Size = MAP_APPFONT ( 115 , 10 ) ;
 		Text [ en-US ] = "~Concordance file";
 	};
 	MenuButton 	MB_AUTOMARK
 	{
-        Pos = MAP_APPFONT ( 201 , 122 ) ;
+        Pos = MAP_APPFONT ( 136 , 137 ) ;
 		Size = MAP_APPFONT ( 50 , 14 ) ;
 		TabStop = TRUE ;
 		ButtonMenu = Menu
 	};
     FixedLine FL_SORTOPTIONS
     {
-        Pos = MAP_APPFONT ( 6, 150) ;
+        Pos = MAP_APPFONT ( 6, 153) ;
         Size = MAP_APPFONT ( 248, 8 ) ;
     	Text [ en-US ] = "Sort";
 	};
     FixedText FT_LANGUAGE
     {
-        Pos = MAP_APPFONT ( 12, 163) ;
+        Pos = MAP_APPFONT ( 12, 166) ;
         Size = MAP_APPFONT ( 33, 8 ) ;
     	Text [ en-US ] = "Language";
 	};
     ListBox LB_LANGUAGE
     {
-        Pos = MAP_APPFONT ( 47, 161) ;
+        Pos = MAP_APPFONT ( 47, 164) ;
         Size = MAP_APPFONT ( 80, 50 ) ;
 		Border = TRUE;
 		DropDown = TRUE;
     };
     FixedText FT_SORTALG
     {
-        Pos = MAP_APPFONT ( 130, 163) ;
+        Pos = MAP_APPFONT ( 130, 166) ;
         Size = MAP_APPFONT ( 50, 8 ) ;
     	Text [ en-US ] = "Key type";
 	};
     ListBox LB_SORTALG
     {
-        Pos = MAP_APPFONT ( 201, 161) ;
+        Pos = MAP_APPFONT ( 201, 164) ;
         Size = MAP_APPFONT ( 50, 50 ) ;
 		Border = TRUE;
 		DropDown = TRUE;
 	FixedText FT_LEVEL
 	{
 		Pos = MAP_APPFONT ( 11 , 14 ) ;
-		Size = MAP_APPFONT ( 24 , 8 ) ;
+        Size = MAP_APPFONT ( 102 , 8 ) ;
 		Text [ en-US ] = "~Levels" ;
 		Left = TRUE ;
 	};
 	FixedText FT_TEMPLATE
 	{
         Pos = MAP_APPFONT ( 142 , 14 ) ;
-		Size = MAP_APPFONT ( 54 , 8 ) ;
+        Size = MAP_APPFONT ( 102 , 8 ) ;
 		Text [ en-US ] = "Paragraph ~Styles" ;
 		Left = TRUE ;
 	};

sw/source/ui/misc/pggrid.cxx

             default:                pButton = &aCharsGridRB;
         }
         pButton->Check();
+        aDisplayCB.Check(rGridItem.IsDisplayGrid());
         GridTypeHdl(pButton);
         aSnapToCharsCB.Check(rGridItem.IsSnapToChars());
         aLinesPerPageNF.SetValue(rGridItem.GetLines());
         aRubySizeMF.SetValue(aRubySizeMF.Normalize(rGridItem.GetRubyHeight()), FUNIT_TWIP);
         aCharWidthMF.SetValue(aCharWidthMF.Normalize(rGridItem.GetBaseWidth()), FUNIT_TWIP);
         aRubyBelowCB.Check(rGridItem.IsRubyTextBelow());
-        aDisplayCB.Check(rGridItem.IsDisplayGrid());
         aPrintCB.Check(rGridItem.IsPrintGrid());
         aColorLB.SelectEntry(rGridItem.GetColor());
     }

sw/source/ui/shells/grfsh.cxx

             {
 			    String sGrfNm, sFilterNm;
 			    rSh.GetGrfNms( &sGrfNm, &sFilterNm );
-                ExportGraphic( *pGraphic, sGrfNm, sGrfNm );
+                ExportGraphic( *pGraphic, sGrfNm );
             }
         }
         break;

sw/source/ui/table/colwd.src

 	HelpID = FN_TABLE_SET_COL_WIDTH ;
 	OutputSize = TRUE ;
 	SVLook = TRUE ;
-	Size = MAP_APPFONT ( 149 , 60 ) ;
+    Size = MAP_APPFONT ( 159 , 60 ) ;
 	Text [ en-US ] = "Column Width" ;
 	Moveable = TRUE ;
 	OKButton BT_OK
 	{
-		Pos = MAP_APPFONT ( 94 , 6 ) ;
+        Pos = MAP_APPFONT ( 104 , 6 ) ;
 		Size = MAP_APPFONT ( 50 , 14 ) ;
 		TabStop = TRUE ;
 		DefButton = TRUE ;
 	};
 	CancelButton BT_CANCEL
 	{
-		Pos = MAP_APPFONT ( 94 , 23 ) ;
+        Pos = MAP_APPFONT ( 104 , 23 ) ;
 		Size = MAP_APPFONT ( 50 , 14 ) ;
 		TabStop = TRUE ;
 	};
 	HelpButton BT_HELP
 	{
-		Pos = MAP_APPFONT ( 94 , 43 ) ;
+        Pos = MAP_APPFONT ( 104 , 43 ) ;
 		Size = MAP_APPFONT ( 50 , 14 ) ;
 		TabStop = TRUE ;
 	};
 	FixedText FT_WIDTH
 	{
 		Pos = MAP_APPFONT ( 12 , 31 ) ;
-		Size = MAP_APPFONT ( 22 , 8 ) ;
+        Size = MAP_APPFONT ( 35 , 8 ) ;
 		Text [ en-US ] = "~Width" ;
 		Left = TRUE ;
 	};
 	MetricField ED_WIDTH
 	{
 		Border = TRUE ;
-		Pos = MAP_APPFONT ( 41 , 30 ) ;
+        Pos = MAP_APPFONT ( 51 , 30 ) ;
 		Size = MAP_APPFONT ( 38 , 12 ) ;
 		TabStop = TRUE ;
 		Left = TRUE ;
     FixedLine FL_WIDTH
 	{
 		Pos = MAP_APPFONT ( 6 , 3 ) ;
-        Size = MAP_APPFONT ( 81 , 8 ) ;
+        Size = MAP_APPFONT ( 91 , 8 ) ;
 		Text [ en-US ] = "Width" ;
 	};
 	FixedText FT_COL
 	{
 		Pos = MAP_APPFONT ( 12 , 16 ) ;
-		Size = MAP_APPFONT ( 29 , 8 ) ;
+        Size = MAP_APPFONT ( 35 , 8 ) ;
 		Text [ en-US ] = "~Column" ;
 		Left = TRUE ;
 	};
 	NumericField ED_COL
 	{
 		Border = TRUE ;
-		Pos = MAP_APPFONT ( 41 , 14 ) ;
+        Pos = MAP_APPFONT ( 51 , 14 ) ;
 		Size = MAP_APPFONT ( 38 , 12 ) ;
 		TabStop = TRUE ;
 		Left = TRUE ;

sw/source/ui/uiview/view2.cxx

 
 				USHORT nOn = ((const SfxBoolItem*)pItem)->GetValue() ? nsRedlineMode_t::REDLINE_ON : 0;
 				USHORT nMode = pWrtShell->GetRedlineMode();
-				pWrtShell->SetRedlineMode( (nMode & ~nsRedlineMode_t::REDLINE_ON) | nOn);
+                pWrtShell->SetRedlineModeAndCheckInsMode( (nMode & ~nsRedlineMode_t::REDLINE_ON) | nOn);
 			}
 		}
 		break;
                     nOn = 0;
                 }
                 USHORT nMode = pIDRA->GetRedlineMode();
-				pWrtShell->SetRedlineMode( (nMode & ~nsRedlineMode_t::REDLINE_ON) | nOn);
+                pWrtShell->SetRedlineModeAndCheckInsMode( (nMode & ~nsRedlineMode_t::REDLINE_ON) | nOn);
                 rReq.AppendItem( SfxBoolItem( FN_REDLINE_PROTECT, ((nMode&nsRedlineMode_t::REDLINE_ON)==0) ) );
             }
             else
 				if( ((const SfxBoolItem*)pItem)->GetValue() )
 					nMode |= nsRedlineMode_t::REDLINE_SHOW_DELETE;
 
-				pWrtShell->SetRedlineMode( nMode );
+                pWrtShell->SetRedlineModeAndCheckInsMode( nMode );
 			}
 			break;
         case FN_MAILMERGE_SENDMAIL_CHILDWINDOW:

sw/source/ui/uiview/viewsrch.cxx

 	{
 		if (GetPostItMgr()->GetActivePostIt())
 			GetPostItMgr()->Replace(pSrchItem);
-		pWrtShell->SwEditShell::Replace( pSrchItem->GetReplaceString(),
+		sal_Bool bReplaced = pWrtShell->SwEditShell::Replace( pSrchItem->GetReplaceString(),
 											pSrchItem->GetRegExp());
 
-		if( pReplList && pReplList->Count() && pWrtShell->HasSelection() )
+		if( bReplaced && pReplList && pReplList->Count() && pWrtShell->HasSelection() )
 		{
 			SfxItemSet aReplSet( pWrtShell->GetAttrPool(),
 									aTxtFmtCollSetRange );

sw/source/ui/wrtsh/select.cxx

 	StartAction();
 	EndAction();
 }
+//Overwrite mode is incompatible with red-lining
+void SwWrtShell::SetRedlineModeAndCheckInsMode( USHORT eMode )
+{
+   SetRedlineMode( eMode );
+   if (IsRedlineOn())
+       SetInsMode( true );
+}
 
 /*
  * Rahmen bearbeiten