[Libreoffice-commits] core.git: 3 commits - sw/inc sw/qa sw/source

Noel Grandin noel at peralex.com
Thu Sep 8 07:24:15 UTC 2016


 sw/inc/IDocumentContentOperations.hxx                   |    2 
 sw/inc/IDocumentFieldsAccess.hxx                        |    2 
 sw/inc/IDocumentRedlineAccess.hxx                       |   48 +++--
 sw/inc/SwAppletImpl.hxx                                 |    2 
 sw/inc/SwUndoField.hxx                                  |    3 
 sw/inc/editsh.hxx                                       |    6 
 sw/inc/fesh.hxx                                         |    1 
 sw/inc/ftninfo.hxx                                      |    2 
 sw/inc/grfatr.hxx                                       |    4 
 sw/inc/ndgrf.hxx                                        |    3 
 sw/inc/postithelper.hxx                                 |    2 
 sw/inc/redline.hxx                                      |    5 
 sw/inc/splargs.hxx                                      |    7 
 sw/inc/swabstdlg.hxx                                    |   18 --
 sw/inc/swcrsr.hxx                                       |    2 
 sw/inc/swtable.hxx                                      |    3 
 sw/inc/txatritr.hxx                                     |    5 
 sw/inc/undobj.hxx                                       |    7 
 sw/inc/unocrsr.hxx                                      |    2 
 sw/inc/unosett.hxx                                      |    2 
 sw/inc/view.hxx                                         |    3 
 sw/inc/wdocsh.hxx                                       |    2 
 sw/qa/core/uwriter.cxx                                  |   34 ++--
 sw/qa/extras/globalfilter/globalfilter.cxx              |   18 +-
 sw/qa/extras/uiwriter/uiwriter.cxx                      |    8 
 sw/source/core/access/parachangetrackinginfo.cxx        |    2 
 sw/source/core/crsr/crstrvl.cxx                         |    2 
 sw/source/core/crsr/swcrsr.cxx                          |    6 
 sw/source/core/doc/DocumentContentOperationsManager.cxx |   70 ++++----
 sw/source/core/doc/DocumentFieldsManager.cxx            |   10 -
 sw/source/core/doc/DocumentRedlineManager.cxx           |  129 +++++++---------
 sw/source/core/doc/DocumentTimerManager.cxx             |    2 
 sw/source/core/doc/acmplwrd.cxx                         |    8 
 sw/source/core/doc/doc.cxx                              |    6 
 sw/source/core/doc/doccomp.cxx                          |   44 ++---
 sw/source/core/doc/docfld.cxx                           |   39 +---
 sw/source/core/doc/docfmt.cxx                           |    6 
 sw/source/core/doc/docftn.cxx                           |    8 
 sw/source/core/doc/docglbl.cxx                          |    2 
 sw/source/core/doc/docnum.cxx                           |    8 
 sw/source/core/doc/docredln.cxx                         |   43 ++---
 sw/source/core/doc/docsort.cxx                          |    2 
 sw/source/core/doc/doctxm.cxx                           |    2 
 sw/source/core/doc/notxtfrm.cxx                         |    2 
 sw/source/core/doc/tblrwcl.cxx                          |    4 
 sw/source/core/docnode/ndsect.cxx                       |    6 
 sw/source/core/docnode/ndtbl.cxx                        |   20 +-
 sw/source/core/docnode/node2lay.cxx                     |    5 
 sw/source/core/docnode/section.cxx                      |   16 -
 sw/source/core/edit/autofmt.cxx                         |   14 -
 sw/source/core/edit/edglss.cxx                          |    4 
 sw/source/core/edit/edlingu.cxx                         |    2 
 sw/source/core/edit/edredln.cxx                         |   14 -
 sw/source/core/edit/edundo.cxx                          |    8 
 sw/source/core/fields/postithelper.cxx                  |    5 
 sw/source/core/frmedt/fecopy.cxx                        |   10 -
 sw/source/core/frmedt/fefly1.cxx                        |    3 
 sw/source/core/inc/DocumentContentOperationsManager.hxx |    2 
 sw/source/core/inc/DocumentFieldsManager.hxx            |    2 
 sw/source/core/inc/DocumentRedlineManager.hxx           |   10 -
 sw/source/core/inc/attrhint.hxx                         |    8 
 sw/source/core/inc/docfld.hxx                           |    9 -
 sw/source/core/inc/node2lay.hxx                         |    2 
 sw/source/core/layout/newfrm.cxx                        |    2 
 sw/source/core/table/swtable.cxx                        |    4 
 sw/source/core/text/atrhndl.hxx                         |    3 
 sw/source/core/text/atrstck.cxx                         |    5 
 sw/source/core/text/frmpaint.cxx                        |    6 
 sw/source/core/text/inftxt.cxx                          |   10 -
 sw/source/core/text/inftxt.hxx                          |    8 
 sw/source/core/text/itradj.cxx                          |    2 
 sw/source/core/text/porglue.cxx                         |    4 
 sw/source/core/text/porglue.hxx                         |    2 
 sw/source/core/text/porlay.cxx                          |    4 
 sw/source/core/text/pormulti.cxx                        |    4 
 sw/source/core/text/porrst.cxx                          |    4 
 sw/source/core/text/redlnitr.cxx                        |    2 
 sw/source/core/text/txtpaint.cxx                        |    2 
 sw/source/core/text/txtpaint.hxx                        |    8 
 sw/source/core/txtnode/ndtxt.cxx                        |    2 
 sw/source/core/txtnode/txtedt.cxx                       |    2 
 sw/source/core/undo/SwUndoField.cxx                     |    4 
 sw/source/core/undo/docundo.cxx                         |    4 
 sw/source/core/undo/unattr.cxx                          |   13 -
 sw/source/core/undo/undobj.cxx                          |   31 +--
 sw/source/core/undo/unins.cxx                           |   32 +--
 sw/source/core/undo/unredln.cxx                         |   26 +--
 sw/source/core/undo/unsect.cxx                          |   14 -
 sw/source/core/undo/unspnd.cxx                          |   16 -
 sw/source/core/undo/untbl.cxx                           |   69 ++++----
 sw/source/core/undo/untblk.cxx                          |   14 -
 sw/source/core/unocore/unocoll.cxx                      |    2 
 sw/source/core/unocore/unocrsr.cxx                      |    4 
 sw/source/core/unocore/unocrsrhelper.cxx                |   18 +-
 sw/source/core/unocore/unoframe.cxx                     |    2 
 sw/source/core/unocore/unosett.cxx                      |    4 
 sw/source/core/unocore/unostyle.cxx                     |    9 -
 sw/source/core/unocore/unotext.cxx                      |    2 
 sw/source/filter/basflt/fltshell.cxx                    |   12 -
 sw/source/filter/basflt/shellio.cxx                     |   33 +---
 sw/source/filter/html/SwAppletImpl.cxx                  |    5 
 sw/source/filter/html/htmlcss1.cxx                      |    4 
 sw/source/filter/html/htmlctxt.cxx                      |    2 
 sw/source/filter/html/htmlgrin.cxx                      |    2 
 sw/source/filter/html/htmlplug.cxx                      |    5 
 sw/source/filter/html/svxcss1.cxx                       |    5 
 sw/source/filter/html/svxcss1.hxx                       |    1 
 sw/source/filter/html/swhtml.cxx                        |   27 +--
 sw/source/filter/html/swhtml.hxx                        |    3 
 sw/source/filter/ww8/docxexport.cxx                     |    2 
 sw/source/filter/ww8/rtfexport.cxx                      |    2 
 sw/source/filter/ww8/writerhelper.cxx                   |   10 -
 sw/source/filter/ww8/writerhelper.hxx                   |    2 
 sw/source/filter/ww8/wrtww8.cxx                         |   18 +-
 sw/source/filter/ww8/wrtww8.hxx                         |    2 
 sw/source/filter/ww8/ww8par.cxx                         |    8 
 sw/source/filter/ww8/ww8par4.cxx                        |    2 
 sw/source/filter/xml/XMLRedlineImportHelper.cxx         |    7 
 sw/source/filter/xml/swxml.cxx                          |   20 +-
 sw/source/filter/xml/wrtxml.cxx                         |   20 +-
 sw/source/filter/xml/xmlexp.cxx                         |   12 -
 sw/source/filter/xml/xmlimp.cxx                         |   10 -
 sw/source/filter/xml/xmlimp.hxx                         |    2 
 sw/source/filter/xml/xmltexti.cxx                       |    4 
 sw/source/filter/xml/xmltexti.hxx                       |    2 
 sw/source/ui/dialog/swdlgfact.cxx                       |  116 ++------------
 sw/source/ui/dialog/swdlgfact.hxx                       |   18 --
 sw/source/uibase/app/docsh.cxx                          |    8 
 sw/source/uibase/dbui/dbmgr.cxx                         |   11 -
 sw/source/uibase/docvw/PostItMgr.cxx                    |    1 
 sw/source/uibase/inc/wrtsh.hxx                          |    2 
 sw/source/uibase/misc/glshell.cxx                       |    2 
 sw/source/uibase/shells/annotsh.cxx                     |    2 
 sw/source/uibase/shells/basesh.cxx                      |    6 
 sw/source/uibase/shells/drwbassh.cxx                    |    2 
 sw/source/uibase/shells/drwtxtex.cxx                    |    2 
 sw/source/uibase/shells/textfld.cxx                     |    2 
 sw/source/uibase/shells/textidx.cxx                     |    2 
 sw/source/uibase/shells/textsh1.cxx                     |    8 
 sw/source/uibase/uiview/view2.cxx                       |   40 ++--
 sw/source/uibase/uiview/viewdlg2.cxx                    |    2 
 sw/source/uibase/uiview/viewstat.cxx                    |    5 
 sw/source/uibase/uno/SwXDocumentSettings.cxx            |    6 
 sw/source/uibase/uno/unoatxt.cxx                        |    4 
 sw/source/uibase/uno/unodoc.cxx                         |    2 
 sw/source/uibase/uno/unotxdoc.cxx                       |   49 ++----
 sw/source/uibase/utlui/glbltree.cxx                     |    1 
 sw/source/uibase/web/wdocsh.cxx                         |    4 
 sw/source/uibase/wrtsh/select.cxx                       |    4 
 149 files changed, 719 insertions(+), 866 deletions(-)

New commits:
commit 579426f798580093214fa8a7cc648318642c7e12
Author: Noel Grandin <noel at peralex.com>
Date:   Thu Sep 8 09:23:17 2016 +0200

    loplugin:constantparam in sw
    
    Change-Id: Ic49d1c3c7b57fb213964ddc21b0f774c762aad94

diff --git a/sw/inc/IDocumentContentOperations.hxx b/sw/inc/IDocumentContentOperations.hxx
index 1572e21..0a1087e 100644
--- a/sw/inc/IDocumentContentOperations.hxx
+++ b/sw/inc/IDocumentContentOperations.hxx
@@ -175,7 +175,7 @@ public:
         const SfxItemSet* pGrfAttrSet, SwFrameFormat*) = 0;
 
     virtual SwFlyFrameFormat* InsertOLE(const SwPaM &rRg, const OUString& rObjName, sal_Int64 nAspect, const SfxItemSet* pFlyAttrSet,
-                           const SfxItemSet* pGrfAttrSet, SwFrameFormat*) = 0;
+                           const SfxItemSet* pGrfAttrSet) = 0;
 
     /** Split a node at rPos (implemented only for TextNode).
     */
diff --git a/sw/inc/IDocumentFieldsAccess.hxx b/sw/inc/IDocumentFieldsAccess.hxx
index f9b116b..f73e51c 100644
--- a/sw/inc/IDocumentFieldsAccess.hxx
+++ b/sw/inc/IDocumentFieldsAccess.hxx
@@ -88,7 +88,7 @@ namespace com { namespace sun { namespace star { namespace uno { class Any; } }
     */
     virtual bool UpdateField(SwTextField * rDstFormatField, SwField & rSrcField, SwMsgPoolItem * pMsgHint, bool bUpdateTableFields) = 0;
 
-    virtual void UpdateRefFields(SfxPoolItem* pHt) = 0;
+    virtual void UpdateRefFields() = 0;
 
     virtual void UpdateTableFields(SfxPoolItem* pHt) = 0;
 
diff --git a/sw/inc/SwAppletImpl.hxx b/sw/inc/SwAppletImpl.hxx
index 9fbeb45..0d6d7d6 100644
--- a/sw/inc/SwAppletImpl.hxx
+++ b/sw/inc/SwAppletImpl.hxx
@@ -50,7 +50,7 @@ class SwApplet_Impl
 
 public:
     static SwHtmlOptType GetOptionType( const OUString& rName, bool bApplet );
-    SwApplet_Impl( SfxItemPool& rPool, sal_uInt16 nWhich1, sal_uInt16 nWhich2 );
+    SwApplet_Impl( SfxItemPool& rPool );
     SwApplet_Impl( SfxItemSet& rSet ): aItemSet ( rSet) {}
     ~SwApplet_Impl();
     void CreateApplet( const OUString& rCode, const OUString& rName,
diff --git a/sw/inc/SwUndoField.hxx b/sw/inc/SwUndoField.hxx
index 541cb54..66ad76e 100644
--- a/sw/inc/SwUndoField.hxx
+++ b/sw/inc/SwUndoField.hxx
@@ -52,8 +52,7 @@ class SwUndoFieldFromDoc : public SwUndoField
 public:
     SwUndoFieldFromDoc(const SwPosition & rPos, const SwField & aOldField,
                        const SwField & aNewField,
-                       SwMsgPoolItem * pHint, bool bUpdate,
-                       SwUndoId nId = UNDO_FIELD );
+                       SwMsgPoolItem * pHint, bool bUpdate);
 
     virtual ~SwUndoFieldFromDoc();
 
diff --git a/sw/inc/fesh.hxx b/sw/inc/fesh.hxx
index 20eb7c9..550f1aa 100644
--- a/sw/inc/fesh.hxx
+++ b/sw/inc/fesh.hxx
@@ -625,7 +625,6 @@ public:
 
     SwFlyFrameFormat* InsertObject( const svt::EmbeddedObjectRef&,
                 const SfxItemSet* pFlyAttrSet,
-                const SfxItemSet* pGrfAttrSet = nullptr,
                 SwFrameFormat* = nullptr );
     bool    FinishOLEObj(); ///< Shutdown server.
 
diff --git a/sw/inc/ftninfo.hxx b/sw/inc/ftninfo.hxx
index 76bdff5..585130c 100644
--- a/sw/inc/ftninfo.hxx
+++ b/sw/inc/ftninfo.hxx
@@ -100,7 +100,7 @@ public:
 
     bool operator==( const SwFootnoteInfo &rInf ) const;
 
-    SwFootnoteInfo(SwTextFormatColl* pTextColl = nullptr);
+    SwFootnoteInfo();
     SwFootnoteInfo(const SwFootnoteInfo&);
 };
 
diff --git a/sw/inc/grfatr.hxx b/sw/inc/grfatr.hxx
index 90838c3..f4a4ad1 100644
--- a/sw/inc/grfatr.hxx
+++ b/sw/inc/grfatr.hxx
@@ -94,8 +94,8 @@ class SwRotationGrf : public SfxUInt16Item
 {
     Size aUnrotatedSize;
 public:
-    SwRotationGrf( sal_Int16 nVal = 0 )
-        : SfxUInt16Item( RES_GRFATR_ROTATION, nVal )
+    SwRotationGrf()
+        : SfxUInt16Item( RES_GRFATR_ROTATION, 0 )
     {}
     SwRotationGrf( sal_Int16 nVal, const Size& rSz )
         : SfxUInt16Item( RES_GRFATR_ROTATION, nVal ), aUnrotatedSize( rSz )
diff --git a/sw/inc/ndgrf.hxx b/sw/inc/ndgrf.hxx
index 6394db3..2734d19 100644
--- a/sw/inc/ndgrf.hxx
+++ b/sw/inc/ndgrf.hxx
@@ -126,7 +126,8 @@ public:
     void SetGraphic(const Graphic& rGraphic, const OUString& rLink);
 
     /// wrappers for non-const calls at GraphicObject
-    void StartGraphicAnimation(OutputDevice* pOut, const Point& rPt, const Size& rSz, long nExtraData, const GraphicAttr* pAttr = nullptr, GraphicManagerDrawFlags nFlags = GraphicManagerDrawFlags::STANDARD, OutputDevice* pFirstFrameOutDev = nullptr) { maGrfObj.StartAnimation(pOut, rPt, rSz, nExtraData, pAttr, nFlags, pFirstFrameOutDev); }
+    void StartGraphicAnimation(OutputDevice* pOut, const Point& rPt, const Size& rSz, long nExtraData, OutputDevice* pFirstFrameOutDev = nullptr)
+    { maGrfObj.StartAnimation(pOut, rPt, rSz, nExtraData, nullptr, GraphicManagerDrawFlags::STANDARD, pFirstFrameOutDev); }
     void StopGraphicAnimation(OutputDevice* pOut, long nExtraData = 0) { maGrfObj.StopAnimation(pOut, nExtraData); }
 
     virtual Size GetTwipSize() const override;
diff --git a/sw/inc/postithelper.hxx b/sw/inc/postithelper.hxx
index e4bf2bf..9642a7e 100644
--- a/sw/inc/postithelper.hxx
+++ b/sw/inc/postithelper.hxx
@@ -114,7 +114,6 @@ public:
     virtual const SwFormatField& GetFormatField() const = 0;
     virtual const SfxBroadcaster* GetBroadCaster() const = 0;
     virtual VclPtr<sw::sidebarwindows::SwSidebarWin> GetSidebarWindow( SwEditWin& rEditWin,
-                                                                WinBits nBits,
                                                                 SwPostItMgr& aMgr) = 0;
 };
 
@@ -145,7 +144,6 @@ public:
     }
     virtual VclPtr<sw::sidebarwindows::SwSidebarWin> GetSidebarWindow(
         SwEditWin& rEditWin,
-        WinBits nBits,
         SwPostItMgr& aMgr ) override;
 
 private:
