[Libreoffice-commits] core.git: compilerplugins/clang include/svl svl/source sw/inc sw/source

2023-08-02 Thread Bjoern Michaelsen (via logerrit)
 compilerplugins/clang/unusedmethods.results |2 -
 include/svl/hint.hxx|1 
 svl/source/items/poolitem.cxx   |1 
 sw/inc/hintids.hxx  |3 --
 sw/inc/hints.hxx|   42 +---
 sw/source/core/attr/hints.cxx   |   14 ++---
 sw/source/core/inc/pagefrm.hxx  |6 ++--
 sw/source/core/inc/tabfrm.hxx   |1 
 sw/source/core/inc/txtfrm.hxx   |1 
 sw/source/core/layout/pagechg.cxx   |6 ++--
 sw/source/core/layout/tabfrm.cxx|   19 +---
 sw/source/core/layout/trvlfrm.cxx   |   14 -
 sw/source/core/text/txtfrm.cxx  |   20 ++---
 13 files changed, 68 insertions(+), 62 deletions(-)

New commits:
commit 7f85415a2f07d62bf688cb33680054940d4dd7f1
Author: Bjoern Michaelsen 
AuthorDate: Sun Jul 30 09:01:30 2023 +0200
Commit: Bjoern Michaelsen 
CommitDate: Thu Aug 3 08:01:55 2023 +0200

move SwVirtPageNumInfo to SfxHint

- also remove now obsolete GetInfo overrides

Change-Id: Iaac75ed2e53daead06242ce4620fd2b879909e02
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155061
Tested-by: Jenkins
Reviewed-by: Bjoern Michaelsen 

diff --git a/compilerplugins/clang/unusedmethods.results 
b/compilerplugins/clang/unusedmethods.results
index 77d563e9d719..a4b5e3d3dcd5 100644
--- a/compilerplugins/clang/unusedmethods.results
+++ b/compilerplugins/clang/unusedmethods.results
@@ -1934,8 +1934,6 @@ include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
-include/svl/typedwhich.hxx:31
- TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
diff --git a/include/svl/hint.hxx b/include/svl/hint.hxx
index 5967d834ceeb..ba230f92b817 100644
--- a/include/svl/hint.hxx
+++ b/include/svl/hint.hxx
@@ -152,6 +152,7 @@ enum class SfxHintId {
 SwDocPosUpdate,
 SwDocPosUpdateAtIndex,
 SwTableHeadingChange,
+SwVirtPageNumHint,
 
 ThisIsAnSdrHint
 };
diff --git a/svl/source/items/poolitem.cxx b/svl/source/items/poolitem.cxx
index dfa584f6114a..cb1bec15159c 100644
--- a/svl/source/items/poolitem.cxx
+++ b/svl/source/items/poolitem.cxx
@@ -437,7 +437,6 @@
 // class SwTableFormulaUpdate : public SwMsgPoolItem
 // class SwAutoFormatGetDocNode: public SwMsgPoolItem
 // class SwAttrSetChg: public SwMsgPoolItem
-// class SwVirtPageNumInfo: public SwMsgPoolItem
 // class SwFindNearestNode : public SwMsgPoolItem
 // class SwStringMsgPoolItem : public SwMsgPoolItem
 // class SwFormatDrop: public SfxPoolItem, public SwClient
diff --git a/sw/inc/hintids.hxx b/sw/inc/hintids.hxx
index 1046dab3e1ca..339a73068162 100644
--- a/sw/inc/hintids.hxx
+++ b/sw/inc/hintids.hxx
@@ -141,7 +141,7 @@ class SwTransparencyGrf;
 class SwFormatRuby;
 class SwTableFormulaUpdate;
 class SwAutoFormatGetDocNode;
-class SwVirtPageNumInfo;
+class VirtPageNumHint;
 class SwFindNearestNode;
 class SwFltAnchor;
 class SwFltTOX;
@@ -433,7 +433,6 @@ constexpr TypedWhichId RES_ATTRSET_CHG(169);
 constexpr TypedWhichId RES_UPDATE_ATTR(170);
 constexpr TypedWhichId RES_AUTOFMT_DOCNODE(176);
 constexpr TypedWhichId RES_HIDDENPARA_PRINT(178);
