LibreOffice Module sw (master)
1
|
#include <DocumentContentOperationsManager.hxx>
Classes | |
struct | ParaRstFormat |
Parameters for _Rst and lcl_SetTextFormatColl. More... | |
Public Member Functions | |
DocumentContentOperationsManager (SwDoc &i_rSwdoc) | |
bool | CopyRange (SwPaM &, SwPosition &, SwCopyFlags) const override |
Copy a selected content range to a position. More... | |
void | DeleteSection (SwNode *pNode) override |
Delete a full Section of the NodeArray. More... | |
void | DeleteRange (SwPaM &) override |
Delete a range SwFlyFrameFormat. More... | |
bool | DelFullPara (SwPaM &) override |
Delete full paragraphs. More... | |
bool | DeleteAndJoin (SwPaM &) override |
complete delete of a given PaM More... | |
bool | MoveRange (SwPaM &, SwPosition &, SwMoveFlags) override |
bool | MoveNodeRange (SwNodeRange &, SwNodeIndex &, SwMoveFlags) override |
void | MoveAndJoin (SwPaM &, SwPosition &) override |
Move a range. More... | |
bool | Overwrite (const SwPaM &rRg, const OUString &rStr) override |
Overwrite string in an existing text node. More... | |
bool | InsertString (const SwPaM &rRg, const OUString &, const SwInsertFlags nInsertMode=SwInsertFlags::EMPTYEXPAND) override |
Insert string into existing text node at position rRg.Point(). More... | |
void | SetIME (bool bIME) override |
States that the last inserted string came from IME. More... | |
bool | GetIME () const override |
Did the last inserted string come from IME? More... | |
void | TransliterateText (const SwPaM &rPaM, utl::TransliterationWrapper &) override |
change text to Upper/Lower/Hiragana/Katakana/... More... | |
SwFlyFrameFormat * | InsertGraphic (const SwPaM &rRg, const OUString &rGrfName, const OUString &rFltName, const Graphic *pGraphic, const SfxItemSet *pFlyAttrSet, const SfxItemSet *pGrfAttrSet, SwFrameFormat *) override |
Insert graphic or formula. More... | |
SwFlyFrameFormat * | InsertGraphicObject (const SwPaM &rRg, const GraphicObject &rGrfObj, const SfxItemSet *pFlyAttrSet, const SfxItemSet *pGrfAttrSet) override |
void | ReRead (SwPaM &, const OUString &rGrfName, const OUString &rFltName, const Graphic *pGraphic) override |
Transpose graphic (with undo) More... | |
SwDrawFrameFormat * | InsertDrawObj (const SwPaM &rRg, SdrObject &rDrawObj, const SfxItemSet &rFlyAttrSet) override |
Insert a DrawObject. More... | |
SwFlyFrameFormat * | InsertEmbObject (const SwPaM &rRg, const svt::EmbeddedObjectRef &xObj, SfxItemSet *pFlyAttrSet) override |
Insert OLE-objects. More... | |
SwFlyFrameFormat * | InsertOLE (const SwPaM &rRg, const OUString &rObjName, sal_Int64 nAspect, const SfxItemSet *pFlyAttrSet, const SfxItemSet *pGrfAttrSet) override |
bool | SplitNode (const SwPosition &rPos, bool bChkTableStart) override |
Split a node at rPos (implemented only for TextNode). More... | |
bool | AppendTextNode (SwPosition &rPos) override |
bool | ReplaceRange (SwPaM &rPam, const OUString &rNewStr, const bool bRegExReplace) override |
Replace selected range in a TextNode with string. More... | |
bool | InsertPoolItem (const SwPaM &rRg, const SfxPoolItem &, const SetAttrMode nFlags=SetAttrMode::DEFAULT, SwRootFrame const *pLayout=nullptr, SwTextAttr **ppNewTextAttr=nullptr) override |
Insert an attribute. More... | |
void | InsertItemSet (const SwPaM &rRg, const SfxItemSet &, const SetAttrMode nFlags=SetAttrMode::DEFAULT, SwRootFrame const *pLayout=nullptr) override |
void | RemoveLeadingWhiteSpace (const SwPosition &rPos) override |
Removes any leading white space from the paragraph. More... | |
void | DeleteDummyChar (SwPosition const &rPos, sal_Unicode cDummy) |
void | CopyWithFlyInFly (const SwNodeRange &rRg, const SwNodeIndex &rInsPos, const std::pair< const SwPaM &, const SwPosition & > *pCopiedPaM=nullptr, bool bMakeNewFrames=true, bool bDelRedlines=true, bool bCopyFlyAtFly=false, SwCopyFlags flags=SwCopyFlags::Default) const |
note: rRg/rInsPos exclude a partially selected start text node; pCopiedPaM includes a partially selected start text node More... | |
void | CopyFlyInFlyImpl (const SwNodeRange &rRg, SwPaM const *const pCopiedPaM, const SwNodeIndex &rStartIdx, const bool bCopyFlyAtFly=false, SwCopyFlags flags=SwCopyFlags::Default) const |
virtual | ~DocumentContentOperationsManager () override |
Static Public Member Functions | |
static bool | lcl_RstTextAttr (SwNode *pNd, void *pArgs) |
pArgs contains the document's ChrFormatTable Is need for selections at the beginning/end and with no SSelection. More... | |
Private Member Functions | |
bool | DeleteAndJoinImpl (SwPaM &) |
bool | DeleteAndJoinWithRedlineImpl (SwPaM &) |
bool | DeleteRangeImpl (SwPaM &) |
bool | DeleteRangeImplImpl (SwPaM &) |
bool | ReplaceRangeImpl (SwPaM &, OUString const &, const bool) |
SwFlyFrameFormat * | InsNoTextNode (const SwPosition &rPos, SwNoTextNode *, const SfxItemSet *pFlyAttrSet, const SfxItemSet *pGrfAttrSet, SwFrameFormat *) |
bool | CopyImpl (SwPaM &, SwPosition &, SwCopyFlags flags, SwPaM *const pCpyRng) const |
bool | CopyImplImpl (SwPaM &, SwPosition &, SwCopyFlags flags, SwPaM *const pCpyRng) const |
DocumentContentOperationsManager (DocumentContentOperationsManager const &)=delete | |
DocumentContentOperationsManager & | operator= (DocumentContentOperationsManager const &)=delete |
Private Attributes | |
SwDoc & | m_rDoc |
bool | m_bIME = false |
Additional Inherited Members | |
![]() | |
virtual | ~IDocumentContentOperations () |
Definition at line 33 of file DocumentContentOperationsManager.hxx.
sw::DocumentContentOperationsManager::DocumentContentOperationsManager | ( | SwDoc & | i_rSwdoc | ) |
Definition at line 1990 of file DocumentContentOperationsManager.cxx.
|
overridevirtual |
Definition at line 4099 of file DocumentContentOperationsManager.cxx.
|
privatedelete |
|
overridevirtual |
Implements IDocumentContentOperations.
Definition at line 3436 of file DocumentContentOperationsManager.cxx.
References SwTextNode::AppendNode(), IDocumentRedlineAccess::AppendRedline(), IDocumentUndoRedo::AppendUndo(), SwIndex::Assign(), IDocumentUndoRedo::DoesUndo(), SwRedlineTable::empty(), fnMoveBackward, SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::getIDocumentStylePoolAccess(), SwDoc::GetIDocumentUndoRedo(), SwNodeIndex::GetNode(), SwDoc::GetNodes(), IDocumentRedlineAccess::GetRedlineTable(), IDocumentStylePoolAccess::GetTextCollFromPool(), SwNode::GetTextNode(), IDocumentRedlineAccess::IsIgnoreRedline(), IDocumentRedlineAccess::IsRedlineOn(), m_rDoc, SwNodes::MakeTextNode(), SwPaM::Move(), SwPosition::nContent, SwPosition::nNode, RES_POOLCOLL_STANDARD, SwPaM::SetMark(), IDocumentState::SetModified(), and IDocumentRedlineAccess::SplitRedline().
void sw::DocumentContentOperationsManager::CopyFlyInFlyImpl | ( | const SwNodeRange & | rRg, |
SwPaM const *const | pCopiedPaM, | ||
const SwNodeIndex & | rStartIdx, | ||
const bool | bCopyFlyAtFly = false , |
||
SwCopyFlags | flags = SwCopyFlags::Default |
||
) | const |
Definition at line 3802 of file DocumentContentOperationsManager.cxx.
References SwNodeRange::aEnd, AllMask, SwNodeRange::aStart, SwPaM::End(), SwNode::EndOfSectionIndex(), SwFormat::GetAnchor(), SwFormatAnchor::GetAnchorId(), SwFormat::GetChain(), SwFormatAnchor::GetContentAnchor(), SwFormatContent::GetContentIdx(), SwNode::GetDoc(), SwNodes::GetEndOfContent(), SwDoc::getIDocumentRedlineAccess(), SwIndex::GetIndex(), SwNodeIndex::GetIndex(), SwNode::GetIndex(), SwFormatChain::GetNext(), SwNodeIndex::GetNode(), SwNode::GetNodes(), SwFormatChain::GetPrev(), SwDoc::GetSpzFrameFormats(), SwNode::GetStartNode(), IsDestroyFrameAnchoredAtChar(), IsMoveToFly, IDocumentRedlineAccess::IsRedlineMove(), IsSelectFrameAnchoredAtPara(), SwTextBoxHelper::isTextBox(), SwNode::IsTextNode(), m_rDoc, SwPosition::nContent, SwPosition::nNode, RES_FLYFRMFMT(), SwTextBoxHelper::restoreLinks(), SwTextBoxHelper::saveLinks(), SwFrameFormats::size(), SwPaM::Start(), and WriterfilterHack.
Referenced by CopyImplImpl(), SwDoc::CopyPageDescHeaderFooterImpl(), and CopyWithFlyInFly().
|
private |
Definition at line 4805 of file DocumentContentOperationsManager.cxx.
References sw::CalcBreaks(), CopyImplImpl(), SwPaM::End(), SwPaM::GetMark(), SwNodeIndex::GetNodes(), SwPaM::GetPoint(), SwPosition::nNode, SwPaM::SetMark(), and SwPaM::Start().
Referenced by CopyRange().
|
private |
Definition at line 4872 of file DocumentContentOperationsManager.cxx.
References aBreakSetRange, SwNodeRange::aEnd, IDocumentUndoRedo::AppendUndo(), SwIndex::Assign(), SwNodeIndex::Assign(), SwNodeRange::aStart, CopyAll, sw::CopyBookmarks(), SwTextNode::CopyCollFormat(), CopyFlyInFlyImpl(), SwTextNode::CopyText(), CopyWithFlyInFly(), SwDoc::CreateUnoCursor(), DeleteRedlines, IDocumentUndoRedo::DoesUndo(), SwPaM::End(), SwPaM::Exchange(), fnMoveBackward, fnMoveForward, IDocumentMarkAccess::getAllMarksCount(), SwFormatAnchor::GetAnchorId(), SwDoc::GetAttrPool(), SwNode::GetContentNode(), SwNode::GetDoc(), sw::GetFlysAnchoredAt(), SwUndoInserts::GetFlysAnchoredAt(), SwDoc::getIDocumentContentOperations(), SwDoc::getIDocumentMarkAccess(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::getIDocumentStylePoolAccess(), SwDoc::GetIDocumentUndoRedo(), SwIndex::GetIndex(), SwNodeIndex::GetIndex(), SwPaM::GetMark(), SwNodeIndex::GetNode(), GetNode(), SwDoc::GetNodes(), SwDoc::GetOutlineNumRule(), SwPaM::GetPageNum(), SwPaM::GetPoint(), SwContentNode::GetpSwAttrSet(), IDocumentRedlineAccess::GetRedlineFlags(), SwTextNode::GetText(), IDocumentStylePoolAccess::GetTextCollFromPool(), SwNode::GetTextNode(), GoInContent(), GoInNode(), SwPaM::HasMark(), SwContentNode::HasSwAttrSet(), Ignore, SwDoc::IsClipBoard(), SwDoc::IsColumnSelection(), SwNode::IsContentNode(), sw::IsEmptyRange(), SwTextNode::IsInList(), SwDoc::IsInsOnlyTextGlossary(), SwTextNode::Len(), m_rDoc, SwTextNode::MakeCopy(), SwNodes::MakeTextNode(), SwPaM::Move(), SwPosition::nContent, SwPosition::nNode, NUMRULE_STATE, POP_NUMRULE_STATE, PUSH_NUMRULE_STATE, SfxItemSet::Put(), RES_POOLCOLL_STANDARD, SwTextNode::ResetAttr(), SwDoc::SearchNumRule(), SwFormatAnchor::SetAnchor(), SwTextNode::SetAttr(), SwUndoInserts::SetInsertRange(), SwPaM::SetMark(), IDocumentState::SetModified(), SwDoc::SetNumRule(), SwDoc::SetOutlineNumRule(), IDocumentRedlineAccess::SetRedlineFlags_intern(), IDocumentContentOperations::SplitNode(), and SwPaM::Start().
Referenced by CopyImpl().
|
overridevirtual |
Copy a selected content range to a position.
The position can be in the same or in an another document. It can also be within the range!
Normally this function should work only with content nodes. But there is a special case used by SwDoc::Paste, which starts the SwPaM at the content start node. This position doesn't contain any content:
This is important, because it prevents merging of the first node of the range into the node pointed to by rPos
. As a result this keeps all properties of the first real content node, which is the 2nd, including the Flys and the page description. In this case the first (fake) node is silently dropped and all other nodes are just copied.
rPam | The source node range to copy |
rPos | The target copy destination |
flags | SwCopyFlags::CheckPos: If this function should check if rPos is in a fly frame anchored in rPam. If false, then no such check will be performed, and it is assumed that the caller took care of verifying this constraint already. |
Implements IDocumentContentOperations.
Definition at line 2018 of file DocumentContentOperationsManager.cxx.
References IDocumentRedlineAccess::AppendRedline(), CheckPosInFly, CopyImpl(), SwRedlineTable::empty(), SwPaM::End(), SwNode::GetDoc(), SwDoc::getIDocumentRedlineAccess(), SwIndex::GetIndex(), SwNodeIndex::GetIndex(), SwNodeIndex::GetNode(), SwDoc::GetNodes(), IDocumentRedlineAccess::GetRedlineFlags(), IDocumentRedlineAccess::GetRedlineTable(), SwPaM::HasMark(), SwDoc::IsClipBoard(), SwDoc::IsColumnSelection(), SwNode::IsContentNode(), sw::IsEmptyRange(), IDocumentRedlineAccess::IsIgnoreRedline(), IDocumentRedlineAccess::IsRedlineOn(), SwNode::IsTextNode(), m_rDoc, SwPosition::nContent, SwPosition::nNode, IDocumentRedlineAccess::SetRedlineFlags_intern(), IDocumentRedlineAccess::SplitRedline(), and SwPaM::Start().
void sw::DocumentContentOperationsManager::CopyWithFlyInFly | ( | const SwNodeRange & | rRg, |
const SwNodeIndex & | rInsPos, | ||
const std::pair< const SwPaM &, const SwPosition & > * | pCopiedPaM = nullptr , |
||
bool | bMakeNewFrames = true , |
||
bool | bDelRedlines = true , |
||
bool | bCopyFlyAtFly = false , |
||
SwCopyFlags | flags = SwCopyFlags::Default |
||
) | const |
note: rRg/rInsPos exclude a partially selected start text node; pCopiedPaM includes a partially selected start text node
Definition at line 3641 of file DocumentContentOperationsManager.cxx.
References SwNodeRange::aEnd, SwNodeRange::aStart, sw::CopyBookmarks(), CopyFlyInFlyImpl(), SwNodes::CopyNodes(), SwNodes::DelDummyNodes(), DeleteRedlines, SwContentNode::DelFrames(), o3tl::sorted_vector< Value, Compare, Find, class >::empty(), o3tl::sorted_vector< Value, Compare, Find, class >::end(), end, o3tl::sorted_vector< Value, Compare, Find, class >::erase(), o3tl::sorted_vector< Value, Compare, Find, class >::find(), SwNode::FindSectionNode(), SwIterator< TElementType, TSource, eMode >::First(), IDocumentMarkAccess::getAllMarksCount(), SwNode::GetDoc(), SwDoc::getIDocumentMarkAccess(), SwDoc::getIDocumentRedlineAccess(), SwDoc::GetIDocumentUndoRedo(), SwNodeIndex::GetIndex(), SwNode::GetIndex(), SwNodeIndex::GetNode(), SwDoc::GetNodes(), SwNode::GetNodeType(), IDocumentRedlineAccess::GetRedlineFlags(), SwNode::GetTextNode(), o3tl::sorted_vector< Value, Compare, Find, class >::insert(), SwNode::IsEndNode(), SwNode::IsSectionNode(), SwNode::IsStartNode(), m_rDoc, MakeFrames(), SwIterator< TElementType, TSource, eMode >::Next(), sw::RecreateStartTextFrames(), SaveRedlEndPosForRestore::Restore(), and Start.
Referenced by SwTextFootnote::CopyFootnote(), CopyImplImpl(), sw::DocumentLayoutManager::CopyLayoutFormat(), SwRangeRedline::CopyToSection(), lcl_CopyBoxToDoc(), and SwDoc::SplitDoc().
|
overridevirtual |
complete delete of a given PaM
Implements IDocumentContentOperations.
Definition at line 2336 of file DocumentContentOperationsManager.cxx.
References DeleteAndJoinImpl(), DeleteAndJoinWithRedlineImpl(), SwDoc::getIDocumentRedlineAccess(), IDocumentRedlineAccess::IsRedlineOn(), and m_rDoc.
|
private |
Definition at line 4246 of file DocumentContentOperationsManager.cxx.
References IDocumentRedlineAccess::CompressRedlines(), DeleteRangeImpl(), SwRedlineTable::empty(), SwDoc::getIDocumentRedlineAccess(), IDocumentRedlineAccess::GetRedlineTable(), IDocumentRedlineAccess::IsIgnoreRedline(), m_rDoc, sw_GetJoinFlags(), and sw_JoinText().
Referenced by DeleteAndJoin(), and ReplaceRange().
|
private |
Definition at line 4104 of file DocumentContentOperationsManager.cxx.
References IDocumentRedlineAccess::AcceptRedlineParagraphFormatting(), IDocumentRedlineAccess::AppendRedline(), IDocumentUndoRedo::AppendUndo(), SwDoc::CreateUnoCursor(), DELETE, IDocumentUndoRedo::DoesGroupUndo(), IDocumentUndoRedo::DoesUndo(), EMPTY, SwPaM::End(), IDocumentUndoRedo::EndUndo(), sw::GetAllValidRanges(), SwDoc::getIDocumentMarkAccess(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), sw::UndoManager::GetLastUndo(), SwPaM::GetMark(), SwPaM::GetPoint(), IDocumentRedlineAccess::GetRedlineFlags(), SwDoc::GetUndoManager(), IDocumentRedlineAccess::IsRedlineOn(), m_rDoc, On, SAL_WARN_IF, IDocumentState::SetModified(), IDocumentRedlineAccess::SetRedlineFlags(), ShowDelete, ShowInsert, ShowMask, SwPaM::Start(), IDocumentUndoRedo::StartUndo(), and sw::UpdateFramesForAddDeleteRedline().
Referenced by DeleteAndJoin(), and ReplaceRange().
void sw::DocumentContentOperationsManager::DeleteDummyChar | ( | SwPosition const & | rPos, |
sal_Unicode | cDummy | ||
) |
Definition at line 2120 of file DocumentContentOperationsManager.cxx.
References IDocumentRedlineAccess::CompressRedlines(), DeleteRangeImpl(), SwRedlineTable::empty(), SwDoc::getIDocumentRedlineAccess(), SwPaM::GetPoint(), IDocumentRedlineAccess::GetRedlineTable(), SwPaM::GetText(), IDocumentRedlineAccess::IsIgnoreRedline(), m_rDoc, SwPosition::nContent, and void().
Delete a range SwFlyFrameFormat.
Implements IDocumentContentOperations.
Definition at line 2137 of file DocumentContentOperationsManager.cxx.
References IDocumentRedlineAccess::CompressRedlines(), DeleteRangeImpl(), SwRedlineTable::empty(), SwDoc::getIDocumentRedlineAccess(), IDocumentRedlineAccess::GetRedlineTable(), IDocumentRedlineAccess::IsIgnoreRedline(), and m_rDoc.
Referenced by RemoveLeadingWhiteSpace().
|
private |
Definition at line 4269 of file DocumentContentOperationsManager.cxx.
References DeleteRangeImplImpl(), SwPaM::GetMark(), SwPaM::GetPoint(), and PaMCorrAbs().
Referenced by DeleteAndJoinImpl(), DeleteDummyChar(), and DeleteRange().
|
private |
Definition at line 4285 of file DocumentContentOperationsManager.cxx.
References IDocumentUndoRedo::AppendUndo(), SwIndex::Assign(), SwAutoCorrExceptWord::CheckDelChar(), IDocumentUndoRedo::ClearRedo(), SwNodes::Count(), SwpHints::Count(), SwpHints::Cut(), DelBookmarks(), SwNodes::Delete(), SwDoc::DeleteAutoCorrExceptWord(), SwPaM::DeleteMark(), IDocumentRedlineAccess::DeleteRedline(), DelFlyInRange(), SwTextNode::DestroyAttr(), IDocumentUndoRedo::DoesGroupUndo(), IDocumentUndoRedo::DoesUndo(), SwRedlineTable::empty(), SwTextAttr::End(), SwPaM::End(), SwpHints::Get(), SwDoc::GetAutoCorrExceptWord(), SwNode::GetContentNode(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwIndex::GetIndex(), SwNodeIndex::GetIndex(), SwNode::GetIndex(), sw::UndoManager::GetLastUndo(), SwPaM::GetMark(), SwNodeIndex::GetNode(), SwDoc::GetNodes(), SwPaM::GetPoint(), SwTextNode::GetpSwpHints(), IDocumentRedlineAccess::GetRedlineTable(), SwTextAttr::GetStart(), SwNode::GetTextNode(), SwDoc::GetUndoManager(), SwPaM::HasMark(), SwAutoCorrExceptWord::IsDeleted(), IsFlySelectedByCursor(), IDocumentRedlineAccess::IsIgnoreRedline(), SwNode::IsSectionNode(), SwContentNode::Len(), m_rDoc, SwPosition::nContent, SwPosition::nNode, SwNodes::SectionUp(), IDocumentState::SetModified(), SwPaM::Start(), and SwNode::StartOfSectionNode().
Referenced by DeleteRangeImpl().
Delete a full Section of the NodeArray.
The passed Node is located somewhere in the designated Section.
Implements IDocumentContentOperations.
Definition at line 2098 of file DocumentContentOperationsManager.cxx.
References SwDoc::CorrAbs(), DelBookmarks(), IDocumentRedlineAccess::DeleteRedline(), DelFlyInRange(), SwNodes::DelNodes(), SwNode::EndOfSectionNode(), SwDoc::getIDocumentRedlineAccess(), SwDoc::GetNodes(), SwNode::IsStartNode(), m_rDoc, and SwNode::StartOfSectionNode().
|
overridevirtual |
Delete full paragraphs.
Implements IDocumentContentOperations.
Definition at line 2148 of file DocumentContentOperationsManager.cxx.
References SwNodeRange::aEnd, IDocumentUndoRedo::AppendUndo(), SwIndex::Assign(), SwNodeRange::aStart, CH_TXT_ATR_FIELDEND, CH_TXT_ATR_FIELDSEP, CH_TXT_ATR_FIELDSTART, IDocumentUndoRedo::ClearRedo(), SwDoc::CorrAbs(), SwNodes::Count(), SwNodes::Delete(), SwPaM::DeleteMark(), IDocumentMarkAccess::deleteMark(), IDocumentLayoutAccess::DelLayoutFormat(), IDocumentUndoRedo::DoesUndo(), SwPaM::End(), SwNode::EndOfSectionIndex(), SwPaM::Exchange(), fnMoveBackward, fnMoveForward, SwFormat::GetAnchor(), SwFormatAnchor::GetAnchorId(), SwFormatAnchor::GetContentAnchor(), SwNode::GetContentNode(), IDocumentMarkAccess::getFieldmarkAt(), IDocumentMarkAccess::getFieldmarkFor(), SwTable::GetFrameFormat(), SwDoc::getIDocumentLayoutAccess(), SwDoc::getIDocumentMarkAccess(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwNodeIndex::GetIndex(), SfxItemSet::GetItemState(), SwPaM::GetMark(), SwNodeIndex::GetNode(), SwDoc::GetNodes(), SwPaM::GetPoint(), SwDoc::GetSpzFrameFormats(), SwTableNode::GetTable(), SwNode::GetTextNode(), GoInNode(), SwNodes::GoNext(), SwPaM::HasMark(), i, SwNode::IsContentNode(), sw::mark::IsFieldmarkOverlap(), IDocumentRedlineAccess::IsRedlineOn(), m_rDoc, SwContentNode::MakeEndIndex(), SwContentNode::MakeStartIndex(), SwPaM::Move(), SwPosition::nContent, SwPosition::nNode, SwPaM::Normalize(), PaMCorrAbs(), SAL_WARN, SwFormat::SetFormatAttr(), SwPaM::SetMark(), IDocumentState::SetModified(), SwFrameFormats::size(), SwPaM::Start(), SwNode::StartOfSectionIndex(), and SwNode::StartOfSectionNode().
|
overridevirtual |
Did the last inserted string come from IME?
Implements IDocumentContentOperations.
Definition at line 2950 of file DocumentContentOperationsManager.cxx.
References m_bIME.
|
overridevirtual |
Insert a DrawObject.
The object must be already registered in DrawModel.
Implements IDocumentContentOperations.
Definition at line 3183 of file DocumentContentOperationsManager.cxx.
References IDocumentUndoRedo::AppendUndo(), CheckControlLayer(), IDocumentUndoRedo::DoesUndo(), SwNode::FindFlyStartNode(), SwFormat::GetAnchor(), SwDrawContact::GetAnchorFrame(), SwFormatAnchor::GetAnchorId(), SwFormatAnchor::GetContentAnchor(), IDocumentLayoutAccess::GetCurrentViewShell(), SwDoc::GetDfltFrameFormat(), SwDoc::getIDocumentLayoutAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwIndex::GetIndex(), SfxItemSet::GetItemIfSet(), SwNodeIndex::GetNode(), SwPaM::GetNode(), SwPaM::GetPoint(), SwNode::GetTextNode(), SwTextNode::InsertItem(), SwDoc::IsInHeaderFooter(), m_rDoc, SwDoc::MakeDrawFrameFormat(), SwDrawFrameFormat::MakeFrames(), SwContact::MoveObjToVisibleLayer(), SwPosition::nContent, SwPosition::nNode, RES_ANCHOR(), SwFormat::SetFormatAttr(), and IDocumentState::SetModified().
|
overridevirtual |
Insert OLE-objects.
Implements IDocumentContentOperations.
Definition at line 3117 of file DocumentContentOperationsManager.cxx.
References SwDoc::GetDfltGrfFormatColl(), SwNodes::GetEndOfAutotext(), IDocumentStylePoolAccess::GetFrameFormatFromPool(), SwDoc::getIDocumentStylePoolAccess(), SwDoc::GetNodes(), SwPaM::GetPoint(), InsNoTextNode(), svt::EmbeddedObjectRef::is(), SotExchange::IsMath(), m_rDoc, SwNodes::MakeOLENode(), nId, RES_POOLFRM_FORMEL, and RES_POOLFRM_OLE.
|
overridevirtual |
Insert graphic or formula.
The XXXX are copied.
Implements IDocumentContentOperations.
Definition at line 3083 of file DocumentContentOperationsManager.cxx.
References SwDoc::GetDfltGrfFormatColl(), SwNodes::GetEndOfAutotext(), IDocumentStylePoolAccess::GetFrameFormatFromPool(), SwDoc::getIDocumentStylePoolAccess(), SwDoc::GetNodes(), SwPaM::GetPoint(), InsNoTextNode(), m_rDoc, SwNodes::MakeGrfNode(), and RES_POOLFRM_GRAPHIC.
|
overridevirtual |
Implements IDocumentContentOperations.
Definition at line 3103 of file DocumentContentOperationsManager.cxx.
References SwDoc::GetDfltGrfFormatColl(), SwNodes::GetEndOfAutotext(), IDocumentStylePoolAccess::GetFrameFormatFromPool(), SwDoc::getIDocumentStylePoolAccess(), SwDoc::GetNodes(), SwPaM::GetPoint(), InsNoTextNode(), m_rDoc, SwNodes::MakeGrfNode(), and RES_POOLFRM_GRAPHIC.
|
overridevirtual |
Implements IDocumentContentOperations.
Definition at line 3588 of file DocumentContentOperationsManager.cxx.
References IDocumentUndoRedo::AppendUndo(), IDocumentUndoRedo::ClearRedo(), IDocumentUndoRedo::DoesUndo(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), m_rDoc, and IDocumentState::SetModified().
Referenced by ReplaceRangeImpl().
|
overridevirtual |
Implements IDocumentContentOperations.
Definition at line 3141 of file DocumentContentOperationsManager.cxx.
References SwDoc::GetDfltGrfFormatColl(), SwNodes::GetEndOfAutotext(), IDocumentStylePoolAccess::GetFrameFormatFromPool(), SwDoc::getIDocumentStylePoolAccess(), SwDoc::GetNodes(), SwPaM::GetPoint(), InsNoTextNode(), m_rDoc, SwNodes::MakeOLENode(), and RES_POOLFRM_OLE.
|
overridevirtual |
Insert an attribute.
If rRg spans several nodes the attribute is split, provided it makes sense. Nodes, where this attribute does not make sense are ignored. In nodes completely enclosed in the selection the attribute becomes hard-formatted, in all other (text-) nodes the attribute is inserted into the attribute array. For a character attribute, in cases where no selection exists an "empty" hint is inserted. If there is a selection the attribute is hard-formatted and added to the node at rRg.Start(). If the attribute could not be inserted, the method returns false.
Implements IDocumentContentOperations.
Definition at line 3554 of file DocumentContentOperationsManager.cxx.
References IDocumentUndoRedo::AppendUndo(), IDocumentUndoRedo::ClearRedo(), IDocumentUndoRedo::DoesUndo(), SwDoc::GetAttrPool(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), utl::ConfigManager::IsFuzzing(), m_rDoc, SfxItemSet::Put(), IDocumentState::SetModified(), and SfxPoolItem::Which().
|
overridevirtual |
Insert string into existing text node at position rRg.Point().
Implements IDocumentContentOperations.
Definition at line 2840 of file DocumentContentOperationsManager.cxx.
References IDocumentRedlineAccess::AcceptRedlineParagraphFormatting(), IDocumentRedlineAccess::AppendRedline(), IDocumentUndoRedo::AppendUndo(), SwUndoInsert::CanGrouping(), SwAutoCorrExceptWord::CheckChar(), IDocumentUndoRedo::ClearRedo(), SwDoc::DeleteAutoCorrExceptWord(), IDocumentUndoRedo::DoesGroupUndo(), IDocumentUndoRedo::DoesUndo(), SwRedlineTable::empty(), FORCEHINTEXPAND, GetAppCharClass(), SwDoc::GetAutoCorrExceptWord(), SwDataChanged::GetContent(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwIndex::GetIndex(), sw::UndoManager::GetLastUndo(), SwNodeIndex::GetNode(), SwPaM::GetPoint(), IDocumentRedlineAccess::GetRedlineFlags(), IDocumentRedlineAccess::GetRedlineTable(), SwNode::GetTextNode(), SwDoc::GetUndoManager(), i, SwTextNode::InsertText(), SwAutoCorrExceptWord::IsDeleted(), IDocumentRedlineAccess::IsIgnoreRedline(), CharClass::isLetterNumeric(), IDocumentRedlineAccess::IsRedlineOn(), m_rDoc, SwPosition::nContent, SwPosition::nNode, IDocumentState::SetModified(), IDocumentRedlineAccess::SetRedlineFlags(), and IDocumentRedlineAccess::SplitRedline().
Referenced by sw::mark::DateFieldmark::ReplaceContent(), and ReplaceRangeImpl().
|
private |
Definition at line 4727 of file DocumentContentOperationsManager.cxx.
References m_rDoc, SwDoc::MakeFlySection_(), and SwContentNode::SetAttr().
Referenced by InsertEmbObject(), InsertGraphic(), InsertGraphicObject(), and InsertOLE().
pArgs contains the document's ChrFormatTable Is need for selections at the beginning/end and with no SSelection.
Definition at line 4061 of file DocumentContentOperationsManager.cxx.
References sw::DocumentContentOperationsManager::ParaRstFormat::bExactRange, sw::DocumentContentOperationsManager::ParaRstFormat::bInclRefToxMark, SwpHints::DeRegister(), SwIndex::GetIndex(), SwNodeIndex::GetNode(), SwTextNode::GetpSwpHints(), SwNode::GetRedlineMergeFlag(), SwNode::GetTextNode(), SwRootFrame::HasMergedParas(), SwNode::Hidden, SwTextNode::Len(), SwPosition::nContent, SwPosition::nNode, sw::DocumentContentOperationsManager::ParaRstFormat::nWhich, sw::DocumentContentOperationsManager::ParaRstFormat::pDelSet, sw::DocumentContentOperationsManager::ParaRstFormat::pEndNd, sw::DocumentContentOperationsManager::ParaRstFormat::pHistory, sw::DocumentContentOperationsManager::ParaRstFormat::pLayout, sw::DocumentContentOperationsManager::ParaRstFormat::pSttNd, SwpHints::Register(), and SwTextNode::RstTextAttr().
Referenced by SwDoc::ResetAttrs(), and SwDoc::RstTextAttrs().
|
overridevirtual |
Move a range.
Implements IDocumentContentOperations.
Definition at line 2709 of file DocumentContentOperationsManager.cxx.
References SwContentNode::CanJoinNext(), SwDoc::CorrRel(), DEFAULT, SwPaM::GetMark(), SwNodeIndex::GetNode(), SwPaM::GetPoint(), SwTextNode::GetText(), SwNode::GetTextNode(), SwNode::IsTextNode(), SwTextNode::JoinNext(), m_rDoc, MoveRange(), SwPosition::nNode, and SwPaM::Start().
|
overridevirtual |
Implements IDocumentContentOperations.
Definition at line 2577 of file DocumentContentOperationsManager.cxx.
References SwNodeRange::aEnd, IDocumentUndoRedo::AppendUndo(), SwIndex::Assign(), SwNodeRange::aStart, o3tl::sorted_vector< Value, Compare, Find, class >::clear(), SwRedlineTable::Contains(), CREATEUNDOOBJ, DelBookmarks(), IDocumentUndoRedo::DoesUndo(), o3tl::sorted_vector< Value, Compare, Find, class >::empty(), SwFrameFormats::empty(), SwRedlineTable::empty(), SwPaM::End(), SwNode::GetContentNode(), SwDoc::GetFootnoteIdxs(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwNodeIndex::GetIndex(), SwNodeIndex::GetNode(), SwDoc::GetNodes(), IDocumentRedlineAccess::GetRedlinePos(), IDocumentRedlineAccess::GetRedlineTable(), SwDoc::GetSpzFrameFormats(), o3tl::sorted_vector< Value, Compare, Find, class >::insert(), m_rDoc, SwNodes::MoveNodes(), SwPosition::nContent, SwPosition::nNode, NO_DELFRMS, SwRedlineTable::npos, REDLINES, RestFlyInRange(), SaveFlyInRange(), IDocumentState::SetModified(), SwRedlineTable::size(), SwPaM::Start(), and SwFootnoteIdxs::UpdateAllFootnote().
|
overridevirtual |
Implements IDocumentContentOperations.
Definition at line 2351 of file DocumentContentOperationsManager.cxx.
References ALLFLYS, SwIndex::Assign(), SwContentNode::CanJoinNext(), o3tl::sorted_vector< Value, Compare, Find, class >::clear(), IDocumentUndoRedo::ClearRedo(), sw::mark::ContentIdxStore::Create(), DelBookmarks(), SwPaM::DeleteMark(), IDocumentUndoRedo::DoesUndo(), eMode, o3tl::sorted_vector< Value, Compare, Find, class >::empty(), SwRedlineTable::empty(), SwPaM::End(), SwPaM::Exchange(), fnMoveBackward, fnMoveForward, SwNode::GetContentNode(), SwPaM::GetContentNode(), SwDoc::GetFootnoteIdxs(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwIndex::GetIdxReg(), SwIndex::GetIndex(), SwNodeIndex::GetIndex(), SwNode::GetIndex(), SwPaM::GetMark(), SwNodeIndex::GetNode(), SwPaM::GetNode(), SwDoc::GetNodes(), SwPaM::GetPoint(), IDocumentRedlineAccess::GetRedlineTable(), SwNode::GetTextNode(), GoInContent(), SwPaM::HasMark(), o3tl::sorted_vector< Value, Compare, Find, class >::insert(), sw::mark::IsFieldmarkOverlap(), SwTextNode::JoinNext(), SwTextNode::Len(), m_rDoc, SwPaM::Move(), SwNodes::MoveRange(), SwPosition::nContent, SwPosition::nNode, REDLINES, RestFlyInRange(), SaveFlyInRange(), SwPaM::SetMark(), IDocumentState::SetModified(), SwTextNode::SplitContentNode(), SwPaM::Start(), SwFootnoteIdxs::UpdateAllFootnote(), and void().
Referenced by MoveAndJoin().
|
privatedelete |
|
overridevirtual |
Overwrite string in an existing text node.
Implements IDocumentContentOperations.
Definition at line 2737 of file DocumentContentOperationsManager.cxx.
References IDocumentRedlineAccess::AppendRedline(), IDocumentUndoRedo::AppendUndo(), SwUndoOverwrite::CanGrouping(), SwAutoCorrExceptWord::CheckChar(), IDocumentUndoRedo::ClearRedo(), SwpHints::Count(), SwDoc::DeleteAutoCorrExceptWord(), IDocumentRedlineAccess::DeleteRedline(), IDocumentUndoRedo::DoesGroupUndo(), IDocumentUndoRedo::DoesUndo(), SwRedlineTable::empty(), EMPTYEXPAND, SwTextNode::EraseText(), SwDoc::GetAutoCorrExceptWord(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwIndex::GetIndex(), sw::UndoManager::GetLastUndo(), getLength(), SwPaM::GetPoint(), SwTextNode::GetpSwpHints(), IDocumentRedlineAccess::GetRedlineTable(), SwTextNode::GetSpaceLeft(), SwNode::GetTextNode(), SwDoc::GetUndoManager(), SwTextNode::InsertText(), SwNode::IsIgnoreDontExpand(), IDocumentRedlineAccess::IsIgnoreRedline(), IDocumentRedlineAccess::IsRedlineOn(), m_rDoc, SwNode::SetIgnoreDontExpand(), IDocumentState::SetModified(), and SwTextNode::TriggerNodeUpdate().
|
overridevirtual |
Removes any leading white space from the paragraph.
Implements IDocumentContentOperations.
Definition at line 3610 of file DocumentContentOperationsManager.cxx.
References DeleteRange(), SwPaM::GetMark(), SwNodeIndex::GetNode(), SwPaM::GetPoint(), SwTextNode::GetText(), SwNode::GetTextNode(), SwPosition::nContent, SwPosition::nNode, and SwPaM::SetMark().
|
overridevirtual |
Replace selected range in a TextNode with string.
Intended for search & replace. bRegExpRplc - replace tabs (\t) and insert the found string ( not & ). E.g.: Find: "zzz", Replace: "xx\t\\t..&..\&" –> "xx\t<Tab>..zzz..&"
Implements IDocumentContentOperations.
Definition at line 3474 of file DocumentContentOperationsManager.cxx.
References sw::CalcBreaks(), DeleteAndJoinImpl(), DeleteAndJoinWithRedlineImpl(), SwPaM::DeleteMark(), SwPaM::End(), fnMoveBackward, SwNodes::GetEndOfContent(), SwDoc::getIDocumentRedlineAccess(), SwIndex::GetIndex(), SwNodeIndex::GetIndex(), SwPaM::GetMark(), SwNodeIndex::GetNodes(), SwDoc::GetNodes(), SwPaM::GetPoint(), IDocumentRedlineAccess::IsRedlineOn(), m_rDoc, SwPaM::Move(), SwPosition::nContent, SwPosition::nNode, SwPaM::Normalize(), ReplaceRangeImpl(), and SwPaM::Start().
Referenced by sw::mark::DateFieldmark::ReplaceContent().
|
private |
Definition at line 4482 of file DocumentContentOperationsManager.cxx.
References IDocumentRedlineAccess::AppendRedline(), IDocumentUndoRedo::AppendUndo(), SwIndex::Assign(), IDocumentMarkAccess::deleteMark(), IDocumentRedlineAccess::DeleteRedline(), IDocumentUndoRedo::DoesUndo(), EMPTY, SwRedlineTable::empty(), SwPaM::End(), IDocumentUndoRedo::EndUndo(), SwPaM::Exchange(), false, fnMoveBackward, SwDoc::GetAttrPool(), SwNode::GetContentNode(), SwDoc::getIDocumentMarkAccess(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwIndex::GetIndex(), SwNodeIndex::GetIndex(), SwNode::GetIndex(), SwIndex::GetMark(), SwPaM::GetMark(), SwNodeIndex::GetNode(), SwTextNode::GetParaAttr(), SwPaM::GetPoint(), IDocumentRedlineAccess::GetRedlineFlags(), IDocumentRedlineAccess::GetRedlineTable(), SwTextNode::GetText(), SwNode::GetTextNode(), SwPaM::HasMark(), InsertItemSet(), InsertString(), IDocumentRedlineAccess::IsIgnoreRedline(), IDocumentRedlineAccess::IsRedlineOn(), m_rDoc, IDocumentMarkAccess::makeMark(), SwPaM::Move(), SwPosition::nContent, sw::mark::New, SwPosition::nNode, On, PaMCorrAbs(), REPLACE, SwTextNode::ReplaceText(), RES_CHRATR_BEGIN(), RES_TXTATR_INETFMT(), RES_TXTATR_META(), RES_TXTATR_TOXMARK(), RES_TXTATR_WITHEND_END(), RES_UNKNOWNATR_BEGIN(), SwDoc::RstTextAttrs(), SAL_WARN_IF, SwUndoReplace::SetEnd(), SwPaM::SetMark(), IDocumentState::SetModified(), IDocumentRedlineAccess::SetRedlineFlags(), ShowDelete, ShowInsert, ShowMask, SplitNode(), IDocumentUndoRedo::StartUndo(), sw_GetJoinFlags(), sw_JoinText(), and IDocumentMarkAccess::UNO_BOOKMARK.
Referenced by ReplaceRange().
|
overridevirtual |
Transpose graphic (with undo)
Implements IDocumentContentOperations.
Definition at line 3159 of file DocumentContentOperationsManager.cxx.
References IDocumentUndoRedo::AppendUndo(), IDocumentUndoRedo::DoesUndo(), Dont, SwNode::GetGrfNode(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwNodeIndex::GetIndex(), SwPaM::GetMark(), SwNodeIndex::GetNode(), SwPaM::GetPoint(), SwContentNode::GetSwAttrSet(), SwPaM::HasMark(), m_rDoc, SwPosition::nNode, SwGrfNode::ReRead(), SwContentNode::SetAttr(), and IDocumentState::SetModified().
|
overridevirtual |
States that the last inserted string came from IME.
Implements IDocumentContentOperations.
Definition at line 2945 of file DocumentContentOperationsManager.cxx.
References m_bIME.
|
overridevirtual |
Split a node at rPos (implemented only for TextNode).
Implements IDocumentContentOperations.
Definition at line 3294 of file DocumentContentOperationsManager.cxx.
References IDocumentRedlineAccess::AppendRedline(), IDocumentUndoRedo::AppendUndo(), IDocumentUndoRedo::ClearRedo(), sw::mark::ContentIdxStore::Create(), IDocumentUndoRedo::DoesUndo(), eMode, SwRedlineTable::empty(), sw::mark::Flys, fnMoveBackward, SwNode::GetContentNode(), SwNodes::GetEndOfExtras(), SwTable::GetFrameFormat(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::getIDocumentStylePoolAccess(), SwDoc::GetIDocumentUndoRedo(), SwIndex::GetIndex(), SwNodeIndex::GetIndex(), SwNode::GetIndex(), SwFormat::GetItemState(), SwNodeIndex::GetNode(), SwDoc::GetNodes(), IDocumentRedlineAccess::GetRedlineTable(), SwTableNode::GetTable(), IDocumentStylePoolAccess::GetTextCollFromPool(), SwNode::GetTextNode(), SwNode::IsContentNode(), SwNode::IsEndNode(), IDocumentRedlineAccess::IsIgnoreRedline(), IDocumentRedlineAccess::IsRedlineOn(), SwNode::IsStartNode(), SwNode::IsTableNode(), SwNode::IsTextNode(), SwTextNode::Len(), m_rDoc, SwNodes::MakeTextNode(), SwPaM::Move(), SwPosition::nContent, SwPosition::nNode, sw::mark::NonFlys, RES_POOLCOLL_TEXT, SwFormat::ResetFormatAttr(), SwTextNode::SetAttr(), SwPaM::SetMark(), IDocumentState::SetModified(), SwUndoSplitNode::SetTableFlag(), SwTextNode::SplitContentNode(), IDocumentRedlineAccess::SplitRedline(), SwNode::StartOfSectionNode(), SwTableBoxStartNode, and SwDoc::UpdateParRsid().
Referenced by ReplaceRangeImpl().
|
overridevirtual |
change text to Upper/Lower/Hiragana/Katakana/...
Implements IDocumentContentOperations.
Definition at line 2955 of file DocumentContentOperationsManager.cxx.
References IDocumentUndoRedo::AppendUndo(), IDocumentUndoRedo::DoesUndo(), SwPaM::End(), g_pBreakIt, SwBreakIt::GetBreakIter(), SwDoc::getIDocumentRedlineAccess(), SwDoc::getIDocumentState(), SwDoc::GetIDocumentUndoRedo(), SwIndex::GetIndex(), SwNodeIndex::GetIndex(), SwTextNode::GetLang(), SwBreakIt::GetLocale(), SwNodeIndex::GetNode(), SwTextNode::GetText(), SwNode::GetTextNode(), utl::TransliterationWrapper::getType(), IDocumentRedlineAccess::IsRedlineOn(), m_rDoc, SwPosition::nContent, SwPosition::nNode, IDocumentState::SetModified(), SwPaM::Start(), and SwTextNode::TransliterateText().
|
private |
Definition at line 161 of file DocumentContentOperationsManager.hxx.
|
private |
Definition at line 159 of file DocumentContentOperationsManager.hxx.
Referenced by AppendTextNode(), CopyFlyInFlyImpl(), CopyImplImpl(), CopyRange(), CopyWithFlyInFly(), DeleteAndJoin(), DeleteAndJoinImpl(), DeleteAndJoinWithRedlineImpl(), DeleteDummyChar(), DeleteRange(), DeleteRangeImplImpl(), DeleteSection(), DelFullPara(), InsertDrawObj(), InsertEmbObject(), InsertGraphic(), InsertGraphicObject(), InsertItemSet(), InsertOLE(), InsertPoolItem(), InsertString(), InsNoTextNode(), MoveAndJoin(), MoveNodeRange(), MoveRange(), Overwrite(), ReplaceRange(), ReplaceRangeImpl(), ReRead(), SplitNode(), and TransliterateText().