diff --git a/sw/inc/redline.hxx b/sw/inc/redline.hxx
index d1dbd52..8a9a1f0 100644
--- a/sw/inc/redline.hxx
+++ b/sw/inc/redline.hxx
@@ -119,8 +119,7 @@ public:
 
     // For sw3io: pNext/pExtraData are taken over.
     SwRedlineData( RedlineType_t eT, sal_uInt16 nAut, const DateTime& rDT,
-                   const OUString& rCmnt, SwRedlineData* pNxt,
-                    SwRedlineExtraData* pExtraData = nullptr );
+                   const OUString& rCmnt, SwRedlineData* pNxt );
 
     ~SwRedlineData();
 
@@ -166,7 +165,7 @@ public:
         }
 
     // ExtraData gets copied, the pointer is therefore not taken over by
-    // the RedlilneObject
+    // the RedlineObject
     void SetExtraData( const SwRedlineExtraData* pData );
     const SwRedlineExtraData* GetExtraData() const { return pExtraData; }
 
diff --git a/sw/inc/splargs.hxx b/sw/inc/splargs.hxx
index e601d71..85ae6b4 100644
--- a/sw/inc/splargs.hxx
+++ b/sw/inc/splargs.hxx
@@ -121,13 +121,12 @@ public:
     sal_Int32 nWordStart;
     sal_Int32 nWordLen;
 
-    SwInterHyphInfo( const Point &rCursorPos, sal_Int32 nStartPos = 0,
-        sal_Int32 nLength = SAL_MAX_INT32 )
+    SwInterHyphInfo( const Point &rCursorPos )
         : aCursorPos(rCursorPos)
         , bNoLang(false)
         , bCheck(false)
-        , nStart(nStartPos)
-        , nEnd(nLength == SAL_MAX_INT32 ? SAL_MAX_INT32 : nStartPos + nLength)
+        , nStart(0)
+        , nEnd(SAL_MAX_INT32)
         , nWordStart(0), nWordLen(0)
     {
     }
diff --git a/sw/inc/swabstdlg.hxx b/sw/inc/swabstdlg.hxx
index f392f32..a42b520 100644
--- a/sw/inc/swabstdlg.hxx
+++ b/sw/inc/swabstdlg.hxx
@@ -333,14 +333,14 @@ public:
     virtual AbstractSwInsertAbstractDlg * CreateSwInsertAbstractDlg() = 0;
     virtual AbstractSwAsciiFilterDlg*  CreateSwAsciiFilterDlg ( SwDocShell& rDocSh,
                                                                 SvStream* pStream ) = 0;
-    virtual VclAbstractDialog * CreateSwInsertBookmarkDlg( vcl::Window *pParent, SwWrtShell &rSh, SfxRequest& rReq, int nResId ) = 0;
+    virtual VclAbstractDialog * CreateSwInsertBookmarkDlg( vcl::Window *pParent, SwWrtShell &rSh, SfxRequest& rReq ) = 0;
 
     virtual AbstractSwBreakDlg * CreateSwBreakDlg(vcl::Window *pParent, SwWrtShell &rSh) = 0;
     virtual VclAbstractDialog   * CreateSwChangeDBDlg(SwView& rVw) = 0;
     virtual SfxAbstractTabDialog *  CreateSwCharDlg(vcl::Window* pParent, SwView& pVw, const SfxItemSet& rCoreSet,
         SwCharDlgMode nDialogMode, const OUString* pFormatStr = nullptr) = 0;
     virtual AbstractSwConvertTableDlg* CreateSwConvertTableDlg(SwView& rView, bool bToTable) = 0;
-    virtual VclAbstractDialog * CreateSwCaptionDialog ( vcl::Window *pParent, SwView &rV,int nResId) = 0;
+    virtual VclAbstractDialog * CreateSwCaptionDialog ( vcl::Window *pParent, SwView &rV) = 0;
 
     virtual AbstractSwInsertDBColAutoPilot* CreateSwInsertDBColAutoPilot(SwView& rView,
         css::uno::Reference< css::sdbc::XDataSource> rxSource,
@@ -360,7 +360,6 @@ public:
     virtual SfxAbstractTabDialog* CreateSwParaDlg ( vcl::Window *pParent,
                                                     SwView& rVw,
                                                     const SfxItemSet& rCoreSet,
-                                                    const OUString *pCollName,
                                                     bool bDraw,
                                                     const OString& sDefPage = OString() ) = 0;
 
@@ -372,15 +371,15 @@ public:
     virtual AbstractSwAutoFormatDlg * CreateSwAutoFormatDlg( vcl::Window* pParent, SwWrtShell* pShell,
                                                             bool bSetAutoFormat = true,
                                                             const SwTableAutoFormat* pSelFormat = nullptr ) = 0;
-    virtual SfxAbstractDialog * CreateSwBorderDlg ( vcl::Window* pParent, SfxItemSet& rSet, SwBorderModes nType, int nResId ) = 0;
-    virtual SfxAbstractDialog * CreateSwWrapDlg ( vcl::Window* pParent, SfxItemSet& rSet, SwWrtShell* pSh, int nResId ) = 0;
+    virtual SfxAbstractDialog * CreateSwBorderDlg ( vcl::Window* pParent, SfxItemSet& rSet, SwBorderModes nType ) = 0;
+    virtual SfxAbstractDialog * CreateSwWrapDlg ( vcl::Window* pParent, SfxItemSet& rSet, SwWrtShell* pSh ) = 0;
 
     virtual VclAbstractDialog * CreateSwTableWidthDlg(vcl::Window *pParent, SwTableFUNC &rFnc) = 0;
     virtual SfxAbstractTabDialog* CreateSwTableTabDlg(vcl::Window* pParent, SfxItemPool& Pool,
         const SfxItemSet* pItemSet, SwWrtShell* pSh) = 0;
 
     virtual AbstractSwFieldDlg * CreateSwFieldDlg(SfxBindings* pB, SwChildWinWrapper* pCW, vcl::Window *pParent) = 0;
-    virtual SfxAbstractDialog*   CreateSwFieldEditDlg ( SwView& rVw, int nResId ) = 0;
+    virtual SfxAbstractDialog*   CreateSwFieldEditDlg ( SwView& rVw ) = 0;
     virtual AbstractSwRenameXNamedDlg * CreateSwRenameXNamedDlg(vcl::Window* pParent,
         css::uno::Reference< css::container::XNamed > & xNamed,
         css::uno::Reference< css::container::XNameAccess > & xNameAccess) = 0;
@@ -391,8 +390,7 @@ public:
                                                 SfxViewFrame *pFrame, vcl::Window *pParent,
                                                 const SfxItemSet& rCoreSet,
                                                 bool bNewFrame = true,
-                                                const OString& sDefPage = OString(),
-                                                const OUString* pFormatStr = nullptr) = 0;
+                                                const OString& sDefPage = OString()) = 0;
     /// @param nSlot
     /// Identifies optional Slot by which the creation of the Template (Style) dialog is triggered.
     /// Currently used, if nRegion == SfxStyleFamily::Page in order to activate certain dialog pane
@@ -414,7 +412,7 @@ public:
     virtual AbstractInsTableDlg*        CreateInsTableDlg(SwView& rView) = 0;
     virtual AbstractJavaEditDialog*     CreateJavaEditDialog(vcl::Window* pParent,
         SwWrtShell* pWrtSh) = 0;