-constexpr TypedWhichId RES_VIRTPAGENUM_INFO(180);
 constexpr TypedWhichId RES_REMOVE_UNO_OBJECT(181);
 // empty
 constexpr TypedWhichId RES_FINDNEARESTNODE(184);
diff --git a/sw/inc/hints.hxx b/sw/inc/hints.hxx
index 46a3c586771f..eb3ba5a2cdc2 100644
--- a/sw/inc/hints.hxx
+++ b/sw/inc/hints.hxx
@@ -261,6 +261,32 @@ class TableHeadingChange final: public SfxHint
 public:
 TableHeadingChange() : SfxHint(SfxHintId::SwTableHeadingChange) {};
 };
+class VirtPageNumHint final: public SfxHint
+{
+const SwPageFrame* m_pPage;
+const SwPageFrame* m_pOrigPage;
+const SwFrame* m_pFrame;
+bool m_bFound;
+/** Multiple attributes can be attached to a single paragraph / table
+ The frame, in the end, has to decide which attribute takes effect and 
which physical page it involves */
+public:
+VirtPageNumHint(const SwPageFrame* pPg);
+const SwPageFrame* GetPage() const
+{ return m_pPage; }
+const SwPageFrame* GetOrigPage() const
+{ return m_pOrigPage; }
+const SwFrame* GetFrame() const
+{ return m_pFrame; }
+void SetInfo(const SwPageFrame* pPg, const SwFrame *pF)
+{ m_pFrame = pF; m_pPage = pPg; }
+void SetFound()
+{
+assert(!m_bFound);
+m_bFound = true;
+}
+bool IsFound()
+{ return m_bFound; }
+};
 }
 
 class SwUpdateAttr final : public SwMsgPoolItem
@@ -359,22 +385,6 @@ public:
 #endif
 };
 
-class SwVirtPageN

[Libreoffice-commits] core.git: compilerplugins/clang include/svl svl/source sw/inc sw/source

2022-09-25 Thread Bjoern Michaelsen (via logerrit)
 compilerplugins/clang/unusedmethods.results |2 -
 include/svl/hint.hxx|1 
 svl/source/items/poolitem.cxx   |1 
 sw/inc/hintids.hxx  |2 -
 sw/inc/hints.hxx|   15 
 sw/source/core/attr/hints.cxx   |   10 ++---
 sw/source/core/text/txtfrm.cxx  |   47 ++--
 sw/source/core/txtnode/ndtxt.cxx|   13 +++
 8 files changed, 45 insertions(+), 46 deletions(-)

New commits:
commit eb1294a60783ceb450cefd6891d6eafa0021aadc
Author: Bjoern Michaelsen 
AuthorDate: Sun Sep 25 11:34:10 2022 +0200
Commit: Bjoern Michaelsen 
CommitDate: Sun Sep 25 20:01:53 2022 +0200

unwrap SwDelChr to plain SfxHint

Change-Id: Ief37a8025181b6cc8a6e484e2726d8a8d92f57ea
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140567
Tested-by: Jenkins
Reviewed-by: Bjoern Michaelsen 

diff --git a/compilerplugins/clang/unusedmethods.results 
b/compilerplugins/clang/unusedmethods.results
index be732177c36b..524af6ade80c 100644
--- a/compilerplugins/clang/unusedmethods.results
+++ b/compilerplugins/clang/unusedmethods.results
@@ -1592,8 +1592,6 @@ include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
-include/svl/typedwhich.hxx:31
- TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
diff --git a/include/svl/hint.hxx b/include/svl/hint.hxx
index 4b4677cd768d..22f0bb8eb7e2 100644
--- a/include/svl/hint.hxx
+++ b/include/svl/hint.hxx
@@ -142,6 +142,7 @@ enum class SfxHintId {
 SwNameChanged, // this can possibly be replaced by the generic NameChanged 
above
 SwInsertText,
 SwDeleteText,
+SwDeleteChar,
 
 ThisIsAnSdrHint
 };
