diff options
-rw-r--r-- | sw/source/core/doc/docredln.cxx | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/sw/source/core/doc/docredln.cxx b/sw/source/core/doc/docredln.cxx index 0d0b7fa621e2..cb6fb4f3302c 100644 --- a/sw/source/core/doc/docredln.cxx +++ b/sw/source/core/doc/docredln.cxx @@ -411,8 +411,15 @@ bool SwRedlineTable::Insert(SwRangeRedline*& p) size_type nP = rv.first - begin(); LOKRedlineNotification(RedlineNotification::Add, p); - // set IsMoved checking nearby redlines - isMoved(nP); + // detect text moving by checking nearby redlines, except during Undo + // (apply isMoved() during OpenDocument and DOCX import, too, to fix + // missing text moving handling in ODF and e.g. web version of MSO) + if ( p->GetDoc().GetIDocumentUndoRedo().DoesUndo() || + p->GetDoc().IsInWriterfilterImport() || + p->GetDoc().IsInXMLImport() ) + { + isMoved(nP); + } p->CallDisplayFunc(nP); if (rv.second) |