-    virtual AbstractMailMergeDlg*       CreateMailMergeDlg( int nResId,
+    virtual AbstractMailMergeDlg*       CreateMailMergeDlg(
                                                 vcl::Window* pParent, SwWrtShell& rSh,
                                                 const OUString& rSourceName,
                                                 const OUString& rTableName,
@@ -430,7 +428,7 @@ public:
     virtual AbstractMultiTOXTabDialog*      CreateMultiTOXTabDialog(
                                                 vcl::Window* pParent, const SfxItemSet& rSet,
                                                 SwWrtShell &rShell,
-                                                SwTOXBase* pCurTOX, sal_uInt16 nToxType,
+                                                SwTOXBase* pCurTOX,
                                                 bool bGlobal) = 0;
     virtual AbstractEditRegionDlg*      CreateEditRegionDlg(vcl::Window* pParent, SwWrtShell& rWrtSh) = 0;
     virtual AbstractInsertSectionTabDialog*     CreateInsertSectionTabDialog(
diff --git a/sw/inc/swcrsr.hxx b/sw/inc/swcrsr.hxx
index 0e9d7d3..b8c269a 100644
--- a/sw/inc/swcrsr.hxx
+++ b/sw/inc/swcrsr.hxx
@@ -271,7 +271,7 @@ protected:
     virtual bool IsSelOvrCheck(int eFlags) override;
 
 public:
-    SwTableCursor( const SwPosition &rPos, SwPaM* pRing = nullptr );
+    SwTableCursor( const SwPosition &rPos );
     SwTableCursor( SwTableCursor& );
     virtual ~SwTableCursor();
 
diff --git a/sw/inc/swtable.hxx b/sw/inc/swtable.hxx
index 303b1dc..619bd8f 100644
--- a/sw/inc/swtable.hxx
+++ b/sw/inc/swtable.hxx
@@ -128,8 +128,7 @@ public:
     };
 
 
-    // single argument ctors shall be explicit.
-    explicit SwTable( SwTableFormat* );
+    explicit SwTable();
     virtual ~SwTable();
 
     // @@@ public copy ctor, but no copy assignment?
diff --git a/sw/inc/txatritr.hxx b/sw/inc/txatritr.hxx
index 471c668..665df19 100644
--- a/sw/inc/txatritr.hxx
+++ b/sw/inc/txatritr.hxx
@@ -74,9 +74,8 @@ public:
 class SwLanguageIterator : public SwTextAttrIterator
 {
 public:
-    SwLanguageIterator( const SwTextNode& rTextNode, sal_Int32 nStart = 0,
-                        sal_uInt16 nWhich = RES_CHRATR_LANGUAGE )
-        : SwTextAttrIterator( rTextNode, nWhich, nStart )
+    SwLanguageIterator( const SwTextNode& rTextNode, sal_Int32 nStart = 0 )
+        : SwTextAttrIterator( rTextNode, RES_CHRATR_LANGUAGE, nStart )
     {}
 
     sal_uInt16 GetLanguage() const
diff --git a/sw/inc/unocrsr.hxx b/sw/inc/unocrsr.hxx
index 9ee9261..a06fd71 100644
--- a/sw/inc/unocrsr.hxx
+++ b/sw/inc/unocrsr.hxx
@@ -39,7 +39,7 @@ private:
     bool m_bSkipOverProtectSections : 1;
 
 public:
-    SwUnoCursor( const SwPosition &rPos, SwPaM* pRing = nullptr );
+    SwUnoCursor( const SwPosition &rPos );
     virtual ~SwUnoCursor();
 
 protected:
diff --git a/sw/inc/unosett.hxx b/sw/inc/unosett.hxx
index dff4f1f..ad80037 100644
--- a/sw/inc/unosett.hxx
+++ b/sw/inc/unosett.hxx
@@ -263,7 +263,7 @@ class SwXTextColumns : public cppu::WeakAggImplHelper4
 protected:
     virtual ~SwXTextColumns();
 public:
-    SwXTextColumns(sal_uInt16 nColCount);
+    SwXTextColumns();
     SwXTextColumns(const SwFormatCol& rFormatCol);
 
     static const css::uno::Sequence< sal_Int8 > & getUnoTunnelId();
diff --git a/sw/inc/view.hxx b/sw/inc/view.hxx
index 76d1a34..636e917 100644
--- a/sw/inc/view.hxx
+++ b/sw/inc/view.hxx
@@ -621,8 +621,7 @@ public:
 
     //public fuer D&D
     int     InsertGraphic( const OUString &rPath, const OUString &rFilter,
-                            bool bLink, GraphicFilter *pFlt,
-                            Graphic* pPreviewGrf = nullptr );
+                            bool bLink, GraphicFilter *pFlt );
 
     void ExecuteScan( SfxRequest& rReq );
 
diff --git a/sw/inc/wdocsh.hxx b/sw/inc/wdocsh.hxx
index 286c16d..3e0cf53 100644
--- a/sw/inc/wdocsh.hxx
+++ b/sw/inc/wdocsh.hxx
@@ -35,7 +35,7 @@ private:
     static void InitInterface_Impl();
 
 public:
-    SwWebDocShell(SfxObjectCreateMode eMode = SfxObjectCreateMode::EMBEDDED);
+    SwWebDocShell();
     virtual ~SwWebDocShell();
 
     virtual void        FillClass( SvGlobalName * pClassName,
diff --git a/sw/source/core/crsr/crstrvl.cxx b/sw/source/core/crsr/crstrvl.cxx
index c3def6d..e7853e3 100644
--- a/sw/source/core/crsr/crstrvl.cxx
+++ b/sw/source/core/crsr/crstrvl.cxx
@@ -528,7 +528,7 @@ bool SwCursorShell::GotoNxtPrvTOXMark( bool bNext )
                 ( IsReadOnlyAvailable() || !pCFrame->IsProtected() ))
             {
                 SwNodeIndex aNdIndex( *pTextNd ); // UNIX needs this object
-                SetGetExpField aCmp( aNdIndex, *pTextTOX, nullptr );
+                SetGetExpField aCmp( aNdIndex, *pTextTOX );
                 aCmp.SetBodyPos( *pCFrame );
 
                 if( bNext ? ( aCurGEF < aCmp && aCmp < aFndGEF )
diff --git a/sw/source/core/crsr/swcrsr.cxx b/sw/source/core/crsr/swcrsr.cxx
index 3dbb7e2..56dc9a0 100644
--- a/sw/source/core/crsr/swcrsr.cxx
+++ b/sw/source/core/crsr/swcrsr.cxx
@@ -2108,8 +2108,8 @@ void SwCursor::RestoreSavePos()
     }
 }
 
-SwTableCursor::SwTableCursor( const SwPosition &rPos, SwPaM* pRing )
-    : SwCursor( rPos, pRing )
+SwTableCursor::SwTableCursor( const SwPosition &rPos )
+    : SwCursor( rPos, nullptr )
 {
     m_bParked = false;
     m_bChanged = false;
diff --git a/sw/source/core/doc/DocumentContentOperationsManager.cxx b/sw/source/core/doc/DocumentContentOperationsManager.cxx
index c3fce7c..47d61ba 100644
--- a/sw/source/core/doc/DocumentContentOperationsManager.cxx
+++ b/sw/source/core/doc/DocumentContentOperationsManager.cxx
@@ -2673,11 +2673,9 @@ SwFlyFrameFormat* DocumentContentOperationsManager::Insert(const SwPaM &rRg, con
 SwFlyFrameFormat* DocumentContentOperationsManager::InsertOLE(const SwPaM &rRg, const OUString& rObjName,
                         sal_Int64 nAspect,
                         const SfxItemSet* pFlyAttrSet,
-                        const SfxItemSet* pGrfAttrSet,
-                        SwFrameFormat* pFrameFormat )
+                        const SfxItemSet* pGrfAttrSet)
 {
-    if( !pFrameFormat )
-        pFrameFormat = m_rDoc.getIDocumentStylePoolAccess().GetFrameFormatFromPool( RES_POOLFRM_OLE );
+    SwFrameFormat* pFrameFormat = m_rDoc.getIDocumentStylePoolAccess().GetFrameFormatFromPool( RES_POOLFRM_OLE );
 
     return InsNoTextNode( *rRg.GetPoint(),
                             m_rDoc.GetNodes().MakeOLENode(
diff --git a/sw/source/core/doc/DocumentFieldsManager.cxx b/sw/source/core/doc/DocumentFieldsManager.cxx
index 7b7226d..c406231 100644
--- a/sw/source/core/doc/DocumentFieldsManager.cxx
+++ b/sw/source/core/doc/DocumentFieldsManager.cxx
@@ -375,7 +375,7 @@ void DocumentFieldsManager::UpdateFields( bool bCloseDB )
     UpdateTableFields(nullptr);
 
     // References
-    UpdateRefFields(nullptr);
+    UpdateRefFields();
     if( bCloseDB )
     {
 #if HAVE_FEATURE_DBCONNECTIVITY
@@ -561,11 +561,11 @@ bool DocumentFieldsManager::UpdateField(SwTextField * pDstTextField, SwField & r
 }
 
 /// Update reference and table fields
-void DocumentFieldsManager::UpdateRefFields( SfxPoolItem* pHt )
+void DocumentFieldsManager::UpdateRefFields()
 {
     for( auto pFieldType : *mpFieldTypes )
         if( RES_GETREFFLD == pFieldType->Which() )
-            pFieldType->ModifyNotification( nullptr, pHt );
+            pFieldType->ModifyNotification( nullptr, nullptr );
 }
 
 void DocumentFieldsManager::UpdateTableFields( SfxPoolItem* pHt )
@@ -835,7 +835,7 @@ void DocumentFieldsManager::UpdateExpFields( SwTextField* pUpdateField, bool bUp
     if( mpUpdateFields->GetSortLst()->empty() )
     {
         if( bUpdRefFields )
-            UpdateRefFields(nullptr);
+            UpdateRefFields();
 
         mpUpdateFields->SetInUpdateFields( bOldInUpdateFields );
         mpUpdateFields->SetFieldsDirty( false );
@@ -1156,7 +1156,7 @@ void DocumentFieldsManager::UpdateExpFields( SwTextField* pUpdateField, bool bUp
 
     // update reference fields
     if( bUpdRefFields )
-        UpdateRefFields(nullptr);
+        UpdateRefFields();
 
     mpUpdateFields->SetInUpdateFields( bOldInUpdateFields );
     mpUpdateFields->SetFieldsDirty( false );
diff --git a/sw/source/core/doc/DocumentTimerManager.cxx b/sw/source/core/doc/DocumentTimerManager.cxx
index 1a0fa08..0a38024 100644
--- a/sw/source/core/doc/DocumentTimerManager.cxx
+++ b/sw/source/core/doc/DocumentTimerManager.cxx
@@ -152,7 +152,7 @@ IMPL_LINK_TYPED( DocumentTimerManager, DoIdleJobs, Idle*, pIdle, void )
             m_rDoc.getIDocumentFieldsAccess().GetSysFieldType( RES_CHAPTERFLD )->ModifyNotification( nullptr, nullptr );    // ChapterField
             m_rDoc.getIDocumentFieldsAccess().UpdateExpFields( nullptr, false );      // Updates ExpressionFields
             m_rDoc.getIDocumentFieldsAccess().UpdateTableFields(nullptr);                // Tables
-            m_rDoc.getIDocumentFieldsAccess().UpdateRefFields(nullptr);                // References
+            m_rDoc.getIDocumentFieldsAccess().UpdateRefFields();                // References
 
             pTmpRoot->EndAllAction();
 
diff --git a/sw/source/core/doc/acmplwrd.cxx b/sw/source/core/doc/acmplwrd.cxx
index 26ba49b..9bd4f58 100644
--- a/sw/source/core/doc/acmplwrd.cxx
+++ b/sw/source/core/doc/acmplwrd.cxx
@@ -84,7 +84,7 @@ class SwAutoCompleteString
 #endif
     SwDocPtrVector aSourceDocs;
     public:
-        SwAutoCompleteString(const OUString& rStr, sal_Int32 nPos, sal_Int32 nLen);
+        SwAutoCompleteString(const OUString& rStr, sal_Int32 nLen);
 
         virtual ~SwAutoCompleteString();
         void        AddDocument(const SwDoc& rDoc);
@@ -176,8 +176,8 @@ void SwAutoCompleteWord_Impl::RemoveDocument(const SwDoc& rDoc)
 }
 
 SwAutoCompleteString::SwAutoCompleteString(
-            const OUString& rStr, sal_Int32 const nPos, sal_Int32 const nLen)
-    : editeng::IAutoCompleteString(rStr.copy(nPos, nLen))
+            const OUString& rStr, sal_Int32 const nLen)
+    : editeng::IAutoCompleteString(rStr.copy(0, nLen))
 {
 #if OSL_DEBUG_LEVEL > 0
     ++nSwAutoCompleteStringCount;
@@ -255,7 +255,7 @@ bool SwAutoCompleteWord::InsertWord( const OUString& rWord, SwDoc& rDoc )
 
     if( !bLockWordLst && nWrdLen >= nMinWrdLen )
     {
-        SwAutoCompleteString* pNew = new SwAutoCompleteString( aNewWord, 0, nWrdLen );
+        SwAutoCompleteString* pNew = new SwAutoCompleteString( aNewWord, nWrdLen );
         pNew->AddDocument(rDoc);
         std::pair<editeng::SortedAutoCompleteStrings::const_iterator, bool>
             aInsPair = m_WordList.insert(pNew);
diff --git a/sw/source/core/doc/doc.cxx b/sw/source/core/doc/doc.cxx
index 364a539e..6aea833 100644
--- a/sw/source/core/doc/doc.cxx
+++ b/sw/source/core/doc/doc.cxx
@@ -502,8 +502,8 @@ void SwDoc::ChgDBData(const SwDBData& rNewData)
 
 struct PostItField_ : public SetGetExpField
 {
-    PostItField_( const SwNodeIndex& rNdIdx, const SwTextField* pField,  const SwIndex* pIdx = nullptr )
-        : SetGetExpField( rNdIdx, pField, pIdx ) {}
+    PostItField_( const SwNodeIndex& rNdIdx, const SwTextField* pField )
+        : SetGetExpField( rNdIdx, pField, nullptr ) {}
 
     sal_uInt16 GetPageNo( const StringRangeEnumerator &rRangeEnum,
             const std::set< sal_Int32 > &rPossiblePages,
@@ -1740,7 +1740,7 @@ void SwDoc::ChkCondColls()
      {
         SwTextFormatColl *pColl = (*mpTextFormatCollTable)[n];
         if (RES_CONDTXTFMTCOLL == pColl->Which())
-            pColl->CallSwClientNotify( SwAttrHint(RES_CONDTXTFMTCOLL) );
+            pColl->CallSwClientNotify( SwAttrHint() );
      }
 }
 
diff --git a/sw/source/core/doc/doccomp.cxx b/sw/source/core/doc/doccomp.cxx
index a598e34..eeab46f 100644
--- a/sw/source/core/doc/doccomp.cxx
+++ b/sw/source/core/doc/doccomp.cxx
@@ -1666,7 +1666,7 @@ void CompareData::SetRedlinesToDoc( bool bUseDocInfo )
     if( pTmp )
     {
         SwRedlineData aRedlnData( nsRedlineType_t::REDLINE_DELETE, nAuthor, aTimeStamp,
-                                    OUString(), nullptr, nullptr );
+                                    OUString(), nullptr );
         do {
             // #i65201#: Expand again, see comment above.
             if( pTmp->GetPoint()->nContent == 0 )
@@ -1718,7 +1718,7 @@ void CompareData::SetRedlinesToDoc( bool bUseDocInfo )
             }
         } while( pInsRing != ( pTmp = pTmp->GetNext()) );
         SwRedlineData aRedlnData( nsRedlineType_t::REDLINE_INSERT, nAuthor, aTimeStamp,
-                                    OUString(), nullptr, nullptr );
+                                    OUString(), nullptr );
 
         // combine consecutive
         if( pTmp->GetNext() != pInsRing )
diff --git a/sw/source/core/doc/docfld.cxx b/sw/source/core/doc/docfld.cxx
index d450dcd..9282e01 100644
--- a/sw/source/core/doc/docfld.cxx
+++ b/sw/source/core/doc/docfld.cxx
@@ -85,15 +85,12 @@ SetGetExpField::SetGetExpField(
 }
 
 SetGetExpField::SetGetExpField( const SwNodeIndex& rNdIdx,
-                            const SwTextINetFormat& rINet, const SwIndex* pIdx )
+                            const SwTextINetFormat& rINet )
 {
     eSetGetExpFieldType = TEXTINET;
     CNTNT.pTextINet = &rINet;
     nNode = rNdIdx.GetIndex();
-    if( pIdx )
-        nContent = pIdx->GetIndex();
-    else
-        nContent = rINet.GetStart();
+    nContent = rINet.GetStart();
 }
 
 // Extension for Sections:
@@ -117,41 +114,29 @@ SetGetExpField::SetGetExpField( const SwSectionNode& rSectNd,
     }
 }
 
-SetGetExpField::SetGetExpField( const SwTableBox& rTBox, const SwPosition* pPos )
+SetGetExpField::SetGetExpField( const SwTableBox& rTBox )
 {
     eSetGetExpFieldType = TABLEBOX;
     CNTNT.pTBox = &rTBox;
 
-    if( pPos )
+    nNode = 0;
+    nContent = 0;
+    if( rTBox.GetSttNd() )
     {
-        nNode = pPos->nNode.GetIndex();
-        nContent = pPos->nContent.GetIndex();
-    }
-    else
-    {
-        nNode = 0;
-        nContent = 0;
-        if( rTBox.GetSttNd() )
-        {
-            SwNodeIndex aIdx( *rTBox.GetSttNd() );
-            const SwContentNode* pNd = aIdx.GetNode().GetNodes().GoNext( &aIdx );
-            if( pNd )
-                nNode = pNd->GetIndex();
-        }
+        SwNodeIndex aIdx( *rTBox.GetSttNd() );
+        const SwContentNode* pNd = aIdx.GetNode().GetNodes().GoNext( &aIdx );
+        if( pNd )
+            nNode = pNd->GetIndex();
     }
 }
 
 SetGetExpField::SetGetExpField( const SwNodeIndex& rNdIdx,
-                                const SwTextTOXMark& rTOX,
-                                const SwIndex* pIdx )
+                                const SwTextTOXMark& rTOX )
 {
     eSetGetExpFieldType = TEXTTOXMARK;
     CNTNT.pTextTOX = &rTOX;
     nNode = rNdIdx.GetIndex();
-    if( pIdx )
-        nContent = pIdx->GetIndex();
-    else
-        nContent = rTOX.GetStart();
+    nContent = rTOX.GetStart();
 }
 
 SetGetExpField::SetGetExpField( const SwPosition& rPos )
diff --git a/sw/source/core/doc/docftn.cxx b/sw/source/core/doc/docftn.cxx
index 807a972..522a908 100644
--- a/sw/source/core/doc/docftn.cxx
+++ b/sw/source/core/doc/docftn.cxx
@@ -239,8 +239,8 @@ SwFootnoteInfo::SwFootnoteInfo(const SwFootnoteInfo& rInfo) :
     m_bEndNote = false;
 }
 
-SwFootnoteInfo::SwFootnoteInfo(SwTextFormatColl *pFormat) :
-    SwEndNoteInfo( pFormat ),
+SwFootnoteInfo::SwFootnoteInfo() :
+    SwEndNoteInfo( nullptr ),
     ePos( FTNPOS_PAGE ),
     eNum( FTNNUM_DOC )
 {
@@ -314,7 +314,7 @@ void SwDoc::SetFootnoteInfo(const SwFootnoteInfo& rInfo)
         // #i81002# no update during loading
         if ( !IsInReading() )
         {
-            getIDocumentFieldsAccess().UpdateRefFields(nullptr);
+            getIDocumentFieldsAccess().UpdateRefFields();
         }
         getIDocumentState().SetModified();
     }
@@ -382,7 +382,7 @@ void SwDoc::SetEndNoteInfo(const SwEndNoteInfo& rInfo)
         // #i81002# no update during loading
         if ( !IsInReading() )
         {
-            getIDocumentFieldsAccess().UpdateRefFields(nullptr);
+            getIDocumentFieldsAccess().UpdateRefFields();
         }
         getIDocumentState().SetModified();
     }
diff --git a/sw/source/core/doc/docredln.cxx b/sw/source/core/doc/docredln.cxx
index 48bf288..5f258a4 100644
--- a/sw/source/core/doc/docredln.cxx
+++ b/sw/source/core/doc/docredln.cxx
@@ -860,8 +860,8 @@ SwRedlineData::SwRedlineData(
 
 // For sw3io: We now own pNext!
 SwRedlineData::SwRedlineData(RedlineType_t eT, sal_uInt16 nAut, const DateTime& rDT,
-    const OUString& rCmnt, SwRedlineData *pNxt, SwRedlineExtraData* pData)
-    : pNext(pNxt), pExtraData(pData), sComment(rCmnt), aStamp(rDT),
+    const OUString& rCmnt, SwRedlineData *pNxt)
+    : pNext(pNxt), pExtraData(nullptr), sComment(rCmnt), aStamp(rDT),
     eType(eT), nAuthor(nAut), nSeqNo(0)
 {
 }
diff --git a/sw/source/core/doc/doctxm.cxx b/sw/source/core/doc/doctxm.cxx
index 5ac6367..4806953 100644
--- a/sw/source/core/doc/doctxm.cxx
+++ b/sw/source/core/doc/doctxm.cxx
@@ -691,7 +691,7 @@ static const SwTextNode* lcl_FindChapterNode( const SwNode& rNd, sal_uInt8 nLvl
         // then find the "Anchor" (Body) position
         Point aPt;
         SwNode2Layout aNode2Layout( *pNd, pNd->GetIndex() );
-        const SwFrame* pFrame = aNode2Layout.GetFrame( &aPt, nullptr );
+        const SwFrame* pFrame = aNode2Layout.GetFrame( &aPt );
 
         if( pFrame )
         {
diff --git a/sw/source/core/doc/notxtfrm.cxx b/sw/source/core/doc/notxtfrm.cxx
index 08517a1..6eb7bb4 100644
--- a/sw/source/core/doc/notxtfrm.cxx
+++ b/sw/source/core/doc/notxtfrm.cxx
@@ -944,7 +944,7 @@ void SwNoTextFrame::PaintPicture( vcl::RenderContext* pOut, const SwRect &rGrfAr
 
                     pGrfNd->StartGraphicAnimation(pOut, aAlignedGrfArea.Pos(),
                                         aAlignedGrfArea.SSize(), sal_IntPtr(this),
-                                        nullptr, GraphicManagerDrawFlags::STANDARD, pVout );
+                                        pVout );
                 }
                 else
                 {
diff --git a/sw/source/core/doc/tblrwcl.cxx b/sw/source/core/doc/tblrwcl.cxx
index 1b21c1b..e0f13cc 100644
--- a/sw/source/core/doc/tblrwcl.cxx
+++ b/sw/source/core/doc/tblrwcl.cxx
@@ -1371,8 +1371,8 @@ struct InsULPara
 
     InsULPara( SwTableNode* pTNd,
                 SwTableBox* pLeft,
-                SwTableLine* pLine=nullptr, SwTableBox* pBox=nullptr )
-        : pTableNd( pTNd ), pInsLine( pLine ), pInsBox( pBox ),
+                SwTableLine* pLine=nullptr )
+        : pTableNd( pTNd ), pInsLine( pLine ), pInsBox( nullptr ),
         pLeftBox( pLeft )
         {   bUL_LR = true; bUL = true; }
 
diff --git a/sw/source/core/docnode/ndtbl.cxx b/sw/source/core/docnode/ndtbl.cxx
index 1c1d2ac..1c92872 100644
--- a/sw/source/core/docnode/ndtbl.cxx
+++ b/sw/source/core/docnode/ndtbl.cxx
@@ -2343,7 +2343,7 @@ sal_uInt16 SwDoc::MergeTable( SwPaM& rPam )
 SwTableNode::SwTableNode( const SwNodeIndex& rIdx )
     : SwStartNode( rIdx, ND_TABLENODE )
 {
-    m_pTable = new SwTable( nullptr );
+    m_pTable = new SwTable;
 }
 
 SwTableNode::~SwTableNode()
diff --git a/sw/source/core/docnode/node2lay.cxx b/sw/source/core/docnode/node2lay.cxx
index 18c01ee..4a829a3 100644
--- a/sw/source/core/docnode/node2lay.cxx
+++ b/sw/source/core/docnode/node2lay.cxx
@@ -453,10 +453,9 @@ SwNode2Layout::~SwNode2Layout()
 {
 }
 
-SwFrame* SwNode2Layout::GetFrame( const Point* pDocPos,
-                              const SwPosition *pPos ) const
+SwFrame* SwNode2Layout::GetFrame( const Point* pDocPos ) const
 {
-    return pImpl->GetFrame( pDocPos, pPos );
+    return pImpl->GetFrame( pDocPos, nullptr );
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/core/docnode/section.cxx b/sw/source/core/docnode/section.cxx
index b44a263..0e1065d 100644
--- a/sw/source/core/docnode/section.cxx
+++ b/sw/source/core/docnode/section.cxx
@@ -72,8 +72,8 @@ class SwIntrnlSectRefLink : public SwBaseLink
 {
     SwSectionFormat& rSectFormat;
 public:
-    SwIntrnlSectRefLink( SwSectionFormat& rFormat, SfxLinkUpdateMode nUpdateType, SotClipboardFormatId nFormat )
-        : SwBaseLink( nUpdateType, nFormat ),
+    SwIntrnlSectRefLink( SwSectionFormat& rFormat, SfxLinkUpdateMode nUpdateType )
+        : SwBaseLink( nUpdateType, SotClipboardFormatId::RTF ),
         rSectFormat( rFormat )
     {}
 
@@ -1506,7 +1506,7 @@ void SwSection::CreateLink( LinkCreateType eCreateType )
     if (!m_RefLink.Is())
     {
         // create BaseLink
-        m_RefLink = new SwIntrnlSectRefLink( *pFormat, nUpdateType, SotClipboardFormatId::RTF );
+        m_RefLink = new SwIntrnlSectRefLink( *pFormat, nUpdateType );
     }
     else
     {
diff --git a/sw/source/core/fields/postithelper.cxx b/sw/source/core/fields/postithelper.cxx
index 68f82c3..42f5757 100644
--- a/sw/source/core/fields/postithelper.cxx
+++ b/sw/source/core/fields/postithelper.cxx
@@ -145,10 +145,9 @@ bool SwAnnotationItem::UseElement()
 
 VclPtr<sw::sidebarwindows::SwSidebarWin> SwAnnotationItem::GetSidebarWindow(
                                                             SwEditWin& rEditWin,
-                                                            WinBits nBits,
                                                             SwPostItMgr& aMgr)
 {
-    return VclPtr<sw::annotation::SwAnnotationWin>::Create( rEditWin, nBits,
+    return VclPtr<sw::annotation::SwAnnotationWin>::Create( rEditWin, WB_DIALOGCONTROL,
                                                 aMgr, 0,
                                                 *this,
                                                 &mrFormatField );
diff --git a/sw/source/core/frmedt/fefly1.cxx b/sw/source/core/frmedt/fefly1.cxx
index d05c562..b10233f 100644
--- a/sw/source/core/frmedt/fefly1.cxx
+++ b/sw/source/core/frmedt/fefly1.cxx
@@ -851,7 +851,6 @@ void SwFEShell::Insert( const OUString& rGrfName, const OUString& rFltName,
 
 SwFlyFrameFormat* SwFEShell::InsertObject( const svt::EmbeddedObjectRef&  xObj,
                         const SfxItemSet* pFlyAttrSet,
-                        const SfxItemSet* pGrfAttrSet,
                         SwFrameFormat* pFrameFormat )
 {
     SwFlyFrameFormat* pFormat = nullptr;
@@ -860,7 +859,7 @@ SwFlyFrameFormat* SwFEShell::InsertObject( const svt::EmbeddedObjectRef&  xObj,
         for(SwPaM& rPaM : GetCursor()->GetRingContainer())
         {
             pFormat = GetDoc()->getIDocumentContentOperations().Insert(rPaM, xObj,
-                                    pFlyAttrSet, pGrfAttrSet, pFrameFormat );
+                                    pFlyAttrSet, nullptr, pFrameFormat );
             OSL_ENSURE( pFormat, "Doc->getIDocumentContentOperations().Insert(notxt) failed." );
 
         }
diff --git a/sw/source/core/inc/DocumentContentOperationsManager.hxx b/sw/source/core/inc/DocumentContentOperationsManager.hxx
index 6fade41..130546f 100644
--- a/sw/source/core/inc/DocumentContentOperationsManager.hxx
+++ b/sw/source/core/inc/DocumentContentOperationsManager.hxx
@@ -77,7 +77,7 @@ public:
         const SfxItemSet* pGrfAttrSet, SwFrameFormat*) override;
 
     SwFlyFrameFormat* InsertOLE(const SwPaM &rRg, const OUString& rObjName, sal_Int64 nAspect, const SfxItemSet* pFlyAttrSet,
-                           const SfxItemSet* pGrfAttrSet, SwFrameFormat*) override;
+                           const SfxItemSet* pGrfAttrSet) override;
 
     bool SplitNode(const SwPosition &rPos, bool bChkTableStart) override;
 
diff --git a/sw/source/core/inc/DocumentFieldsManager.hxx b/sw/source/core/inc/DocumentFieldsManager.hxx
index a5facc6..fa8d797 100644
--- a/sw/source/core/inc/DocumentFieldsManager.hxx
+++ b/sw/source/core/inc/DocumentFieldsManager.hxx
@@ -43,7 +43,7 @@ public:
     virtual void InsDeletedFieldType(SwFieldType &) override;
     virtual bool PutValueToField(const SwPosition & rPos, const css::uno::Any& rVal, sal_uInt16 nWhich) override;
     virtual bool UpdateField(SwTextField * rDstFormatField, SwField & rSrcField, SwMsgPoolItem * pMsgHint, bool bUpdateTableFields) override;
-    virtual void UpdateRefFields(SfxPoolItem* pHt) override;
+    virtual void UpdateRefFields() override;
     virtual void UpdateTableFields(SfxPoolItem* pHt) override;
     virtual void UpdateExpFields(SwTextField* pField, bool bUpdateRefFields) override;
     virtual void UpdateUsrFields() override;
diff --git a/sw/source/core/inc/attrhint.hxx b/sw/source/core/inc/attrhint.hxx
index 34d5631..8a3e86c5 100644
--- a/sw/source/core/inc/attrhint.hxx
+++ b/sw/source/core/inc/attrhint.hxx
@@ -24,14 +24,6 @@
 
 class SwAttrHint : public SfxHint
 {
-    sal_Int32   nId;
-
-public:
-    SwAttrHint( sal_Int32 n )
-        : nId(n)
-    {}
-
-    sal_Int32 GetId() const { return nId; }
 };
 
 #endif
diff --git a/sw/source/core/inc/docfld.hxx b/sw/source/core/inc/docfld.hxx
index bed8e0a..231a63a 100644
--- a/sw/source/core/inc/docfld.hxx
+++ b/sw/source/core/inc/docfld.hxx
@@ -63,17 +63,14 @@ public:
     SetGetExpField( const SwNodeIndex& rNdIdx, const SwTextField* pField = nullptr,
                     const SwIndex* pIdx = nullptr );
 
-    SetGetExpField( const SwNodeIndex& rNdIdx, const SwTextINetFormat& rINet,
-                    const SwIndex* pIdx = nullptr );
+    SetGetExpField( const SwNodeIndex& rNdIdx, const SwTextINetFormat& rINet );
 
     SetGetExpField( const SwSectionNode& rSectNode,
                     const SwPosition* pPos = nullptr  );
 
-    SetGetExpField( const SwTableBox& rTableBox,
-                    const SwPosition* pPos = nullptr  );
+    SetGetExpField( const SwTableBox& rTableBox  );
 
-    SetGetExpField( const SwNodeIndex& rNdIdx, const SwTextTOXMark& rTOX,
-                    const SwIndex* pIdx );
+    SetGetExpField( const SwNodeIndex& rNdIdx, const SwTextTOXMark& rTOX );
 
     SetGetExpField( const SwPosition& rPos );
 
diff --git a/sw/source/core/inc/node2lay.hxx b/sw/source/core/inc/node2lay.hxx
index 7fb2fcd..3cec60f 100644
--- a/sw/source/core/inc/node2lay.hxx
+++ b/sw/source/core/inc/node2lay.hxx
@@ -67,7 +67,7 @@ public:
     SwLayoutFrame* UpperFrame( SwFrame* &rpFrame, const SwNode& rNode );
     void RestoreUpperFrames( SwNodes& rNds, sal_uLong nStt, sal_uLong nEnd );
 
-    SwFrame *GetFrame( const Point* pDocPos, const SwPosition *pPos ) const;
+    SwFrame *GetFrame( const Point* pDocPos ) const;
 };
 
 #endif
diff --git a/sw/source/core/layout/newfrm.cxx b/sw/source/core/layout/newfrm.cxx
index 1470822..b8b0963 100644
--- a/sw/source/core/layout/newfrm.cxx
+++ b/sw/source/core/layout/newfrm.cxx
@@ -535,7 +535,7 @@ void SwRootFrame::Init( SwFrameFormat* pFormat )
     //Remove masters that haven't been replaced yet from the list.
     RemoveMasterObjs( mpDrawPage );
     if( rSettingAccess.get(DocumentSettingId::GLOBAL_DOCUMENT) )
-        rFieldsAccess.UpdateRefFields( nullptr );
+        rFieldsAccess.UpdateRefFields();
     //b6433357: Update page fields after loading
     if ( !mpCurrShell || !mpCurrShell->Imp()->IsUpdateExpFields() )
     {
diff --git a/sw/source/core/table/swtable.cxx b/sw/source/core/table/swtable.cxx
index 4ae7636..5558fa8 100644
--- a/sw/source/core/table/swtable.cxx
+++ b/sw/source/core/table/swtable.cxx
@@ -204,8 +204,8 @@ void InsTableBox( SwDoc* pDoc, SwTableNode* pTableNd,
     }
 }
 
-SwTable::SwTable( SwTableFormat* pFormat )
-    : SwClient( pFormat ),
+SwTable::SwTable()
+    : SwClient( nullptr ),
     m_pHTMLLayout( nullptr ),
     m_pTableNode( nullptr ),
     m_nGraphicsThatResize( 0 ),
diff --git a/sw/source/core/text/atrhndl.hxx b/sw/source/core/text/atrhndl.hxx
index 76072e7..0b7caf1 100644
--- a/sw/source/core/text/atrhndl.hxx
+++ b/sw/source/core/text/atrhndl.hxx
@@ -107,8 +107,7 @@ public:
 
     // set default attributes to values in rAttrSet or from cache
     void Init( const SwAttrSet& rAttrSet,
-               const IDocumentSettingAccess& rIDocumentSettingAccess,
-               const SwViewShell* pShell );
+               const IDocumentSettingAccess& rIDocumentSettingAccess );
     void Init( const SfxPoolItem** pPoolItem, const SwAttrSet* pAttrSet,
                const IDocumentSettingAccess& rIDocumentSettingAccess,
                const SwViewShell* pShell, SwFont& rFnt,
diff --git a/sw/source/core/text/atrstck.cxx b/sw/source/core/text/atrstck.cxx
index 2766ac5..418556f 100644
--- a/sw/source/core/text/atrstck.cxx
+++ b/sw/source/core/text/atrstck.cxx
@@ -357,11 +357,10 @@ SwAttrHandler::~SwAttrHandler()
 }
 
 void SwAttrHandler::Init( const SwAttrSet& rAttrSet,
-                          const IDocumentSettingAccess& rIDocumentSettingAcces,
-                          const SwViewShell* pSh )
+                          const IDocumentSettingAccess& rIDocumentSettingAcces )
 {
     mpIDocumentSettingAccess = &rIDocumentSettingAcces;
-    mpShell = pSh;
+    mpShell = nullptr;
 
     for ( sal_uInt16 i = RES_CHRATR_BEGIN; i < RES_CHRATR_END; i++ )
         pDefaultArray[ StackPos[ i ] ] = &rAttrSet.Get( i );
diff --git a/sw/source/core/text/frmpaint.cxx b/sw/source/core/text/frmpaint.cxx
index ef8e22f..7f6efc6 100644
--- a/sw/source/core/text/frmpaint.cxx
+++ b/sw/source/core/text/frmpaint.cxx
@@ -490,7 +490,7 @@ bool SwTextFrame::PaintEmpty( const SwRect &rRect, bool bCheck ) const
                 {
                     SwAttrHandler aAttrHandler;
                     aAttrHandler.Init(  rTextNode.GetSwAttrSet(),
-                                       *rTextNode.getIDocumentSettingAccess(), nullptr );
+                                       *rTextNode.getIDocumentSettingAccess() );
                     SwRedlineItr aRedln( rTextNode, *pFnt, aAttrHandler, nRedlPos, true );
                 }
             }
diff --git a/sw/source/core/text/inftxt.cxx b/sw/source/core/text/inftxt.cxx
index d98ed5d..1f0fa02 100644
--- a/sw/source/core/text/inftxt.cxx
+++ b/sw/source/core/text/inftxt.cxx
@@ -323,7 +323,7 @@ void SwTextSizeInfo::CtorInitTextSizeInfo( OutputDevice* pRenderContext, SwTextF
 }
 
 SwTextSizeInfo::SwTextSizeInfo( const SwTextSizeInfo &rNew, const OUString* pText,
-                              const sal_Int32 nIndex, const sal_Int32 nLength )
+                              const sal_Int32 nIndex )
     : SwTextInfo( rNew ),
       m_pKanaComp(rNew.GetpKanaComp()),
       m_pVsh(const_cast<SwTextSizeInfo&>(rNew).GetVsh()),
@@ -335,7 +335,7 @@ SwTextSizeInfo::SwTextSizeInfo( const SwTextSizeInfo &rNew, const OUString* pTex
       m_pOpt(&rNew.GetOpt()),
       m_pText(pText),
       m_nIdx(nIndex),
-      m_nLen(nLength),
+      m_nLen(COMPLETE_STRING),
       m_nKanaIdx( rNew.GetKanaIdx() ),
       m_bOnWin( rNew.OnWin() ),
       m_bNotEOL( rNew.NotEOL() ),
@@ -358,12 +358,10 @@ SwTextSizeInfo::SwTextSizeInfo( const SwTextSizeInfo &rNew, const OUString* pTex
     SetLen( GetMinLen( *this ) );
 }
 
-SwTextSizeInfo::SwTextSizeInfo( SwTextFrame *pTextFrame, SwFont *pTextFnt,
-               const sal_Int32 nIndex,
-               const sal_Int32 nLength )
+SwTextSizeInfo::SwTextSizeInfo( SwTextFrame *pTextFrame, const sal_Int32 nIndex )
     : m_bOnWin(false)
 {
-    CtorInitTextSizeInfo( pTextFrame->getRootFrame()->GetCurrShell()->GetOut(), pTextFrame, pTextFnt, nIndex, nLength );
+    CtorInitTextSizeInfo( pTextFrame->getRootFrame()->GetCurrShell()->GetOut(), pTextFrame, nullptr, nIndex );
 }
 
 void SwTextSizeInfo::SelectFont()
diff --git a/sw/source/core/text/inftxt.hxx b/sw/source/core/text/inftxt.hxx
index f94d732..729f65f 100644
--- a/sw/source/core/text/inftxt.hxx
+++ b/sw/source/core/text/inftxt.hxx
@@ -194,12 +194,8 @@ protected:
 public:
     SwTextSizeInfo( const SwTextSizeInfo &rInf );
     SwTextSizeInfo( const SwTextSizeInfo &rInf, const OUString* pText,
-                   const sal_Int32 nIdx = 0,
-                   const sal_Int32 nLen = COMPLETE_STRING );
-
-    SwTextSizeInfo( SwTextFrame *pTextFrame, SwFont *pTextFnt = nullptr,
-                   const sal_Int32 nIndex = 0,
-                   const sal_Int32 nLength = COMPLETE_STRING );
+                   const sal_Int32 nIdx = 0 );
+    SwTextSizeInfo( SwTextFrame *pTextFrame, const sal_Int32 nIndex = 0 );
 
     // GetMultiAttr returns the text attribute of the multiportion,
     // if rPos is inside any multi-line part.
diff --git a/sw/source/core/text/itradj.cxx b/sw/source/core/text/itradj.cxx
index d5261ea..33c3e8e 100644
--- a/sw/source/core/text/itradj.cxx
+++ b/sw/source/core/text/itradj.cxx
@@ -558,7 +558,7 @@ SwMarginPortion *SwTextAdjuster::CalcRightMargin( SwLineLayout *pCurrent,
         delete pFly;
     }
 
-    SwMarginPortion *pRight = new SwMarginPortion( 0 );
+    SwMarginPortion *pRight = new SwMarginPortion;
     pLast->Append( pRight );
 
     if( long( nPrtWidth )< nRealWidth )
diff --git a/sw/source/core/text/porglue.cxx b/sw/source/core/text/porglue.cxx
index 8dec151..d63540d 100644
--- a/sw/source/core/text/porglue.cxx
+++ b/sw/source/core/text/porglue.cxx
@@ -145,8 +145,8 @@ SwFixPortion::SwFixPortion()
     SetWhichPor( POR_FIX );
 }
 
-SwMarginPortion::SwMarginPortion( const sal_uInt16 nFixedWidth )
-    :SwGluePortion( nFixedWidth )
+SwMarginPortion::SwMarginPortion()
+    :SwGluePortion( 0 )
 {
     SetWhichPor( POR_MARGIN );
 }
diff --git a/sw/source/core/text/porglue.hxx b/sw/source/core/text/porglue.hxx
index f2ceabf..a76b02d 100644
--- a/sw/source/core/text/porglue.hxx
+++ b/sw/source/core/text/porglue.hxx
@@ -62,7 +62,7 @@ public:
 class SwMarginPortion : public SwGluePortion
 {
 public:
-    explicit SwMarginPortion( const sal_uInt16 nFixWidth );
+    explicit SwMarginPortion();
     void AdjustRight( const SwLineLayout* pCurr );
     OUTPUT_OPERATOR_OVERRIDE
 };
diff --git a/sw/source/core/text/porlay.cxx b/sw/source/core/text/porlay.cxx
index f4df684..9dd9c95 100644
--- a/sw/source/core/text/porlay.cxx
+++ b/sw/source/core/text/porlay.cxx
@@ -187,7 +187,7 @@ SwMarginPortion *SwLineLayout::CalcLeftMargin()
          SetPortion(SwTextPortion::CopyLinePortion(*this));
     if( !pLeft )
     {
-        pLeft = new SwMarginPortion( 0 );
+        pLeft = new SwMarginPortion;
         pLeft->SetPortion( GetPortion() );
         SetPortion( pLeft );
     }
diff --git a/sw/source/core/text/pormulti.cxx b/sw/source/core/text/pormulti.cxx
index 6725508..5618e25 100644
--- a/sw/source/core/text/pormulti.cxx
+++ b/sw/source/core/text/pormulti.cxx
@@ -683,14 +683,14 @@ void SwRubyPortion::Adjust_( SwTextFormatInfo &rInf )
             pCurr->SetPortion(SwTextPortion::CopyLinePortion(*pCurr));
         if( nLeft )
         {
-            SwMarginPortion *pMarg = new SwMarginPortion( 0 );
+            SwMarginPortion *pMarg = new SwMarginPortion;
             pMarg->AddPrtWidth( nLeft );
             pMarg->SetPortion( pCurr->GetPortion() );
             pCurr->SetPortion( pMarg );
         }
         if( nRight )
         {
-            SwMarginPortion *pMarg = new SwMarginPortion( 0 );
+            SwMarginPortion *pMarg = new SwMarginPortion;
             pMarg->AddPrtWidth( nRight );
             pCurr->FindLastPortion()->Append( pMarg );
         }
diff --git a/sw/source/core/text/porrst.cxx b/sw/source/core/text/porrst.cxx
index aad0fc6..bbc2d25 100644
--- a/sw/source/core/text/porrst.cxx
+++ b/sw/source/core/text/porrst.cxx
@@ -257,7 +257,7 @@ SwTwips SwTextFrame::EmptyHeight() const
         {
             SwAttrHandler aAttrHandler;
             aAttrHandler.Init(  GetTextNode()->GetSwAttrSet(),
-                               *GetTextNode()->getIDocumentSettingAccess(), nullptr );
+                               *GetTextNode()->getIDocumentSettingAccess() );
             SwRedlineItr aRedln( rTextNode, *pFnt, aAttrHandler,
                                  nRedlPos, true );
         }
diff --git a/sw/source/core/text/txtpaint.cxx b/sw/source/core/text/txtpaint.cxx
index 1d84ca5..8f1106f 100644
--- a/sw/source/core/text/txtpaint.cxx
+++ b/sw/source/core/text/txtpaint.cxx
@@ -98,7 +98,7 @@ void SwSaveClip::ChgClip_( const SwRect &rRect, const SwTextFrame* pFrame,
         static bool bDbg = false;
         if( bDbg )
         {
-            DbgBackColor aDbg( pOut, bDbg, COL_RED );
+            DbgBackColor aDbg( pOut, bDbg );
             pOut->DrawRect( aRect );
         }
 #endif
diff --git a/sw/source/core/text/txtpaint.hxx b/sw/source/core/text/txtpaint.hxx
index 8ef9a58..29435b1 100644
--- a/sw/source/core/text/txtpaint.hxx
+++ b/sw/source/core/text/txtpaint.hxx
@@ -68,8 +68,7 @@ class DbgBackColor : public SwDbgOut
 {
         Color   aOldFillColor;
 public:
-        DbgBackColor( OutputDevice* pOut, const bool bOn = true,
-                  ColorData nColor = COL_YELLOW );
+        DbgBackColor( OutputDevice* pOut, const bool bOn = true );
        ~DbgBackColor();
 };
 
@@ -85,14 +84,13 @@ inline SwDbgOut::SwDbgOut( OutputDevice* pOutDev, const bool bOn )
                :pOut( bOn ? pOutDev : nullptr )
 { }
 
-inline DbgBackColor::DbgBackColor( OutputDevice* pOutDev, const bool bOn,
-                           ColorData eColor )
+inline DbgBackColor::DbgBackColor( OutputDevice* pOutDev, const bool bOn )
     :SwDbgOut( pOutDev, bOn )
 {
     if( pOut )
     {
         aOldFillColor = pOut->GetFillColor();
-        pOut->SetFillColor( Color(eColor) );
+        pOut->SetFillColor( Color(COL_RED) );
     }
 }
 
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index 8b0c40a..d01a006 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -4919,7 +4919,7 @@ void SwTextNode::SwClientNotify( const SwModify& rModify, const SfxHint& rHint )
 {
     SwClient::SwClientNotify(rModify, rHint);
     const SwAttrHint* pHint = dynamic_cast<const SwAttrHint*>(&rHint);
-    if ( pHint && pHint->GetId() == RES_CONDTXTFMTCOLL && &rModify == GetRegisteredIn() )
+    if ( pHint && &rModify == GetRegisteredIn() )
         ChkCondColl();
 }
 
diff --git a/sw/source/core/undo/SwUndoField.cxx b/sw/source/core/undo/SwUndoField.cxx
index fc370c8..88ae5ac 100644
--- a/sw/source/core/undo/SwUndoField.cxx
+++ b/sw/source/core/undo/SwUndoField.cxx
@@ -57,8 +57,8 @@ SwPosition SwUndoField::GetPosition()
 SwUndoFieldFromDoc::SwUndoFieldFromDoc(const SwPosition & rPos,
                          const SwField & rOldField,
                          const SwField & rNewField,
-                         SwMsgPoolItem * _pHint, bool _bUpdate, SwUndoId _nId)
-    : SwUndoField(rPos,_nId)
+                         SwMsgPoolItem * _pHint, bool _bUpdate)
+    : SwUndoField(rPos,UNDO_FIELD)
     , pOldField(rOldField.CopyField())
     , pNewField(rNewField.CopyField())
     , pHint(_pHint)
diff --git a/sw/source/core/unocore/unocoll.cxx b/sw/source/core/unocore/unocoll.cxx
index 055e931..bc81e78 100644
--- a/sw/source/core/unocore/unocoll.cxx
+++ b/sw/source/core/unocore/unocoll.cxx
@@ -798,7 +798,7 @@ SwXServiceProvider::MakeInstance(SwServiceType nObjectType, SwDoc & rDoc)
             xRet = static_cast<cppu::OWeakObject*>(new SwXNumberingRules(rDoc));
         break;
         case SwServiceType::TextColumns :
-            xRet = static_cast<cppu::OWeakObject*>(new SwXTextColumns(0));
+            xRet = static_cast<cppu::OWeakObject*>(new SwXTextColumns);
         break;
         case SwServiceType::Defaults:
             xRet = static_cast<cppu::OWeakObject*>(new SwXTextDefaults(&rDoc));
diff --git a/sw/source/core/unocore/unocrsr.cxx b/sw/source/core/unocore/unocrsr.cxx
index 53d7284..5154590 100644
--- a/sw/source/core/unocore/unocrsr.cxx
+++ b/sw/source/core/unocore/unocrsr.cxx
@@ -29,8 +29,8 @@ sw::DocDisposingHint::~DocDisposingHint() {}
 
 IMPL_FIXEDMEMPOOL_NEWDEL( SwUnoCursor )
 
-SwUnoCursor::SwUnoCursor( const SwPosition &rPos, SwPaM* pRing )
-    : SwCursor( rPos, pRing )
+SwUnoCursor::SwUnoCursor( const SwPosition &rPos )
+    : SwCursor( rPos, nullptr )
     , SwModify(nullptr)
     , m_bRemainInSection(true)
     , m_bSkipOverHiddenSections(false)
diff --git a/sw/source/core/unocore/unoframe.cxx b/sw/source/core/unocore/unoframe.cxx
index 855d752..c3f27a9 100644
--- a/sw/source/core/unocore/unoframe.cxx
+++ b/sw/source/core/unocore/unoframe.cxx
@@ -2995,7 +2995,7 @@ void SwXFrame::attachToRange(const uno::Reference< text::XTextRange > & xTextRan
                 pDoc->GetIDocumentUndoRedo().StartUndo(UNDO_INSERT, nullptr);
 
                 SwFlyFrameFormat* pFrameFormat = nullptr;
-                pFrameFormat = pDoc->getIDocumentContentOperations().InsertOLE( aPam, sStreamName, embed::Aspects::MSOLE_CONTENT, &aFrameSet, nullptr, nullptr );
+                pFrameFormat = pDoc->getIDocumentContentOperations().InsertOLE( aPam, sStreamName, embed::Aspects::MSOLE_CONTENT, &aFrameSet, nullptr );
                 pDoc->GetIDocumentUndoRedo().EndUndo(UNDO_INSERT, nullptr);
                 pFrameFormat->Add(this);
                 if(!m_sName.isEmpty())
diff --git a/sw/source/core/unocore/unosett.cxx b/sw/source/core/unocore/unosett.cxx
index 40c7e39..b5a3b54 100644
--- a/sw/source/core/unocore/unosett.cxx
+++ b/sw/source/core/unocore/unosett.cxx
@@ -2318,7 +2318,7 @@ Sequence< OUString > SwXTextColumns::getSupportedServiceNames() throw( RuntimeEx
     return aRet;
 }
 
-SwXTextColumns::SwXTextColumns(sal_uInt16 nColCount) :
+SwXTextColumns::SwXTextColumns() :
     nReference(0),
     bIsAutomaticWidth(true),
     nAutoDistance(0),
@@ -2330,8 +2330,6 @@ SwXTextColumns::SwXTextColumns(sal_uInt16 nColCount) :
     bSepLineIsOn(false),
     nSepLineStyle(API_COL_LINE_NONE) // None
 {
-    if(nColCount)
-        setColumnCount(nColCount);
 }
 
 SwXTextColumns::SwXTextColumns(const SwFormatCol& rFormatCol) :
diff --git a/sw/source/filter/html/SwAppletImpl.cxx b/sw/source/filter/html/SwAppletImpl.cxx
index 7d6d9c8..bfeb6e8 100644
--- a/sw/source/filter/html/SwAppletImpl.cxx
+++ b/sw/source/filter/html/SwAppletImpl.cxx
@@ -27,6 +27,7 @@
 #include <comphelper/classids.hxx>
 #include <com/sun/star/uno/Any.hxx>
 #include <svtools/embedhlp.hxx>
+#include <hintids.hxx>
 
 using namespace com::sun::star;
 
@@ -105,8 +106,8 @@ SwHtmlOptType SwApplet_Impl::GetOptionType( const OUString& rName, bool bApplet
 
     return nType;
 }
-SwApplet_Impl::SwApplet_Impl( SfxItemPool& rPool, sal_uInt16 nWhich1, sal_uInt16 nWhich2 ) :
-        aItemSet( rPool, nWhich1, nWhich2 )
+SwApplet_Impl::SwApplet_Impl( SfxItemPool& rPool ) :
+        aItemSet( rPool, RES_FRMATR_BEGIN, RES_FRMATR_END-1 )
 {
 }
 
diff --git a/sw/source/filter/html/htmlplug.cxx b/sw/source/filter/html/htmlplug.cxx
index f5bde4e..d00f20c 100644
--- a/sw/source/filter/html/htmlplug.cxx
+++ b/sw/source/filter/html/htmlplug.cxx
@@ -500,8 +500,7 @@ void SwHTMLParser::NewObject()
              bDeclare = false;
     // Eine neue Command-List anlegen
     delete m_pAppletImpl;
-    m_pAppletImpl = new SwApplet_Impl( m_pDoc->GetAttrPool(),
-                                     RES_FRMATR_BEGIN, RES_FRMATR_END-1 );
+    m_pAppletImpl = new SwApplet_Impl( m_pDoc->GetAttrPool() );
 
     const HTMLOptions& rHTMLOptions = GetOptions();
     for (size_t i = rHTMLOptions.size(); i; )
@@ -671,7 +670,7 @@ void SwHTMLParser::InsertApplet()
 
     // Eine neue Command-List anlegen
     delete m_pAppletImpl;
-    m_pAppletImpl = new SwApplet_Impl( m_pDoc->GetAttrPool(), RES_FRMATR_BEGIN, RES_FRMATR_END-1 );
+    m_pAppletImpl = new SwApplet_Impl( m_pDoc->GetAttrPool() );
 
     const HTMLOptions& rHTMLOptions = GetOptions();
     for (size_t i = rHTMLOptions.size(); i; )
diff --git a/sw/source/filter/ww8/ww8par4.cxx b/sw/source/filter/ww8/ww8par4.cxx
index 4b68065..cbecacd 100644
--- a/sw/source/filter/ww8/ww8par4.cxx
+++ b/sw/source/filter/ww8/ww8par4.cxx
@@ -235,7 +235,7 @@ SwFlyFrameFormat* SwWW8ImplReader::InsertOle(SdrOle2Obj &rObject,
     if (bSuccess)
     {
         const SfxItemSet *pFlySet = pMathFlySet ? pMathFlySet : &rFlySet;
-        pRet = m_rDoc.getIDocumentContentOperations().InsertOLE(*m_pPaM, sNewName, rObject.GetAspect(), pFlySet, rGrfSet, nullptr);
+        pRet = m_rDoc.getIDocumentContentOperations().InsertOLE(*m_pPaM, sNewName, rObject.GetAspect(), pFlySet, rGrfSet);
     }
     delete pMathFlySet;
     return pRet;
diff --git a/sw/source/filter/xml/XMLRedlineImportHelper.cxx b/sw/source/filter/xml/XMLRedlineImportHelper.cxx
index e24fe06..1e35bf7 100644
--- a/sw/source/filter/xml/XMLRedlineImportHelper.cxx
+++ b/sw/source/filter/xml/XMLRedlineImportHelper.cxx
@@ -715,8 +715,7 @@ SwRedlineData* XMLRedlineImportHelper::ConvertRedline(
     SwRedlineData* pData = new SwRedlineData(pRedlineInfo->eType,
                                              nAuthorId, aDT,
                                              pRedlineInfo->sComment,
-                                             pNext, // next data (if available)
-                                             nullptr); // no extra data
+                                             pNext); // next data (if available)
 
     return pData;
 }
diff --git a/sw/source/filter/xml/xmltexti.cxx b/sw/source/filter/xml/xmltexti.cxx
index 1fc18b2..b83ef45 100644
--- a/sw/source/filter/xml/xmltexti.cxx
+++ b/sw/source/filter/xml/xmltexti.cxx
@@ -347,7 +347,7 @@ uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertOLEObject(
         // TODO/LATER: Actually it should be set here
         if( pTextCursor )
         {
-            pFrameFormat = pDoc->getIDocumentContentOperations().InsertOLE( *pTextCursor->GetPaM(), aName, embed::Aspects::MSOLE_CONTENT, &aItemSet, nullptr, nullptr );
+            pFrameFormat = pDoc->getIDocumentContentOperations().InsertOLE( *pTextCursor->GetPaM(), aName, embed::Aspects::MSOLE_CONTENT, &aItemSet, nullptr );
             pOLENd = lcl_GetOLENode( pFrameFormat );
         }
         aObjName = aName;
diff --git a/sw/source/ui/dialog/swdlgfact.cxx b/sw/source/ui/dialog/swdlgfact.cxx
index f3f71dd..ddc6e0e 100644
--- a/sw/source/ui/dialog/swdlgfact.cxx
+++ b/sw/source/ui/dialog/swdlgfact.cxx
@@ -674,23 +674,10 @@ AbstractSwAsciiFilterDlg* SwAbstractDialogFactory_Impl::CreateSwAsciiFilterDlg(
 
 VclAbstractDialog* SwAbstractDialogFactory_Impl::CreateSwInsertBookmarkDlg( vcl::Window *pParent,
                                                                            SwWrtShell &rSh,
-                                                                           SfxRequest& rReq,
-                                                                           int nResId )
+                                                                           SfxRequest& rReq )
 {
-    Dialog* pDlg=nullptr;
-    switch ( nResId )
-    {
-        case DLG_INSERT_BOOKMARK :
-            pDlg = VclPtr<SwInsertBookmarkDlg>::Create( pParent, rSh, rReq );
-            break;
-
-        default:
-            break;
-    }
-
-    if ( pDlg )
-        return new VclAbstractDialog_Impl( pDlg );
-    return nullptr;
+    VclPtr<SwInsertBookmarkDlg> pDlg = VclPtr<SwInsertBookmarkDlg>::Create( pParent, rSh, rReq );
+    return new VclAbstractDialog_Impl( pDlg );
 }
 
 AbstractSwBreakDlg * SwAbstractDialogFactory_Impl::CreateSwBreakDlg(vcl::Window *pParent,
@@ -719,22 +706,10 @@ AbstractSwConvertTableDlg* SwAbstractDialogFactory_Impl::CreateSwConvertTableDlg
     return new AbstractSwConvertTableDlg_Impl(pDlg);
 }
 
-VclAbstractDialog * SwAbstractDialogFactory_Impl::CreateSwCaptionDialog ( vcl::Window *pParent, SwView &rV,int nResId)
+VclAbstractDialog * SwAbstractDialogFactory_Impl::CreateSwCaptionDialog ( vcl::Window *pParent, SwView &rV)
 {
-    VclPtr<Dialog> pDlg;
-    switch ( nResId )
-    {
-        case DLG_CAPTION :
-            pDlg = VclPtr<SwCaptionDialog>::Create( pParent, rV );
-            break;
-
-        default:
-            break;
-    }
-
-    if ( pDlg.get() )
-        return new VclAbstractDialog_Impl( pDlg );
-    return nullptr;
+    VclPtr<Dialog> pDlg = VclPtr<SwCaptionDialog>::Create( pParent, rV );
+    return new VclAbstractDialog_Impl( pDlg );
 }
 
 AbstractSwInsertDBColAutoPilot* SwAbstractDialogFactory_Impl::CreateSwInsertDBColAutoPilot( SwView& rView,
@@ -781,11 +756,10 @@ SwLabDlgMethod SwAbstractDialogFactory_Impl::GetSwLabDlgStaticMethod ()
 
 SfxAbstractTabDialog* SwAbstractDialogFactory_Impl::CreateSwParaDlg ( vcl::Window *pParent, SwView& rVw,
                                                     const SfxItemSet& rCoreSet  ,
-                                                    const OUString *pCollName,
                                                     bool bDraw ,
                                                     const OString& sDefPage)
 {
-    VclPtr<SfxTabDialog> pDlg = VclPtr<SwParaDlg>::Create( pParent, rVw, rCoreSet, DLG_STD, pCollName, bDraw, sDefPage );
+    VclPtr<SfxTabDialog> pDlg = VclPtr<SwParaDlg>::Create( pParent, rVw, rCoreSet, DLG_STD, nullptr, bDraw, sDefPage );
     return new AbstractTabDialog_Impl( pDlg );
 }
 
@@ -833,38 +807,16 @@ AbstractSwAutoFormatDlg * SwAbstractDialogFactory_Impl::CreateSwAutoFormatDlg(vc
     return new AbstractSwAutoFormatDlg_Impl(pDlg);
 }
 
-SfxAbstractDialog * SwAbstractDialogFactory_Impl::CreateSwBorderDlg(vcl::Window* pParent, SfxItemSet& rSet, SwBorderModes nType, int nResId )
+SfxAbstractDialog * SwAbstractDialogFactory_Impl::CreateSwBorderDlg(vcl::Window* pParent, SfxItemSet& rSet, SwBorderModes nType )
 {
-    VclPtr<SfxModalDialog> pDlg;
-    switch ( nResId )
-    {
-        case RC_DLG_SWBORDERDLG :
-            pDlg = VclPtr<SwBorderDlg>::Create( pParent, rSet, nType );
-            break;
-        default:
-            break;
-    }
-
-    if ( pDlg.get() )
-        return new SwAbstractSfxDialog_Impl( pDlg );
-    return nullptr;
+    VclPtr<SfxModalDialog> pDlg = VclPtr<SwBorderDlg>::Create( pParent, rSet, nType );
+    return new SwAbstractSfxDialog_Impl( pDlg );
 }
 
-SfxAbstractDialog* SwAbstractDialogFactory_Impl::CreateSwWrapDlg ( vcl::Window* pParent, SfxItemSet& rSet, SwWrtShell* pSh, int nResId )
+SfxAbstractDialog* SwAbstractDialogFactory_Impl::CreateSwWrapDlg ( vcl::Window* pParent, SfxItemSet& rSet, SwWrtShell* pSh )
 {
-    VclPtr<SfxModalDialog> pDlg;
-    switch ( nResId )
-    {
-        case RC_DLG_SWWRAPDLG :
-            pDlg = VclPtr<SwWrapDlg>::Create( pParent, rSet, pSh, true/*bDrawMode*/ );
-            break;
-        default:
-            break;
-    }
-
-    if ( pDlg.get() )
-        return new SwAbstractSfxDialog_Impl( pDlg );
-    return nullptr;
+    VclPtr<SfxModalDialog> pDlg = VclPtr<SwWrapDlg>::Create( pParent, rSet, pSh, true/*bDrawMode*/ );
+    return new SwAbstractSfxDialog_Impl( pDlg );
 }
 
 VclAbstractDialog * SwAbstractDialogFactory_Impl::CreateSwTableWidthDlg(vcl::Window *pParent, SwTableFUNC &rFnc)
@@ -886,21 +838,10 @@ AbstractSwFieldDlg * SwAbstractDialogFactory_Impl::CreateSwFieldDlg(SfxBindings*
     return new AbstractSwFieldDlg_Impl(pDlg);
 }
 
-SfxAbstractDialog*   SwAbstractDialogFactory_Impl::CreateSwFieldEditDlg ( SwView& rVw, int nResId )
+SfxAbstractDialog*   SwAbstractDialogFactory_Impl::CreateSwFieldEditDlg ( SwView& rVw )
 {
-    VclPtr<SfxModalDialog> pDlg;
-    switch ( nResId )
-    {
-        case RC_DLG_SWFLDEDITDLG :
-            pDlg = VclPtr<SwFieldEditDlg>::Create( rVw );
-            break;
-        default:
-            break;
-    }
-
-    if ( pDlg.get() )
-        return new SwAbstractSfxDialog_Impl( pDlg );
-    return nullptr;
+    VclPtr<SfxModalDialog> pDlg = VclPtr<SwFieldEditDlg>::Create( rVw );
+    return new SwAbstractSfxDialog_Impl( pDlg );
 }
 
 AbstractSwRenameXNamedDlg * SwAbstractDialogFactory_Impl::CreateSwRenameXNamedDlg(vcl::Window* pParent,
@@ -927,10 +868,9 @@ SfxAbstractTabDialog* SwAbstractDialogFactory_Impl::CreateFrameTabDialog(const O
                                                 SfxViewFrame *pFrame, vcl::Window *pParent,
                                                 const SfxItemSet& rCoreSet,
                                                 bool        bNewFrame,
-                                                const OString&  sDefPage,
-                                                const OUString* pFormatStr )
+                                                const OString&  sDefPage )
 {
-    VclPtr<SfxTabDialog> pDlg = VclPtr<SwFrameDlg>::Create(pFrame, pParent, rCoreSet, bNewFrame, rDialogType, false/*bFormat*/, sDefPage, pFormatStr);
+    VclPtr<SfxTabDialog> pDlg = VclPtr<SwFrameDlg>::Create(pFrame, pParent, rCoreSet, bNewFrame, rDialogType, false/*bFormat*/, sDefPage, nullptr);
     return new AbstractTabDialog_Impl(pDlg);
 }
 
@@ -993,25 +933,15 @@ AbstractJavaEditDialog * SwAbstractDialogFactory_Impl::CreateJavaEditDialog(
     return new AbstractJavaEditDialog_Impl( pDlg );
 }
 
-AbstractMailMergeDlg * SwAbstractDialogFactory_Impl::CreateMailMergeDlg( int nResId,
+AbstractMailMergeDlg * SwAbstractDialogFactory_Impl::CreateMailMergeDlg(
                                                 vcl::Window* pParent, SwWrtShell& rSh,
                                                 const OUString& rSourceName,
                                                 const OUString& rTableName,
                                                 sal_Int32 nCommandType,
                                                 const uno::Reference< sdbc::XConnection>& xConnection )
 {
-    VclPtr<SwMailMergeDlg> pDlg;
-    switch ( nResId )
-    {
-        case DLG_MAILMERGE :
-            pDlg = VclPtr<SwMailMergeDlg>::Create( pParent, rSh, rSourceName, rTableName, nCommandType, xConnection, nullptr );
-            break;
-        default:
-            break;
-    }
-    if ( pDlg.get() )
-        return new AbstractMailMergeDlg_Impl( pDlg );
-    return nullptr;
+    VclPtr<SwMailMergeDlg> pDlg = VclPtr<SwMailMergeDlg>::Create( pParent, rSh, rSourceName, rTableName, nCommandType, xConnection, nullptr );
+    return new AbstractMailMergeDlg_Impl( pDlg );
 }
 
 AbstractMailMergeCreateFromDlg * SwAbstractDialogFactory_Impl::CreateMailMergeCreateFromDlg(vcl::Window* pParent)
@@ -1058,10 +988,10 @@ SfxAbstractTabDialog* SwAbstractDialogFactory_Impl::CreateSwTabDialog( int nResI
 AbstractMultiTOXTabDialog * SwAbstractDialogFactory_Impl::CreateMultiTOXTabDialog(
                                                 vcl::Window* pParent, const SfxItemSet& rSet,
                                                 SwWrtShell &rShell,
-                                                SwTOXBase* pCurTOX, sal_uInt16 nToxType,
+                                                SwTOXBase* pCurTOX,
                                                 bool bGlobal)
 {
-    VclPtr<SwMultiTOXTabDialog> pDlg = VclPtr<SwMultiTOXTabDialog>::Create( pParent, rSet, rShell, pCurTOX, nToxType, bGlobal );
+    VclPtr<SwMultiTOXTabDialog> pDlg = VclPtr<SwMultiTOXTabDialog>::Create( pParent, rSet, rShell, pCurTOX, USHRT_MAX, bGlobal );
     return new AbstractMultiTOXTabDialog_Impl( pDlg );
 }
 
diff --git a/sw/source/ui/dialog/swdlgfact.hxx b/sw/source/ui/dialog/swdlgfact.hxx
index 49baf29..6110e98 100644
--- a/sw/source/ui/dialog/swdlgfact.hxx
+++ b/sw/source/ui/dialog/swdlgfact.hxx
@@ -378,13 +378,13 @@ public:
     virtual AbstractSwInsertAbstractDlg * CreateSwInsertAbstractDlg() override;
     virtual AbstractSwAsciiFilterDlg*  CreateSwAsciiFilterDlg ( SwDocShell& rDocSh,
                                                                 SvStream* pStream ) override;
-    virtual VclAbstractDialog * CreateSwInsertBookmarkDlg( vcl::Window *pParent, SwWrtShell &rSh, SfxRequest& rReq, int nResId ) override;
+    virtual VclAbstractDialog * CreateSwInsertBookmarkDlg( vcl::Window *pParent, SwWrtShell &rSh, SfxRequest& rReq ) override;
     virtual AbstractSwBreakDlg * CreateSwBreakDlg(vcl::Window *pParent, SwWrtShell &rSh) override;
     virtual VclAbstractDialog   * CreateSwChangeDBDlg(SwView& rVw) override;
     virtual SfxAbstractTabDialog *  CreateSwCharDlg(vcl::Window* pParent, SwView& pVw, const SfxItemSet& rCoreSet,
         SwCharDlgMode nDialogMode, const OUString* pFormatStr = nullptr) override;
     virtual AbstractSwConvertTableDlg* CreateSwConvertTableDlg(SwView& rView, bool bToTable) override;
-    virtual VclAbstractDialog * CreateSwCaptionDialog ( vcl::Window *pParent, SwView &rV,int nResId) override;
+    virtual VclAbstractDialog * CreateSwCaptionDialog ( vcl::Window *pParent, SwView &rV) override;
 
     virtual AbstractSwInsertDBColAutoPilot* CreateSwInsertDBColAutoPilot(SwView& rView,
         css::uno::Reference< css::sdbc::XDataSource> rxSource,
@@ -402,7 +402,6 @@ public:
     virtual SfxAbstractTabDialog* CreateSwParaDlg ( vcl::Window *pParent,
                                                     SwView& rVw,
                                                     const SfxItemSet& rCoreSet,
-                                                    const OUString *pCollName,
                                                     bool bDraw,
                                                     const OString& sDefPage = OString() ) override;
 
@@ -413,14 +412,14 @@ public:
     virtual AbstractSwAutoFormatDlg * CreateSwAutoFormatDlg( vcl::Window* pParent, SwWrtShell* pShell,
                                                             bool bSetAutoFormat = true,
                                                             const SwTableAutoFormat* pSelFormat = nullptr ) override;
-    virtual SfxAbstractDialog * CreateSwBorderDlg (vcl::Window* pParent, SfxItemSet& rSet, SwBorderModes nType, int nResId ) override;
+    virtual SfxAbstractDialog * CreateSwBorderDlg (vcl::Window* pParent, SfxItemSet& rSet, SwBorderModes nType ) override;
 
-    virtual SfxAbstractDialog * CreateSwWrapDlg ( vcl::Window* pParent, SfxItemSet& rSet, SwWrtShell* pSh, int nResId ) override;
+    virtual SfxAbstractDialog * CreateSwWrapDlg ( vcl::Window* pParent, SfxItemSet& rSet, SwWrtShell* pSh ) override;
     virtual VclAbstractDialog * CreateSwTableWidthDlg(vcl::Window *pParent, SwTableFUNC &rFnc) override;
     virtual SfxAbstractTabDialog* CreateSwTableTabDlg(vcl::Window* pParent, SfxItemPool& Pool,
         const SfxItemSet* pItemSet, SwWrtShell* pSh) override;
     virtual AbstractSwFieldDlg * CreateSwFieldDlg(SfxBindings* pB, SwChildWinWrapper* pCW, vcl::Window *pParent) override;
-    virtual SfxAbstractDialog*   CreateSwFieldEditDlg ( SwView& rVw, int nResId ) override;
+    virtual SfxAbstractDialog*   CreateSwFieldEditDlg ( SwView& rVw ) override;
     virtual AbstractSwRenameXNamedDlg * CreateSwRenameXNamedDlg(vcl::Window* pParent,
         css::uno::Reference< css::container::XNamed > & xNamed,
         css::uno::Reference< css::container::XNameAccess > & xNameAccess) override;
@@ -431,8 +430,7 @@ public:
                                                 SfxViewFrame *pFrame, vcl::Window *pParent,
                                                 const SfxItemSet& rCoreSet,
                                                 bool bNewFrame  = true,
-                                                const OString& sDefPage = OString(),
-                                                const OUString*   pFormatStr  = nullptr) override;
+                                                const OString& sDefPage = OString()) override;
     virtual SfxAbstractApplyTabDialog*  CreateTemplateDialog(
                                                 vcl::Window *pParent,
                                                 SfxStyleSheetBase&  rBase,
@@ -452,7 +450,7 @@ public:
     virtual AbstractInsTableDlg*        CreateInsTableDlg(SwView& rView) override;
     virtual AbstractJavaEditDialog*     CreateJavaEditDialog(vcl::Window* pParent,
         SwWrtShell* pWrtSh) override;
-    virtual AbstractMailMergeDlg*       CreateMailMergeDlg( int nResId,
+    virtual AbstractMailMergeDlg*       CreateMailMergeDlg(
                                                 vcl::Window* pParent, SwWrtShell& rSh,
                                                 const OUString& rSourceName,
                                                 const OUString& rTableName,
@@ -468,7 +466,7 @@ public:
     virtual AbstractMultiTOXTabDialog*      CreateMultiTOXTabDialog(
                                                 vcl::Window* pParent, const SfxItemSet& rSet,
                                                 SwWrtShell &rShell,
-                                                SwTOXBase* pCurTOX, sal_uInt16 nToxType,
+                                                SwTOXBase* pCurTOX,
                                                 bool bGlobal) override;
     virtual AbstractEditRegionDlg*      CreateEditRegionDlg(vcl::Window* pParent, SwWrtShell& rWrtSh) override;
     virtual AbstractInsertSectionTabDialog*     CreateInsertSectionTabDialog(
diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx
index f906c55..14437bf 100644
--- a/sw/source/uibase/dbui/dbmgr.cxx
+++ b/sw/source/uibase/dbui/dbmgr.cxx
@@ -2825,12 +2825,11 @@ void SwDBManager::ExecuteFormLetter( SwWrtShell& rSh,
     }
     SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
     assert( pFact && "Factory creation failed!" );
-    pImpl->pMergeDialog = pFact->CreateMailMergeDlg( DLG_MAILMERGE,
-                                                        &rSh.GetView().GetViewFrame()->GetWindow(), rSh,
-                                                        sDataSource,
-                                                        sDataTableOrQuery,
-                                                        nCmdType,
-                                                        xConnection);
+    pImpl->pMergeDialog = pFact->CreateMailMergeDlg( &rSh.GetView().GetViewFrame()->GetWindow(), rSh,
+                                                     sDataSource,
+                                                     sDataTableOrQuery,
+                                                     nCmdType,
+                                                     xConnection);
     assert( pImpl->pMergeDialog && "Dialog creation failed!" );
     if(pImpl->pMergeDialog->Execute() == RET_OK)
     {
diff --git a/sw/source/uibase/docvw/PostItMgr.cxx b/sw/source/uibase/docvw/PostItMgr.cxx
index ee5a8ba..1eed1df 100644
--- a/sw/source/uibase/docvw/PostItMgr.cxx
+++ b/sw/source/uibase/docvw/PostItMgr.cxx
@@ -649,7 +649,6 @@ void SwPostItMgr::LayoutPostIts()
                         if (!pPostIt)
                         {
                             pPostIt = (*i)->GetSidebarWindow( mpView->GetEditWin(),
-                                                              WB_DIALOGCONTROL,
                                                               *this );
                             pPostIt->InitControls();
                             pPostIt->SetReadonly(mbReadOnly);
diff --git a/sw/source/uibase/misc/glshell.cxx b/sw/source/uibase/misc/glshell.cxx
index 9b05cb5..6446f61 100644
--- a/sw/source/uibase/misc/glshell.cxx
+++ b/sw/source/uibase/misc/glshell.cxx
@@ -167,7 +167,7 @@ bool SwGlosDocShell::Save()
 }
 
 SwWebGlosDocShell::SwWebGlosDocShell()
-    : SwWebDocShell( SfxObjectCreateMode::STANDARD )
+    : SwWebDocShell()
 {
     SetHelpId(SW_WEBGLOSDOCSHELL);
 }
diff --git a/sw/source/uibase/shells/annotsh.cxx b/sw/source/uibase/shells/annotsh.cxx
index 0988389..18d60f2d 100644
--- a/sw/source/uibase/shells/annotsh.cxx
+++ b/sw/source/uibase/shells/annotsh.cxx
@@ -544,7 +544,7 @@ void SwAnnotationShell::Exec( SfxRequest &rReq )
                 SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
                 OSL_ENSURE(pFact, "SwAbstractDialogFactory fail!");
 
-                std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateSwParaDlg( rView.GetWindow(), rView, aDlgAttr, nullptr, true ));
+                std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateSwParaDlg( rView.GetWindow(), rView, aDlgAttr, true ));
                 OSL_ENSURE(pDlg, "Dialog creation failed!");
                 sal_uInt16 nRet = pDlg->Execute();
                 if(RET_OK == nRet)
diff --git a/sw/source/uibase/shells/basesh.cxx b/sw/source/uibase/shells/basesh.cxx
index 3293dae..3bb4368 100644
--- a/sw/source/uibase/shells/basesh.cxx
+++ b/sw/source/uibase/shells/basesh.cxx
@@ -2445,7 +2445,7 @@ void SwBaseShell::ExecDlg(SfxRequest &rReq)
                 SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
                 OSL_ENSURE(pFact, "SwAbstractDialogFactory fail!");
 
-                pDlg.reset(pFact->CreateSwBorderDlg( pMDI, aSet, SwBorderModes::TABLE, RC_DLG_SWBORDERDLG ));
+                pDlg.reset(pFact->CreateSwBorderDlg( pMDI, aSet, SwBorderModes::TABLE ));
                 OSL_ENSURE(pDlg, "Dialog creation failed!");
                 if ( pDlg->Execute() == RET_OK )
                 {
@@ -2462,7 +2462,7 @@ void SwBaseShell::ExecDlg(SfxRequest &rReq)
                 SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
                 OSL_ENSURE(pFact, "SwAbstractDialogFactory fail!");
 
-                pDlg.reset(pFact->CreateSwBorderDlg( pMDI, aSet, SwBorderModes::FRAME, RC_DLG_SWBORDERDLG ));
+                pDlg.reset(pFact->CreateSwBorderDlg( pMDI, aSet, SwBorderModes::FRAME ));
                 OSL_ENSURE(pDlg, "Dialog creation failed!");
                 if ( pDlg->Execute() == RET_OK )
                 {
@@ -2480,7 +2480,7 @@ void SwBaseShell::ExecDlg(SfxRequest &rReq)
                 SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
                 OSL_ENSURE(pFact, "SwAbstractDialogFactory fail!");
 
-                pDlg.reset(pFact->CreateSwBorderDlg( pMDI, aSet, SwBorderModes::PARA, RC_DLG_SWBORDERDLG ));
+                pDlg.reset(pFact->CreateSwBorderDlg( pMDI, aSet, SwBorderModes::PARA ));
                 OSL_ENSURE(pDlg, "Dialog creation failed!");
                 if ( pDlg->Execute() == RET_OK )
                 {
diff --git a/sw/source/uibase/shells/drwbassh.cxx b/sw/source/uibase/shells/drwbassh.cxx
index 141a757..ab0c55b 100644
--- a/sw/source/uibase/shells/drwbassh.cxx
+++ b/sw/source/uibase/shells/drwbassh.cxx
@@ -148,7 +148,7 @@ void SwDrawBaseShell::Execute(SfxRequest &rReq)
                         SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
                         OSL_ENSURE(pFact, "SwAbstractDialogFactory fail!");
 
-                        std::unique_ptr<SfxAbstractDialog> pDlg(pFact->CreateSwWrapDlg( GetView().GetWindow(), aSet, pSh, RC_DLG_SWWRAPDLG ));
+                        std::unique_ptr<SfxAbstractDialog> pDlg(pFact->CreateSwWrapDlg( GetView().GetWindow(), aSet, pSh ));
                         OSL_ENSURE(pDlg, "Dialog creation failed!");
 
                         if (pDlg->Execute() == RET_OK)
diff --git a/sw/source/uibase/shells/drwtxtex.cxx b/sw/source/uibase/shells/drwtxtex.cxx
index 08a2ea2..8ff6fea 100644
--- a/sw/source/uibase/shells/drwtxtex.cxx
+++ b/sw/source/uibase/shells/drwtxtex.cxx
@@ -422,7 +422,7 @@ void SwDrawTextShell::Execute( SfxRequest &rReq )
                 SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
                 assert(pFact && "SwAbstractDialogFactory fail!");
 
-                std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateSwParaDlg( GetView().GetWindow(), GetView(), aDlgAttr, nullptr, true ));
+                std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateSwParaDlg( GetView().GetWindow(), GetView(), aDlgAttr, true ));
                 assert(pDlg && "Dialog creation failed!");
                 sal_uInt16 nRet = pDlg->Execute();
                 if(RET_OK == nRet)
diff --git a/sw/source/uibase/shells/textfld.cxx b/sw/source/uibase/shells/textfld.cxx
index 1ac6ad5..c6d580c 100644
--- a/sw/source/uibase/shells/textfld.cxx
+++ b/sw/source/uibase/shells/textfld.cxx
@@ -152,7 +152,7 @@ void SwTextShell::ExecField(SfxRequest &rReq)
                         SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
                         assert(pFact && "SwAbstractDialogFactory fail!");
 
-                        std::unique_ptr<SfxAbstractDialog> pDlg(pFact->CreateSwFieldEditDlg( GetView(),RC_DLG_SWFLDEDITDLG ));
+                        std::unique_ptr<SfxAbstractDialog> pDlg(pFact->CreateSwFieldEditDlg( GetView() ));
                         assert(pDlg && "Dialog creation failed!");
                         pDlg->Execute();
                     }
diff --git a/sw/source/uibase/shells/textidx.cxx b/sw/source/uibase/shells/textidx.cxx
index 851227b..5b7d55a 100644
--- a/sw/source/uibase/shells/textidx.cxx
+++ b/sw/source/uibase/shells/textidx.cxx
@@ -140,7 +140,7 @@ void SwTextShell::ExecIdx(SfxRequest &rReq)
             OSL_ENSURE(pFact, "Dialog creation failed!");
             std::unique_ptr<AbstractMultiTOXTabDialog> pDlg(pFact->CreateMultiTOXTabDialog(
                                                         pMDI, aSet, rSh, const_cast<SwTOXBase*>(pCurTOX),
-                                                        USHRT_MAX, bGlobal));
+                                                        bGlobal));
             OSL_ENSURE(pDlg, "Dialog creation failed!");
             pDlg->Execute();
         }
diff --git a/sw/source/uibase/shells/textsh1.cxx b/sw/source/uibase/shells/textsh1.cxx
index ac19555..e48facd 100644
--- a/sw/source/uibase/shells/textsh1.cxx
+++ b/sw/source/uibase/shells/textsh1.cxx
@@ -626,7 +626,7 @@ void SwTextShell::Execute(SfxRequest &rReq)
                 SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
                 OSL_ENSURE(pFact, "SwAbstractDialogFactory fail!");
 
-                std::unique_ptr<VclAbstractDialog> pDlg(pFact->CreateSwInsertBookmarkDlg( GetView().GetWindow(), rWrtSh, rReq, DLG_INSERT_BOOKMARK ));
+                std::unique_ptr<VclAbstractDialog> pDlg(pFact->CreateSwInsertBookmarkDlg( GetView().GetWindow(), rWrtSh, rReq ));
                 OSL_ENSURE(pDlg, "Dialog creation failed!");
                 pDlg->Execute();
             }
@@ -1004,7 +1004,7 @@ void SwTextShell::Execute(SfxRequest &rReq)
                 SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
                 OSL_ENSURE(pFact, "SwAbstractDialogFactory fail!");
 
-                pDlg.reset(pFact->CreateSwParaDlg( GetView().GetWindow(),GetView(), aCoreSet, nullptr, false, sDefPage ));
+                pDlg.reset(pFact->CreateSwParaDlg( GetView().GetWindow(),GetView(), aCoreSet, false, sDefPage ));
                 OSL_ENSURE(pDlg, "Dialog creation failed!");
             }
             SfxItemSet* pSet = nullptr;
diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx
index 413ec54..366641a 100644
--- a/sw/source/uibase/uiview/view2.cxx
+++ b/sw/source/uibase/uiview/view2.cxx
@@ -216,23 +216,17 @@ OUString SwView::GetPageStr(sal_uInt16 nPhyNum, sal_uInt16 nVirtNum, const OUStr
 }
 
 int SwView::InsertGraphic( const OUString &rPath, const OUString &rFilter,
-                                bool bLink, GraphicFilter *pFilter,
-                                Graphic* pPreviewGrf )
+                                bool bLink, GraphicFilter *pFilter )
 {
     SwWait aWait( *GetDocShell(), true );
 
     Graphic aGraphic;
     int aResult = GRFILTER_OK;
-    if ( pPreviewGrf )
-        aGraphic = *pPreviewGrf;
-    else
+    if( !pFilter )
     {
-        if( !pFilter )
-        {
-            pFilter = &GraphicFilter::GetGraphicFilter();
-        }
-        aResult = GraphicFilter::LoadGraphic( rPath, rFilter, aGraphic, pFilter );
+        pFilter = &GraphicFilter::GetGraphicFilter();
     }
+    aResult = GraphicFilter::LoadGraphic( rPath, rFilter, aGraphic, pFilter );
 
     if( GRFILTER_OK == aResult )
     {
diff --git a/sw/source/uibase/uiview/viewdlg2.cxx b/sw/source/uibase/uiview/viewdlg2.cxx
index e1797bb..5453032 100644
--- a/sw/source/uibase/uiview/viewdlg2.cxx
+++ b/sw/source/uibase/uiview/viewdlg2.cxx
@@ -54,7 +54,7 @@ void SwView::ExecDlgExt(SfxRequest &rReq)
             SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
             assert(pFact && "SwAbstractDialogFactory fail!");
 
-            std::unique_ptr<VclAbstractDialog> pDialog(pFact->CreateSwCaptionDialog( pMDI, *this, DLG_CAPTION ));
+            std::unique_ptr<VclAbstractDialog> pDialog(pFact->CreateSwCaptionDialog( pMDI, *this ));
             assert(pDialog && "Dialog creation failed!");
             if ( pDialog )
             {
diff --git a/sw/source/uibase/uno/unodoc.cxx b/sw/source/uibase/uno/unodoc.cxx
index aded8e9..929ebcc 100644
--- a/sw/source/uibase/uno/unodoc.cxx
+++ b/sw/source/uibase/uno/unodoc.cxx
@@ -60,7 +60,7 @@ com_sun_star_comp_Writer_WebDocument_get_implementation(css::uno::XComponentCont
 {
     SolarMutexGuard aGuard;
     SwGlobals::ensure();
-    SfxObjectShell* pShell = new SwWebDocShell( SfxObjectCreateMode::STANDARD );
+    SfxObjectShell* pShell = new SwWebDocShell;
     uno::Reference< uno::XInterface > model( pShell->GetModel() );
     model->acquire();
     return model.get();
diff --git a/sw/source/uibase/utlui/glbltree.cxx b/sw/source/uibase/utlui/glbltree.cxx
index 71a8dd5..1a0a5a2 100644
--- a/sw/source/uibase/utlui/glbltree.cxx
+++ b/sw/source/uibase/utlui/glbltree.cxx
@@ -894,7 +894,6 @@ void    SwGlobalTree::ExecuteContextMenuAction( sal_uInt16 nSelectedPopupEntry )
                                                         this, aSet,
                                                         *pActiveShell,
                                                         nullptr,
-                                                        USHRT_MAX,
                                                         true));
                 assert(pDlg && "Dialog creation failed!");
                 if(RET_OK == pDlg->Execute())
diff --git a/sw/source/uibase/web/wdocsh.cxx b/sw/source/uibase/web/wdocsh.cxx
index 8cca32f..dfccc65e 100644
--- a/sw/source/uibase/web/wdocsh.cxx
+++ b/sw/source/uibase/web/wdocsh.cxx
@@ -50,8 +50,8 @@ void SwWebDocShell::InitInterface_Impl()
 
 SFX_IMPL_OBJECTFACTORY(SwWebDocShell, SvGlobalName(SO3_SWWEB_CLASSID), SfxObjectShellFlags::STD_NORMAL|SfxObjectShellFlags::HASMENU, "swriter/web" )
 
-SwWebDocShell::SwWebDocShell(SfxObjectCreateMode const eMode)
-    : SwDocShell(eMode)
+SwWebDocShell::SwWebDocShell()
+    : SwDocShell(SfxObjectCreateMode::STANDARD)
     , m_nSourcePara(0)
 {
 }
commit 847e004e65ec3c35acff607588d15cd75a84f121
Author: Noel Grandin <noel at peralex.com>
Date:   Wed Sep 7 13:10:40 2016 +0200

    convert nsRedlineMode_t to typed_flags
    
    including fixing a bug in SwXMLExport::exportDoc where it was ORing with
    a constant from a different type: nsRedlineType_t::REDLINE_INSERT
    
    Change-Id: I2bb154c9a35d106e64fd1a8b6e928d0384c9fafe

diff --git a/sw/inc/IDocumentRedlineAccess.hxx b/sw/inc/IDocumentRedlineAccess.hxx
index 1a7d580..757394d 100644
--- a/sw/inc/IDocumentRedlineAccess.hxx
+++ b/sw/inc/IDocumentRedlineAccess.hxx
@@ -26,6 +26,7 @@
 #include <limits.h>
 
 #include <com/sun/star/uno/Sequence.hxx>
+#include <o3tl/typed_flags_set.hxx>
 
 class SwRangeRedline;
 class SwTableRowRedline;
@@ -37,25 +38,28 @@ struct SwPosition;
 class SwStartNode;
 class SwNode;
 
-typedef sal_uInt16 RedlineMode_t;
-namespace nsRedlineMode_t
+enum class RedlineFlags
 {
-    const RedlineMode_t REDLINE_NONE = 0; ///< no RedlineMode
-    const RedlineMode_t REDLINE_ON = 0x01;///< RedlineMode on
-    const RedlineMode_t REDLINE_IGNORE = 0x02;///< ignore Redlines
-    const RedlineMode_t REDLINE_SHOW_INSERT = 0x10;///< show all inserts
-    const RedlineMode_t REDLINE_SHOW_DELETE = 0x20;///< show all deletes
-    const RedlineMode_t REDLINE_SHOW_MASK = REDLINE_SHOW_INSERT | REDLINE_SHOW_DELETE;
+    NONE                 = 0x000, ///< no RedlineFlags
+    On                   = 0x001, ///< RedlineFlags on
+    Ignore               = 0x002, ///< ignore Redlines
+    ShowInsert           = 0x010, ///< show all inserts
+    ShowDelete           = 0x020, ///< show all deletes
+    ShowMask             = ShowInsert | ShowDelete,
 
     // For internal management:
     // remove the original Redlines together with their content
     // (Clipboard/text modules).
-    const RedlineMode_t REDLINE_DELETE_REDLINES = 0x100;
+    DeleteRedlines       = 0x100,
     // When deleting within a RedlineObject
     // ignore the DeleteRedline during Append.
-    const RedlineMode_t REDLINE_IGNOREDELETE_REDLINES = 0x200;
+    IgnoreDeleteRedlines = 0x200,
     // don't combine any redlines. This flag may be only used in Undo.
-    const RedlineMode_t REDLINE_DONTCOMBINE_REDLINES = 0x400;
+    DontCombineRedlines  = 0x400,
+};
+namespace o3tl
+{
+    template<> struct typed_flags<RedlineFlags> : is_typed_flags<RedlineFlags, 0x733> {};
 }
 
 typedef sal_uInt16 RedlineType_t;
@@ -82,17 +86,17 @@ class IDocumentRedlineAccess
 {
      // Static helper functions
 public:
-    static bool IsShowChanges(const sal_uInt16 eM)
-    { return (nsRedlineMode_t::REDLINE_SHOW_INSERT | nsRedlineMode_t::REDLINE_SHOW_DELETE) == (eM & nsRedlineMode_t::REDLINE_SHOW_MASK); }
+    static bool IsShowChanges(const RedlineFlags eM)
+    { return (RedlineFlags::ShowInsert | RedlineFlags::ShowDelete) == (eM & RedlineFlags::ShowMask); }
 
-    static bool IsHideChanges(const sal_uInt16 eM)
-    { return nsRedlineMode_t::REDLINE_SHOW_INSERT == (eM & nsRedlineMode_t::REDLINE_SHOW_MASK); }
+    static bool IsHideChanges(const RedlineFlags eM)
+    { return RedlineFlags::ShowInsert == (eM & RedlineFlags::ShowMask); }
 
-    static bool IsShowOriginal(const sal_uInt16 eM)
-    { return nsRedlineMode_t::REDLINE_SHOW_DELETE == (eM & nsRedlineMode_t::REDLINE_SHOW_MASK); }
+    static bool IsShowOriginal(const RedlineFlags eM)
+    { return RedlineFlags::ShowDelete == (eM & RedlineFlags::ShowMask); }
 
-    static bool IsRedlineOn(const sal_uInt16 eM)
-    { return nsRedlineMode_t::REDLINE_ON == (eM & (nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_IGNORE )); }
+    static bool IsRedlineOn(const RedlineFlags eM)
+    { return RedlineFlags::On == (eM & (RedlineFlags::On | RedlineFlags::Ignore )); }
 
 public:
 
@@ -101,21 +105,21 @@ public:
         @returns
         the currently set redline mode
     */
-     virtual RedlineMode_t GetRedlineMode() const = 0;
+     virtual RedlineFlags GetRedlineFlags() const = 0;
 
     /** Set a new redline mode.
 
         @param eMode
         [in] the new redline mode.
     */
-    virtual void SetRedlineMode_intern(/*[in]*/RedlineMode_t eMode) = 0;
+    virtual void SetRedlineFlags_intern(/*[in]*/RedlineFlags eMode) = 0;
 
     /** Set a new redline mode.
 
         @param eMode
         [in] the new redline mode.
     */
-    virtual void SetRedlineMode(/*[in]*/RedlineMode_t eMode) = 0;
+    virtual void SetRedlineFlags(/*[in]*/RedlineFlags eMode) = 0;
 
     /** Query if redlining is on.
 
diff --git a/sw/inc/editsh.hxx b/sw/inc/editsh.hxx
index d874337..2105e22 100644
--- a/sw/inc/editsh.hxx
+++ b/sw/inc/editsh.hxx
@@ -101,6 +101,8 @@ class SwView;
 struct SwConversionArgs;
 enum class SvtScriptType;
 enum class SfxClassificationPolicyType;
+enum class RedlineFlags;
+
 namespace com { namespace sun { namespace star { namespace uno {
     template < class > class Sequence;
 }}}}
@@ -885,8 +887,8 @@ public:
     bool GotoGlobalDocContent( const SwGlblDocContent& rPos );
 
     /// For Redlining.
-    sal_uInt16 GetRedlineMode() const;
-    void SetRedlineMode( sal_uInt16 eMode );
+    RedlineFlags GetRedlineFlags() const;
+    void SetRedlineFlags( RedlineFlags eMode );
     bool IsRedlineOn() const;
     sal_uInt16 GetRedlineCount() const;
     const SwRangeRedline& GetRedline( sal_uInt16 nPos ) const;
diff --git a/sw/inc/undobj.hxx b/sw/inc/undobj.hxx
index 0913cea..5d3e0d3 100644
--- a/sw/inc/undobj.hxx
+++ b/sw/inc/undobj.hxx
@@ -38,6 +38,7 @@ class SwNodeIndex;
 class SwNodeRange;
 class SwRedlineData;
 class SwRedlineSaveDatas;
+enum class RedlineFlags;
 
 namespace sw {
     class UndoRedoContext;
@@ -48,7 +49,7 @@ class SwUndo
     : public SfxUndoAction
 {
     SwUndoId const m_nId;
-    sal_uInt16 nOrigRedlineMode;
+    RedlineFlags nOrigRedlineFlags;
     sal_Int32 m_nViewShellId;
 
 protected:
@@ -112,8 +113,8 @@ public:
 
     // UndoObject remembers which mode was turned on.
     // In Undo/Redo/Repeat this remembered mode is switched on.
-    sal_uInt16 GetRedlineMode() const { return nOrigRedlineMode; }
-    void SetRedlineMode( sal_uInt16 eMode ) { nOrigRedlineMode = eMode; }
+    RedlineFlags GetRedlineFlags() const { return nOrigRedlineFlags; }
+    void SetRedlineFlags( RedlineFlags eMode ) { nOrigRedlineFlags = eMode; }
 
     bool IsDelBox() const;
 
diff --git a/sw/qa/core/uwriter.cxx b/sw/qa/core/uwriter.cxx
index e994fcb..01c67e4 100644
--- a/sw/qa/core/uwriter.cxx
+++ b/sw/qa/core/uwriter.cxx
@@ -310,9 +310,9 @@ SwTextNode* getModelToViewTestDocument(SwDoc *pDoc)
     aPaM.DeleteMark();
 
     //turn on red-lining and show changes
-    pDoc->getIDocumentRedlineAccess().SetRedlineMode(nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_SHOW_DELETE|nsRedlineMode_t::REDLINE_SHOW_INSERT);
+    pDoc->getIDocumentRedlineAccess().SetRedlineFlags(RedlineFlags::On | RedlineFlags::ShowDelete|RedlineFlags::ShowInsert);
     CPPUNIT_ASSERT_MESSAGE("redlining should be on", pDoc->getIDocumentRedlineAccess().IsRedlineOn());
-    CPPUNIT_ASSERT_MESSAGE("redlines should be visible", IDocumentRedlineAccess::IsShowChanges(pDoc->getIDocumentRedlineAccess().GetRedlineMode()));
+    CPPUNIT_ASSERT_MESSAGE("redlines should be visible", IDocumentRedlineAccess::IsShowChanges(pDoc->getIDocumentRedlineAccess().GetRedlineFlags()));
 
     //set start of selection to last A
     aPaM.GetPoint()->nContent.Assign(aPaM.GetContentNode(), 4);
@@ -743,9 +743,9 @@ void SwDocTest::testSwScanner()
         CPPUNIT_ASSERT_EQUAL(aDocStat.nWord, static_cast<sal_uLong>(2));
 
         //turn on red-lining and show changes
-        m_pDoc->getIDocumentRedlineAccess().SetRedlineMode(nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_SHOW_DELETE|nsRedlineMode_t::REDLINE_SHOW_INSERT);
+        m_pDoc->getIDocumentRedlineAccess().SetRedlineFlags(RedlineFlags::On | RedlineFlags::ShowDelete|RedlineFlags::ShowInsert);
         CPPUNIT_ASSERT_MESSAGE("redlining should be on", m_pDoc->getIDocumentRedlineAccess().IsRedlineOn());
-        CPPUNIT_ASSERT_MESSAGE("redlines should be visible", IDocumentRedlineAccess::IsShowChanges(m_pDoc->getIDocumentRedlineAccess().GetRedlineMode()));
+        CPPUNIT_ASSERT_MESSAGE("redlines should be visible", IDocumentRedlineAccess::IsShowChanges(m_pDoc->getIDocumentRedlineAccess().GetRedlineFlags()));
 
         //delete everything except the first word
         aPaM.SetMark(); //set start of selection to current pos
@@ -762,9 +762,9 @@ void SwDocTest::testSwScanner()
         pTextNode->SetWordCountDirty(true);
 
         //keep red-lining on but hide changes
-        m_pDoc->getIDocumentRedlineAccess().SetRedlineMode(nsRedlineMode_t::REDLINE_ON);
+        m_pDoc->getIDocumentRedlineAccess().SetRedlineFlags(RedlineFlags::On);
         CPPUNIT_ASSERT_MESSAGE("redlining should be still on", m_pDoc->getIDocumentRedlineAccess().IsRedlineOn());
-        CPPUNIT_ASSERT_MESSAGE("redlines should be invisible", !IDocumentRedlineAccess::IsShowChanges(m_pDoc->getIDocumentRedlineAccess().GetRedlineMode()));
+        CPPUNIT_ASSERT_MESSAGE("redlines should be invisible", !IDocumentRedlineAccess::IsShowChanges(m_pDoc->getIDocumentRedlineAccess().GetRedlineFlags()));
 
         aDocStat.Reset();
         pTextNode->CountWords(aDocStat, 0, pTextNode->Len()); //but word-counting the text should only count the non-deleted text
@@ -794,7 +794,7 @@ void SwDocTest::testSwScanner()
 
         // https://bugs.libreoffice.org/show_bug.cgi?id=68347 we do want to count
         // redline *added* text though
-        m_pDoc->getIDocumentRedlineAccess().SetRedlineMode(nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_SHOW_DELETE|nsRedlineMode_t::REDLINE_SHOW_INSERT);
+        m_pDoc->getIDocumentRedlineAccess().SetRedlineFlags(RedlineFlags::On | RedlineFlags::ShowDelete|RedlineFlags::ShowInsert);
         aPaM.DeleteMark();
         aPaM.GetPoint()->nContent.Assign(aPaM.GetContentNode(), 0);
         m_pDoc->getIDocumentContentOperations().InsertString(aPaM, "redline-new-text ");
@@ -1044,15 +1044,15 @@ getRandomPosition(SwDoc *pDoc, int /* nOffset */)
 void SwDocTest::randomTest()
 {
     CPPUNIT_ASSERT_MESSAGE("SwDoc::IsRedlineOn()", !m_pDoc->getIDocumentRedlineAccess().IsRedlineOn());
-    RedlineMode_t modes[] = {
-        nsRedlineMode_t::REDLINE_ON,
-        nsRedlineMode_t::REDLINE_SHOW_MASK,
-        nsRedlineMode_t::REDLINE_NONE,
-        nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_SHOW_MASK,
-        nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_IGNORE,
-        nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_IGNORE | nsRedlineMode_t::REDLINE_SHOW_MASK,
-        nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_SHOW_INSERT,
-        nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_SHOW_DELETE
+    RedlineFlags modes[] = {
+        RedlineFlags::On,
+        RedlineFlags::ShowMask,
+        RedlineFlags::NONE,
+        RedlineFlags::On | RedlineFlags::ShowMask,
+        RedlineFlags::On | RedlineFlags::Ignore,
+        RedlineFlags::On | RedlineFlags::Ignore | RedlineFlags::ShowMask,
+        RedlineFlags::On | RedlineFlags::ShowInsert,
+        RedlineFlags::On | RedlineFlags::ShowDelete
     };
     static const char *authors[] = {
         "Jim", "Bob", "JimBobina", "Helga", "Gertrude", "Spagna", "Hurtleweed"
@@ -1063,7 +1063,7 @@ void SwDocTest::randomTest()
         m_pDoc->ClearDoc();
 
         // setup redlining
-        m_pDoc->getIDocumentRedlineAccess().SetRedlineMode(modes[rlm]);
+        m_pDoc->getIDocumentRedlineAccess().SetRedlineFlags(modes[rlm]);
         SW_MOD()->SetRedlineAuthor(OUString::createFromAscii(authors[0]));
 
         for( int i = 0; i < 2000; i++ )
diff --git a/sw/qa/extras/globalfilter/globalfilter.cxx b/sw/qa/extras/globalfilter/globalfilter.cxx
index 818fbd6..4f91797 100644
--- a/sw/qa/extras/globalfilter/globalfilter.cxx
+++ b/sw/qa/extras/globalfilter/globalfilter.cxx
@@ -39,7 +39,7 @@ public:
 #if !defined(_WIN32)
     void testSkipImages();
 #endif
-    void testRedlineMode();
+    void testRedlineFlags();
 
     CPPUNIT_TEST_SUITE(Test);
     CPPUNIT_TEST(testSwappedOutImageExport);
@@ -53,7 +53,7 @@ public:
 #if !defined(_WIN32)
     CPPUNIT_TEST(testSkipImages);
 #endif
-    CPPUNIT_TEST(testRedlineMode);
+    CPPUNIT_TEST(testRedlineFlags);
     CPPUNIT_TEST_SUITE_END();
 };
 
@@ -821,7 +821,7 @@ void Test::testSkipImages()
 }
 #endif
 
-void Test::testRedlineMode()
+void Test::testRedlineFlags()
 {
     const char* aFilterNames[] = {
         "writer8",
@@ -840,8 +840,8 @@ void Test::testRedlineMode()
 
     IDocumentRedlineAccess & rIDRA(pDoc->getIDocumentRedlineAccess());
     // enable change tracking
-    rIDRA.SetRedlineMode(rIDRA.GetRedlineMode()
-        | nsRedlineMode_t::REDLINE_ON | nsRedlineMode_t::REDLINE_SHOW_DELETE);
+    rIDRA.SetRedlineFlags(rIDRA.GetRedlineFlags()
+        | RedlineFlags::On | RedlineFlags::ShowDelete);
 
     // need a delete redline to trigger mode switching
     pam.Move(fnMoveForward, GoInDoc);
@@ -850,9 +850,9 @@ void Test::testRedlineMode()
     pDoc->getIDocumentContentOperations().DeleteAndJoin(pam);
 
     // hide delete redlines
-    RedlineMode_t const nRedlineMode =
-        rIDRA.GetRedlineMode() & ~nsRedlineMode_t::REDLINE_SHOW_DELETE;
-    rIDRA.SetRedlineMode(nRedlineMode);
+    RedlineFlags const nRedlineFlags =
+        rIDRA.GetRedlineFlags() & ~RedlineFlags::ShowDelete;
+    rIDRA.SetRedlineFlags(nRedlineFlags);
 
     for (size_t nFilter = 0; nFilter < SAL_N_ELEMENTS(aFilterNames); ++nFilter)
     {
@@ -869,7 +869,7 @@ void Test::testRedlineMode()
         // tdf#97103 check that redline mode is properly restored
         CPPUNIT_ASSERT_EQUAL_MESSAGE(
             OString(OString("redline mode not restored in ") + aFilterNames[nFilter]).getStr(),
-            nRedlineMode, rIDRA.GetRedlineMode());
+            (int)nRedlineFlags, (int)rIDRA.GetRedlineFlags());
     }
 }
 
diff --git a/sw/qa/extras/uiwriter/uiwriter.cxx b/sw/qa/extras/uiwriter/uiwriter.cxx

... etc. - the rest is truncated


More information about the Libreoffice-commits mailing list