diff --git a/svl/source/items/poolitem.cxx b/svl/source/items/poolitem.cxx
index 32dfebb51747..225678340a1c 100644
--- a/svl/source/items/poolitem.cxx
+++ b/svl/source/items/poolitem.cxx
@@ -434,7 +434,6 @@
 // class SwMsgPoolItem : public SfxPoolItem
 // class SwPtrMsgPoolItem : public SwMsgPoolItem
 // class SwFormatChg: public SwMsgPoolItem
-// class SwDelChr: public SwMsgPoolItem
 // class SwUpdateAttr : public SwMsgPoolItem
 // class SwRefMarkFieldUpdate : public SwMsgPoolItem
 // class SwDocPosUpdate : public SwMsgPoolItem
diff --git a/sw/inc/hintids.hxx b/sw/inc/hintids.hxx
index afe2df275aaa..497635f71f5b 100644
--- a/sw/inc/hintids.hxx
+++ b/sw/inc/hintids.hxx
@@ -133,7 +133,6 @@ class SwTableBoxNumFormat;
 class SwTextGridItem;
 class SwTransparencyGrf;
 class SwFormatRuby;
-class SwDelChr;
 class SwRefMarkFieldUpdate;
 class SwTableFormulaUpdate;
 class SwAutoFormatGetDocNode;
@@ -422,7 +421,6 @@ constexpr sal_uInt16 RES_MSG_BEGIN(RES_FMT_END);
 constexpr TypedWhichId RES_OBJECTDYING(RES_MSG_BEGIN); // 161
 constexpr TypedWhichId RES_FMT_CHG(162);
 constexpr TypedWhichId RES_ATTRSET_CHG(163);
-constexpr TypedWhichId RES_DEL_CHR(165);
 constexpr TypedWhichId RES_UPDATE_ATTR(167);
 constexpr TypedWhichId RES_REFMARKFLD_UPDATE(168);
 constexpr TypedWhichId RES_DOCPOS_UPDATE(169);
diff --git a/sw/inc/hints.hxx b/sw/inc/hints.hxx
index 78952b288193..777825ae4969 100644
--- a/sw/inc/hints.hxx
+++ b/sw/inc/hints.hxx
@@ -76,13 +76,6 @@ public:
 SwFormatChg( SwFormat *pFormat );
 };
 
-class SwDelChr final : public SwMsgPoolItem
-{
-public:
-sal_Int32 nPos;
-
-SwDelChr( sal_Int32 nP );
-};
 
 
 namespace sw {
@@ -119,6 +112,14 @@ public:
 DeleteText( sal_Int32 nS, sal_Int32 nL );
 };
 
+class DeleteChar final : public SfxHint
+{
+public:
+const sal_Int32 m_nPos;
+
+DeleteChar( const sal_Int32 nPos );
+};
+
 /// new delete redline is created
 class RedlineDelText final : public SfxHint
 {
diff --git a/sw/source/core/attr/hints.cxx b/sw/source/core/attr/hints.cxx
index 76a5113eed46..3257d5736900 100644
--- a/sw/source/core/attr/hints.cxx
+++ b/sw/source/core/attr/hints.cxx
@@ -33,11 +33,6 @@ SwFormatChg::SwFormatChg( SwFormat* pFormat )
 }
 
 
-SwDelChr::SwDelChr( sal_Int32 nP )
-: SwMsgPoolItem( RES_DEL_CHR ), nPos( nP )
-{
-}
-
 
 namespace sw {
 
@@ -59,6 +54,11 @@ DeleteText::DeleteText( const sal_Int32 nS, const sal_Int32 
nL )
 {
 }
 
+DeleteChar::DeleteChar( const sal_Int32 nPos )
+: SfxHint( SfxHintId::SwDeleteChar ), m_nPos( nPos )
+{
+}
+
 RedlineDelText::RedlineDelText(sal_Int32 const nS, sal_Int32 const nL)
 : nStart(nS), nLen(nL)
 {
diff --git a/sw/source/core/text/txtfrm.cxx b/sw/source/core/text/txtfrm.cxx
index 1de6c91cc633..22a8a0bc0ae1 100644
--- a/sw/source/core/text/txtfrm.cxx
+++ b/sw/source/core/text/txtfrm.cxx
@@ -1977,6 +1977,7 @@ void SwTextFrame::SwClientNotify(SwModify const& rModify, 
SfxHint const&

[Libreoffice-commits] core.git: compilerplugins/clang include/svl svl/source sw/inc sw/source

2022-09-25 Thread Bjoern Michaelsen (via logerrit)
 compilerplugins/clang/unusedmethods.results |2 
 include/svl/hint.hxx|1 
 svl/source/items/poolitem.cxx   |1 
 sw/inc/hintids.hxx  |2 
 sw/inc/hints.hxx|   27 
 sw/inc/ndtxt.hxx|3 
 sw/source/core/attr/hints.cxx   |   17 ++---
 sw/source/core/doc/docbm.cxx|6 -
 sw/source/core/inc/txtfrm.hxx   |4 -
 sw/source/core/text/txtfrm.cxx  |   94 ++--
 sw/source/core/txtnode/ndtxt.cxx|   21 +++---
 sw/source/core/txtnode/txtedt.cxx   |7 +-
 12 files changed, 94 insertions(+), 91 deletions(-)

New commits:
commit eea9f1ee27db98617871b9ecf80e9b3a62a4e723
Author: Bjoern Michaelsen 
AuthorDate: Sat Sep 24 19:28:17 2022 +0200
Commit: Bjoern Michaelsen 
CommitDate: Sun Sep 25 10:42:33 2022 +0200

unwrap SwInsText to a plain SfxHint

- also add some constnesss and move some things to private

Change-Id: I67a45e1326361b5a8f7e320b3525e74e93b1ef12
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140556
Tested-by: Jenkins
Reviewed-by: Bjoern Michaelsen 

diff --git a/compilerplugins/clang/unusedmethods.results 
b/compilerplugins/clang/unusedmethods.results
index 2624f69422ef..be732177c36b 100644
--- a/compilerplugins/clang/unusedmethods.results
+++ b/compilerplugins/clang/unusedmethods.results
@@ -1696,8 +1696,6 @@ include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, 
int>::type)
-include/svl/typedwhich.hxx:31
- TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
diff --git a/include/svl/hint.hxx b/include/svl/hint.hxx
index b22e9c789f3f..4b4677cd768d 100644
--- a/include/svl/hint.hxx
+++ b/include/svl/hint.hxx
@@ -140,6 +140,7 @@ enum class SfxHintId {
 SwGatherRefFields,
 SwGatherFields,
 SwNameChanged, // this can possibly be replaced by the generic NameChanged 
above
+SwInsertText,
 SwDeleteText,
 
 ThisIsAnSdrHint
diff --git a/svl/source/items/poolitem.cxx b/svl/source/items/poolitem.cxx
index 5aada9d9d08b..32dfebb51747 100644
--- a/svl/source/items/poolitem.cxx
+++ b/svl/source/items/poolitem.cxx
@@ -434,7 +434,6 @@
 // class SwMsgPoolItem : public SfxPoolItem
 // class SwPtrMsgPoolItem : public SwMsgPoolItem
 // class SwFormatChg: public SwMsgPoolItem
-// class SwInsText: public SwMsgPoolItem
 // class SwDelChr: public SwMsgPoolItem
 // class SwUpdateAttr : public SwMsgPoolItem
 // class SwRefMarkFieldUpdate : public SwMsgPoolItem
diff --git a/sw/inc/hintids.hxx b/sw/inc/hintids.hxx
index a2529f935d00..afe2df275aaa 100644
--- a/sw/inc/hintids.hxx
+++ b/sw/inc/hintids.hxx
@@ -133,7 +133,6 @@ class SwTableBoxNumFormat;
 class SwTextGridItem;
 class SwTransparencyGrf;
 class SwFormatRuby;
-class SwInsText;
 class SwDelChr;
 class SwRefMarkFieldUpdate;
 class SwTableFormulaUpdate;
@@ -423,7 +422,6 @@ constexpr sal_uInt16 RES_MSG_BEGIN(RES_FMT_END);
 constexpr TypedWhichId RES_OBJECTDYING(RES_MSG_BEGIN); // 161
 constexpr TypedWhichId RES_FMT_CHG(162);
 constexpr TypedWhichId RES_ATTRSET_CHG(163);
-constexpr TypedWhichId RES_INS_TXT(164);
 constexpr TypedWhichId RES_DEL_CHR(165);
 constexpr TypedWhichId RES_UPDATE_ATTR(167);
 constexpr TypedWhichId RES_REFMARKFLD_UPDATE(168);
diff --git a/sw/inc/hints.hxx b/sw/inc/hints.hxx
index 63c25b90b4e0..78952b288193 100644
--- a/sw/inc/hints.hxx
+++ b/sw/inc/hints.hxx
@@ -76,17 +76,6 @@ public:
 SwFormatChg( SwFormat *pFormat );
 };
 
-class SwInsText final : public SwMsgPoolItem
-{
-public:
-sal_Int32 nPos;
-sal_Int32 nLen;
-bool isInsideFieldmarkCommand;
-bool isInsideFieldmarkResult;
-
-SwInsText(sal_Int32 nP, sal_Int32 nL, bool isInFMCommand, bool 
isInFMResult);
-};
-
 class SwDelChr final : public SwMsgPoolItem
 {
 public:
@@ -110,14 +99,26 @@ public:
 MoveText(SwTextNode *pD, sal_Int32 nD, sal_Int32 nS, sal_Int32 nL);
 };
 
+class InsertText final : public SfxHint
+{
+public:
+const sal_Int32 nPos;
+const sal_Int32 nLen;
+const bool isInsideFieldmarkCommand;
+const bool isInsideFieldmarkResult;
+
+InsertText(sal_Int32 nP, sal_Int32 nL, bool isInFMCommand, bool 
isInFMResult);
+};
+
 class DeleteText final : public SfxHint
 {
 public:
-sal_Int32 nStart;
-sal_Int32 nLen;
+const sal_Int32 nStart;
+const sal_Int32 nLen;
 
 DeleteText( sal_Int32 nS, sal_Int32 nL );
 };
+
 /// new delete redline is created
 class RedlineDelText final : public SfxHint
 {
diff --git a/sw/inc/ndtxt.hxx b/sw/inc/ndtxt.hxx
index 3a2b4d65e41d..12b823a52f7c 100644
--- a/sw/inc/ndtxt.hxx
+

[Libreoffice-commits] core.git: compilerplugins/clang include/svl svl/source sw/inc sw/source

2022-09-24 Thread Bjoern Michaelsen (via logerrit)
 compilerplugins/clang/unusedmethods.results |2 
 include/svl/hint.hxx|1 
 svl/source/items/poolitem.cxx   |1 
 sw/inc/hintids.hxx  |2 
 sw/inc/hints.hxx|   16 +-
 sw/inc/ndtxt.hxx|8 +
 sw/source/core/attr/hints.cxx   |9 -
 sw/source/core/text/txtfrm.cxx  |   62 +-
 sw/source/core/txtnode/ndtxt.cxx|  161 
 sw/source/core/txtnode/txtedt.cxx   |3 
 10 files changed, 148 insertions(+), 117 deletions(-)

New commits:
commit aace38f9bf702ecbe8de7cafc0979754eaa178c1
Author: Bjoern Michaelsen 
AuthorDate: Sun Sep 18 12:46:01 2022 +0200
Commit: Bjoern Michaelsen 
CommitDate: Sat Sep 24 18:28:07 2022 +0200

unwrap SwDelText to a plain SfxHint

Change-Id: I559f8f1e837830426e820dace6226618c5e0fc62
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140210
Tested-by: Jenkins
Reviewed-by: Bjoern Michaelsen 

diff --git a/compilerplugins/clang/unusedmethods.results 
b/compilerplugins/clang/unusedmethods.results
index 98c1d36bd64a..2624f69422ef 100644
--- a/compilerplugins/clang/unusedmethods.results
+++ b/compilerplugins/clang/unusedmethods.results
@@ -1594,8 +1594,6 @@ include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
-include/svl/typedwhich.hxx:31
- TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
  TypedWhichId::TypedWhichId(TypedWhichId,typename 
enable_if, int>::type)
 include/svl/typedwhich.hxx:31
diff --git a/include/svl/hint.hxx b/include/svl/hint.hxx
index a5cbc1913e2e..b22e9c789f3f 100644
--- a/include/svl/hint.hxx
+++ b/include/svl/hint.hxx
@@ -140,6 +140,7 @@ enum class SfxHintId {
 SwGatherRefFields,
 SwGatherFields,
 SwNameChanged, // this can possibly be replaced by the generic NameChanged 
above
+SwDeleteText,
 
 ThisIsAnSdrHint
 };
diff --git a/svl/source/items/poolitem.cxx b/svl/source/items/poolitem.cxx
index 205f75b89bcd..5aada9d9d08b 100644
--- a/svl/source/items/poolitem.cxx
+++ b/svl/source/items/poolitem.cxx
@@ -436,7 +436,6 @@
 // class SwFormatChg: public SwMsgPoolItem
 // class SwInsText: public SwMsgPoolItem
 // class SwDelChr: public SwMsgPoolItem
-// class SwDelText: public SwMsgPoolItem
 // class SwUpdateAttr : public SwMsgPoolItem
 // class SwRefMarkFieldUpdate : public SwMsgPoolItem
 // class SwDocPosUpdate : public SwMsgPoolItem
diff --git a/sw/inc/hintids.hxx b/sw/inc/hintids.hxx
index b4fddf911179..a2529f935d00 100644
--- a/sw/inc/hintids.hxx
+++ b/sw/inc/hintids.hxx
@@ -135,7 +135,6 @@ class SwTransparencyGrf;
 class SwFormatRuby;
 class SwInsText;
 class SwDelChr;
-class SwDelText;
 class SwRefMarkFieldUpdate;
 class SwTableFormulaUpdate;
 class SwAutoFormatGetDocNode;
@@ -426,7 +425,6 @@ constexpr TypedWhichId RES_FMT_CHG(162);
 constexpr TypedWhichId RES_ATTRSET_CHG(163);
 constexpr TypedWhichId RES_INS_TXT(164);
 constexpr TypedWhichId RES_DEL_CHR(165);
-constexpr TypedWhichId RES_DEL_TXT(166);
 constexpr TypedWhichId RES_UPDATE_ATTR(167);
 constexpr TypedWhichId RES_REFMARKFLD_UPDATE(168);
 constexpr TypedWhichId RES_DOCPOS_UPDATE(169);
diff --git a/sw/inc/hints.hxx b/sw/inc/hints.hxx
index 8c15ed64ced6..63c25b90b4e0 100644
--- a/sw/inc/hints.hxx
+++ b/sw/inc/hints.hxx
@@ -95,14 +95,6 @@ public:
 SwDelChr( sal_Int32 nP );
 };
 
-class SwDelText final : public SwMsgPoolItem
-{
-public:
-sal_Int32 nStart;
-sal_Int32 nLen;
-
-SwDelText( sal_Int32 nS, sal_Int32 nL );
-};
 
 namespace sw {
 
@@ -118,6 +110,14 @@ public:
 MoveText(SwTextNode *pD, sal_Int32 nD, sal_Int32 nS, sal_Int32 nL);
 };
 
+class DeleteText final : public SfxHint
+{
+public:
+sal_Int32 nStart;
+sal_Int32 nLen;
+
+DeleteText( sal_Int32 nS, sal_Int32 nL );
+};
 /// new delete redline is created
 class RedlineDelText final : public SfxHint
 {
diff --git a/sw/inc/ndtxt.hxx b/sw/inc/ndtxt.hxx
index feaa6c4c1bc2..3a2b4d65e41d 100644
--- a/sw/inc/ndtxt.hxx
+++ b/sw/inc/ndtxt.hxx
@@ -68,7 +68,11 @@ enum class ExpandMode;
 enum class SwFieldIds : sal_uInt16;
 class SwField;
 
-namespace sw::mark { enum class RestoreMode; }
+namespace sw {
+class TextNodeNotificationSuppressor;
+class DeleteText;
+namespace mark { enum class RestoreMode; }
+}
 
 namespace com::sun::star {
 namespace uno {
@@ -90,6 +94,7 @@ class SW_DLLPUBLIC SwTextNode final
 friend class SwNodes;
 friend class SwTextFrame;
 friend class SwScriptInfo;
+friend class sw::TextNodeNotificationSuppressor;
 
 /** May be 0. It is only then not 0 if it contains hard attributes.
Therefore: never access directly! */
@@ -216,6 +221,7 @@ public:
 
 public:
 using