LibreOffice Module sw (master) 1
delete.cxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#include <hintids.hxx>
21#include <wrtsh.hxx>
22#include <swcrsr.hxx>
23#include <editeng/lrspitem.hxx>
24#include <view.hxx>
25#include <drawbase.hxx>
26#include <unobaseclass.hxx>
27#include <fmtanchr.hxx>
28#include <flyfrm.hxx>
29#include <ndtxt.hxx>
30#include <txtfld.hxx>
31#include <docufld.hxx>
32#include <IDocumentUndoRedo.hxx>
33#include <i18nutil/unicode.hxx>
34#include <o3tl/temporary.hxx>
35#include <rtl/character.hxx>
36#include <osl/diagnose.h>
37#include <doc.hxx>
39
41{
44 KillPams();
45 SetMark();
46}
47
48inline void SwWrtShell::CloseMark( bool bOkFlag )
49{
50 if( bOkFlag )
51 UpdateAttr();
52 else
53 SwapPam();
54
55 ClearMark();
57}
58
59
60
61// #i23725#
63{
64 bool bResult = false;
65
67 GetCurAttr(aAttrSet);
68
69 SvxLRSpaceItem aItem = aAttrSet.Get(RES_LR_SPACE);
70 short aOldFirstLineOfst = aItem.GetTextFirstLineOffset();
71
72 if (aOldFirstLineOfst > 0)
73 {
75 bResult = true;
76 }
77 else if (aOldFirstLineOfst < 0)
78 {
80 aItem.SetLeft(aItem.GetLeft() + aOldFirstLineOfst);
81
82 bResult = true;
83 }
84 else if (aItem.GetLeft() != 0)
85 {
86 aItem.SetLeft(0);
87 bResult = true;
88 }
89
90 if (bResult)
91 {
92 aAttrSet.Put(aItem);
93 SetAttrSet(aAttrSet);
94 }
95
96 return bResult;
97}
98
102{
103 SwActContext aActContext(this);
105 // remember the old cursor
106 Push();
107 ClearMark();
109 SetMark();
111
112 bool bRet = Delete(false);
114 if( bRet )
115 UpdateAttr();
116}
117
119{
120 OpenMark();
122 bool bRet = Delete(false);
123 CloseMark( bRet );
124}
125
127{
128 OpenMark();
130 bool bRet = Delete(false);
131 CloseMark( bRet );
132}
133
135{
136 // If it's a Fly, throw it away
137 SelectionType nSelType = GetSelectionType();
139 if( nCmp & nSelType )
140 {
141 // #108205# Remember object's position.
142 Point aTmpPt = GetObjRect().TopLeft();
143
145
146 // #108205# Set cursor to remembered position.
147 SetCursor(&aTmpPt);
148
151
152 nSelType = GetSelectionType();
153 if ( nCmp & nSelType )
154 {
156 GotoNextFly();
157 }
158
159 return true;
160 }
161
162 // If a selection exists, erase this
163 if ( IsSelection() )
164 {
165 if( !IsBlockMode() || HasSelection() )
166 {
167 //OS: Once again Basic: SwActContext must be leaved
168 //before EnterStdMode!
169 {
170 SwActContext aActContext(this);
172 Delete(false);
173 UpdateAttr();
174 }
175 if( IsBlockMode() )
176 {
177 NormalizePam();
178 ClearMark();
180 }
181 else
182 EnterStdMode();
183 return true;
184 }
185 else
186 EnterStdMode();
187 }
188
189 // JP 29.06.95: never erase a table standing in front of it.
190 bool bSwap = false;
191 const SwTableNode * pWasInTableNd = SwCursorShell::IsCursorInTable();
192
194 {
195 // Start/EndAllAction to avoid cursor flickering
198
199 // #i4032# Don't actually call a 'delete' if we
200 // changed the table cell, compare DelRight().
201 const SwStartNode * pSNdOld = pWasInTableNd ?
203 nullptr;
204
205 // If the cursor is at the beginning of a paragraph, try to step
206 // backwards. On failure we are done.
207 bool bDoSomething = SwCursorShell::Left(1,SwCursorSkipMode::Chars);
208
209 if (bDoSomething)
210 {
211 // If the cursor entered or left a table (or both) we are done.
212 const SwTableNode* pIsInTableNd = SwCursorShell::IsCursorInTable();
213 bDoSomething = pIsInTableNd == pWasInTableNd;
214
215 if (bDoSomething)
216 {
217 const SwStartNode* pSNdNew = pIsInTableNd ?
219 nullptr;
220
221 // #i4032# Don't actually call a 'delete' if we
222 // changed the table cell, compare DelRight().
223 bDoSomething = pSNdOld == pSNdNew;
224 }
225 }
226
227 if (!bDoSomething)
228 {
229 // tdf#115132 Restore previous position and we are done
231 return false;
232 }
233
235
236 OpenMark();
239 bSwap = true;
240 }
241 else
242 {
243 // If we are just to the right to a fieldmark, then remove it completely
244 const SwPosition* pCurPos = GetCursor()->GetPoint();
245 SwPosition aPrevChar(*pCurPos->GetContentNode(), pCurPos->GetContentIndex() - 1);
247 if (pFm && pFm->GetMarkEnd() == *pCurPos)
248 {
249 mxDoc->GetIDocumentUndoRedo().StartUndo(SwUndoId::EMPTY, nullptr);
252 mxDoc->GetIDocumentUndoRedo().EndUndo(SwUndoId::EMPTY, nullptr);
253 return true;
254 }
255
256 OpenMark();
258 if (SvtScriptType::ASIAN == GetScriptType())
259 {
260 sal_uInt32 nCode = GetChar(false);
261 if ( rtl::isSurrogate( nCode ) )
262 {
263 OUString sStr = GetSelText();
264 nCode = sStr.iterateCodePoints( &o3tl::temporary(sal_Int32(0)) );
265 }
266
268 {
271 OUString sStr = GetSelText();
272 nCode = sStr.iterateCodePoints( &o3tl::temporary(sal_Int32(0)) );
275 else
277 }
278 }
279 }
280 bool bRet = Delete(true);
281 if( !bRet && bSwap )
283 CloseMark( bRet );
284 if (!bRet)
285 { // false indicates HasReadonlySel failed
287 }
288 return bRet;
289}
290
291bool SwWrtShell::DelRight(bool const isReplaceHeuristic)
292{
293 // Will be or'ed, if a tableselection exists;
294 // will here be implemented on SelectionType::Table
295 bool bRet = false;
296 SelectionType nSelection = GetSelectionType();
297 if(nSelection & SelectionType::TableCell)
298 nSelection = SelectionType::Table;
299 if(nSelection & SelectionType::Text)
300 nSelection = SelectionType::Text;
301
302 switch( nSelection & ~SelectionType::Ornament & ~SelectionType::Media )
303 {
308 // If a selection exists, erase it.
309 if( IsSelection() )
310 {
311 if( !IsBlockMode() || HasSelection() )
312 {
313 //OS: And once again Basic: SwActContext must be
314 //leaved before EnterStdMode !
315 {
316 SwActContext aActContext(this);
318 Delete(isReplaceHeuristic);
319 UpdateAttr();
320 }
321 if( IsBlockMode() )
322 {
323 NormalizePam();
324 ClearMark();
326 }
327 else
328 EnterStdMode();
329 bRet = true;
330 break;
331 }
332 else
333 EnterStdMode();
334 }
335
337 {
338 // Start/EndAllAction to avoid cursor flickering
340
341 const SwTableNode* pWasInTableNd = IsCursorInTable();
342 // #108049# Save the startnode of the current cell
343 const SwStartNode* pSNdOld = pWasInTableNd ?
345 bool bCheckDelFull = SelectionType::Text & nSelection && SwCursorShell::IsSttPara();
346 bool bDelFull = false;
347 bool bDoNothing = false;
348
349 // #i41424# Introduced a couple of
350 // Push()-Pop() pairs here. The reason for this is that a
351 // Right()-Left() combination does not make sure, that
352 // the cursor will be in its initial state, because there
353 // may be a numbering in front of the next paragraph.
355
357 {
358 const SwTableNode* pCurrTableNd = IsCursorInTable();
359 bDelFull = bCheckDelFull && pCurrTableNd && pCurrTableNd != pWasInTableNd;
360 if (!bDelFull && (IsCursorInTable() || (pCurrTableNd != pWasInTableNd)))
361 {
362 // #108049# Save the startnode of the current cell.
363 // May be different to pSNdOld as we have moved.
364 const SwStartNode* pSNdNew = pCurrTableNd ?
366
367 // tdf#115132 Only keep cursor position instead of deleting
368 // if we have moved to a different cell
369 bDoNothing = pSNdOld != pSNdNew;
370 }
371 }
372
373 // restore cursor
375
376 if (bDelFull)
377 {
378 DelFullPara();
379 UpdateAttr();
380 }
381 if (bDelFull || bDoNothing)
382 break;
383 }
384
385 {
386 // If we are just ahead of a fieldmark, then remove it completely
388 if (pFm && pFm->GetMarkStart() == *GetCursor()->GetPoint())
389 {
390 mxDoc->GetIDocumentUndoRedo().StartUndo(SwUndoId::EMPTY, nullptr);
393 mxDoc->GetIDocumentUndoRedo().EndUndo(SwUndoId::EMPTY, nullptr);
394 bRet = true;
395 break;
396 }
397 }
398
399 OpenMark();
401 bRet = Delete(true);
402 CloseMark( bRet );
403 if (!bRet)
404 { // false indicates HasReadonlySel failed
406 }
407 break;
408
415 {
416 // Group deletion of the object and its comment together
417 // (also as-character anchor conversion at track changes)
418 mxDoc->GetIDocumentUndoRedo().StartUndo(SwUndoId::EMPTY, nullptr);
419
420 // #108205# Remember object's position.
421 Point aTmpPt = GetObjRect().TopLeft();
422
423 // Remember the anchor of the selected object before deletion.
424 std::optional<SwPosition> oAnchor;
425 RndStdIds eAnchorId = RndStdIds::FLY_AT_PARA;
427 SwFrameFormat* pFormat = nullptr;
428 if (pFly)
429 {
430 pFormat = pFly->GetFormat();
431 if (pFormat)
432 {
433 eAnchorId = pFormat->GetAnchor().GetAnchorId();
434 // to-character anchor conversion at track changes
435 if ( IsRedlineOn() && (eAnchorId != RndStdIds::FLY_AS_CHAR &&
436 eAnchorId != RndStdIds::FLY_AT_CHAR) )
437 {
439 GetFlyFrameAttr(aSet);
440 SwFormatAnchor aAnch(RndStdIds::FLY_AT_CHAR);
441 aSet.Put(aAnch);
442 SetFlyFrameAttr(aSet);
443 eAnchorId = pFormat->GetAnchor().GetAnchorId();
444 }
445 if ((eAnchorId == RndStdIds::FLY_AS_CHAR || eAnchorId == RndStdIds::FLY_AT_CHAR)
446 && pFormat->GetAnchor().GetContentAnchor())
447 {
448 oAnchor.emplace(*pFormat->GetAnchor().GetContentAnchor());
449 // set cursor before the anchor point
450 if ( IsRedlineOn() )
451 *GetCurrentShellCursor().GetPoint() = *oAnchor;
452 }
453 }
454 }
455
456 // track changes: create redline at anchor point of the image to record the deletion
457 if ( IsRedlineOn() && oAnchor && SelectionType::Graphic & nSelection && pFormat &&
458 ( eAnchorId == RndStdIds::FLY_AT_CHAR || eAnchorId == RndStdIds::FLY_AS_CHAR ) )
459 {
460 sal_Int32 nRedlineLength = 1;
461 // create a double CH_TXT_TRACKED_DUMMY_CHAR anchor point of the image to record the
462 // deletion, if needed (otherwise use the existing anchor point of the image anchored
463 // *as* character)
464 if ( eAnchorId == RndStdIds::FLY_AT_CHAR )
465 {
466 nRedlineLength = 2;
471 Insert( OUStringChar(CH_TXT_TRACKED_DUMMY_CHAR) +
472 OUStringChar(CH_TXT_TRACKED_DUMMY_CHAR) );
473 SwFormatAnchor anchor(RndStdIds::FLY_AT_CHAR);
475 anchor.SetAnchor(GetCursor()->GetPoint());
476 GetDoc()->SetAttr(anchor, *pFormat);
477 SetRedlineFlags( eOld );
479 }
480 OpenMark();
482 bRet = Delete(false);
483 CloseMark( bRet );
484 }
485 else
487
488 if (oAnchor)
489 {
490 SwTextNode* pTextNode = oAnchor->GetNode().GetTextNode();
491 if (pTextNode)
492 {
493 const SwTextField* pField(
494 pTextNode->GetFieldTextAttrAt(oAnchor->GetContentIndex(), ::sw::GetTextAttrMode::Default));
495 if (pField
496 && dynamic_cast<const SwPostItField*>(pField->GetFormatField().GetField()))
497 {
498 // Remove the comment of the deleted object.
499 *GetCurrentShellCursor().GetPoint() = *oAnchor;
500 DelRight();
501 }
502 }
503 }
504
505 mxDoc->GetIDocumentUndoRedo().EndUndo(SwUndoId::EMPTY, nullptr);
506
507 // #108205# Set cursor to remembered position.
508 SetCursor(&aTmpPt);
509
512 OSL_ENSURE( !IsFrameSelected(),
513 "<SwWrtShell::DelRight(..)> - <SwWrtShell::UnSelectFrame()> should unmark all objects" );
514 // leave draw mode, if necessary.
515 {
516 if (GetView().GetDrawFuncPtr())
517 {
519 GetView().SetDrawFuncPtr(nullptr);
520 }
521 if ( GetView().IsDrawMode() )
522 {
524 }
525 }
526 }
527
528 // <IsFrameSelected()> can't be true - see above.
529 {
530 nSelection = GetSelectionType();
531 if ( SelectionType::Frame & nSelection ||
532 SelectionType::Graphic & nSelection ||
533 SelectionType::Ole & nSelection ||
534 SelectionType::DrawObject & nSelection )
535 {
537 GotoNextFly();
538 }
539 }
540 bRet = true;
541 break;
542 default: break;
543 }
544 return bRet;
545}
546
548{
549 SwActContext aActContext(this);
551 Push();
552 SetMark();
554 {
556 return;
557 }
558 bool bRet = Delete(false);
560 if( bRet )
561 UpdateAttr();
562}
563
565{
566 SwActContext aActContext(this);
568 Push();
569 SetMark();
571 {
573 return;
574 }
575 bool bRet = Delete(false);
577 if( bRet )
578 UpdateAttr();
579}
580
581// All erase operations should work with Find instead with
582// Nxt-/PrvDelim, because the latter works with Wrap Around
583// -- that's probably not wished.
584
586{
587 if(IsStartOfDoc())
588 return;
589 OpenMark();
590 bool bRet = BwdSentence_() && Delete(false);
591 CloseMark( bRet );
592}
593
595{
596 if(IsEndOfDoc())
597 return false;
598 OpenMark();
599 bool bRet(false);
600 // fdo#60967: special case that is documented in help: delete
601 // paragraph following table if cursor is at end of last cell in table
602 if (IsEndOfTable())
603 {
604 Push();
605 ClearMark();
607 {
608 SetMark();
609 if (!IsEndPara()) // can only be at the end if it's empty
610 { // for an empty paragraph this would actually select the _next_
612 }
613 if (!IsEndOfDoc()) // do not delete last paragraph in body text
614 {
615 bRet = DelFullPara();
616 }
617 }
619 }
620 else
621 {
622 bRet = FwdSentence_() && Delete(false);
623 }
624 CloseMark( bRet );
625 return bRet;
626}
627
629{
630 if(IsEndOfDoc())
631 return;
632 SwActContext aActContext(this);
634 EnterStdMode();
635 SetMark();
636 if(IsEndWrd() && !IsStartWord())
637 NxtWrdForDelete(); // #i92468#
638 if(IsStartWord() || IsEndPara())
639 NxtWrdForDelete(); // #i92468#
640 else
641 EndWrd();
642
643 bool bRet = Delete(false);
644 if( bRet )
645 UpdateAttr();
646 else
647 SwapPam();
648 ClearMark();
649}
650
652{
653 if(IsStartOfDoc())
654 return;
655 SwActContext aActContext(this);
657 EnterStdMode();
658 SetMark();
659 if ( !IsStartWord() ||
660 !PrvWrdForDelete() ) // #i92468#
661 {
662 if (IsEndWrd() || IsSttPara())
663 PrvWrdForDelete(); // #i92468#
664 else
665 SttWrd();
666 }
667 bool bRet = Delete(false);
668 if( bRet )
669 UpdateAttr();
670 else
671 SwapPam();
672 ClearMark();
673}
674
675/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
@ Ignore
ignore Redlines
virtual ::sw::mark::IFieldmark * getFieldmarkAt(const SwPosition &rPos) const =0
get Fieldmark for CH_TXT_ATR_FIELDSTART/CH_TXT_ATR_FIELDEND at rPos
static void DeleteFieldmarkCommand(::sw::mark::IFieldmark const &rMark)
Definition: docbm.cxx:524
virtual std::unique_ptr< ILazyDeleter > deleteMark(const IDocumentMarkAccess::const_iterator_t &ppMark, bool isMoveNodes)=0
Deletes a mark.
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
const SfxPoolItem & Get(sal_uInt16 nWhich, bool bSrchInParent=true) const
short GetTextFirstLineOffset() const
tools::Long GetLeft() const
void SetTextFirstLineOffset(const short nF, const sal_uInt16 nProp=100)
void SetLeft(const tools::Long nL, const sal_uInt16 nProp=100)
Class for automated call of Start- and EndAction().
Definition: editsh.hxx:1019
bool Pop(PopMode, ::std::optional< SwCallLink > &roLink)
bool LeftMargin()
Definition: crsrsh.hxx:367
void Push()
store a copy of the current cursor on the cursor stack
Definition: crsrsh.cxx:2251
const SwTableNode * IsCursorInTable() const
Definition: crsrsh.hxx:909
bool IsEndOfTable() const
at the very last SwPosition inside a table
Definition: crsrsh.cxx:1133
void SwapPam()
Definition: crsrsh.cxx:976
virtual SwCursor & GetCurrentShellCursor() override
Return the current shell cursor.
Definition: crsrsh.cxx:185
void NormalizePam(bool bPointFirst=true)
Ensure point and mark of the current PaM are in a specific order.
Definition: crsrsh.cxx:970
bool MovePara(SwWhichPara, SwMoveFnCollection const &)
Definition: crsrsh.cxx:696
bool IsEndPara() const
Definition: crsrsh.cxx:1114
bool RightMargin(bool bAPI=false)
Definition: crsrsh.hxx:368
SwCursor * GetCursor(bool bMakeTableCursor=true) const
Return pointer to the current shell cursor.
Definition: crsrsh.cxx:194
OUString GetSelText() const
get selected text of a node at current cursor
Definition: crsrsh.cxx:2559
bool IsSttPara() const
Definition: crsrsh.cxx:1095
bool IsSelection() const
Definition: crsrsh.hxx:899
void UpdateAttr()
Definition: crsrsh.hxx:776
bool IsStartOfDoc() const
Definition: crsrsh.cxx:2767
bool Right(sal_uInt16 nCnt, SwCursorSkipMode nMode, bool bAllowVisual=false)
Definition: crsrsh.hxx:363
void ClearMark()
Definition: crsrsh.cxx:939
void SetMark()
Definition: crsrsh.hxx:895
bool IsEndOfDoc() const
Definition: crsrsh.cxx:2779
bool Left(sal_uInt16 nCnt, SwCursorSkipMode nMode, bool bAllowVisual=false)
Definition: crsrsh.hxx:361
void KillPams()
Definition: crsrsh.cxx:1022
bool IsStartWord(sal_Int16 nWordType=css::i18n::WordType::ANYWORD_IGNOREWHITESPACES) const
Definition: crstrvl1.cxx:27
sal_Unicode GetChar(bool bEnd=true, tools::Long nOffset=0)
get the nth character of the current SSelection
Definition: crsrsh.cxx:2615
void SetAttr(const SfxPoolItem &, SwFormat &)
Set attribute in given format.1y If Undo is enabled, the old values is added to the Undo history.
Definition: docfmt.cxx:452
virtual void Deactivate()
Definition: drawbase.cxx:444
bool GetCurAttr(SfxItemSet &, const bool bMergeIndentValuesOfNumRule=false) const
Definition: edattr.cxx:171
void StartAllAction()
For all views of this document.
Definition: edws.cxx:86
bool IsRedlineOn() const
Definition: edredln.cxx:43
bool Delete(bool isArtificialSelection=false)
Delete content of all ranges.
Definition: eddel.cxx:125
void SetRedlineFlags(RedlineFlags eMode)
Definition: edredln.cxx:32
void SetAttrSet(const SfxItemSet &, SetAttrMode nFlags=SetAttrMode::DEFAULT, SwPaM *pCursor=nullptr, const bool bParagraphSetting=false)
Definition: edatmisc.cxx:129
RedlineFlags GetRedlineFlags() const
For Redlining.
Definition: edredln.cxx:27
SvtScriptType GetScriptType() const
returns the script type of the selection
Definition: edattr.cxx:662
bool DelFullPara()
Remove a complete paragraph.
Definition: eddel.cxx:341
void EndAllAction()
Definition: edws.cxx:97
SwFlyFrame * GetSelectedFlyFrame() const
Definition: fefly1.cxx:277
bool SetFlyFrameAttr(SfxItemSet &rSet)
Definition: fefly1.cxx:1103
bool GotoNextFly(GotoObjFlags eType=GotoObjFlags::FlyAny)
Independent selecting of flys.
Definition: fesh.hxx:414
bool IsFrameSelected() const
Definition: feshview.cxx:1253
void DelSelectedObj()
Definition: feshview.cxx:2377
SwRect GetObjRect() const
For adjustment of PosAttr when anchor changes.
Definition: fefly1.cxx:1298
bool GetFlyFrameAttr(SfxItemSet &rSet) const
Definition: fefly1.cxx:1061
general base class for all free-flowing frames
Definition: flyfrm.hxx:79
virtual const SwFlyFrameFormat * GetFormat() const override
Definition: fly.cxx:2905
FlyAnchors.
Definition: fmtanchr.hxx:37
RndStdIds GetAnchorId() const
Definition: fmtanchr.hxx:67
const SwPosition * GetContentAnchor() const
Definition: fmtanchr.hxx:69
const SwField * GetField() const
Definition: fmtfld.hxx:130
const SwFormatAnchor & GetAnchor(bool=true) const
Definition: fmtanchr.hxx:83
Style of a layout element.
Definition: frmfmt.hxx:62
SwTextNode * GetTextNode()
Inline methods from Node.hxx.
Definition: ndtxt.hxx:897
const SwStartNode * FindTableBoxStartNode() const
Definition: node.hxx:218
SwNode & GetPointNode() const
Definition: pam.hxx:283
const SwPosition * GetPoint() const
Definition: pam.hxx:261
Point TopLeft() const
Definition: swrect.hxx:254
Starts a section of nodes in the document model.
Definition: node.hxx:348
const SwFormatField & GetFormatField() const
Definition: txatbase.hxx:199
SwTextNode is a paragraph in the document model.
Definition: ndtxt.hxx:111
SwTextField * GetFieldTextAttrAt(const sal_Int32 nIndex, ::sw::GetTextAttrMode const eMode=::sw::GetTextAttrMode::Expand) const
Definition: ndtxt.cxx:1835
rtl::Reference< SwDoc > mxDoc
The document; never 0.
Definition: viewsh.hxx:179
const IDocumentMarkAccess * getIDocumentMarkAccess() const
Provides access to the document bookmark interface.
Definition: viewsh.cxx:2807
SwDoc * GetDoc() const
Definition: viewsh.hxx:290
const SfxItemPool & GetAttrPool() const
Definition: viewsh.hxx:624
SwDrawBase * GetDrawFuncPtr() const
Definition: view.hxx:529
void SetDrawFuncPtr(std::unique_ptr< SwDrawBase > pFuncPtr)
Definition: viewdraw.cxx:641
void LeaveDrawCreate()
Definition: view.hxx:541
void EnterBlockMode()
Definition: select.cxx:651
void DelToEndOfLine()
Definition: delete.cxx:126
SAL_DLLPRIVATE void CloseMark(bool bOkFlag)
Definition: delete.cxx:48
void EnterSelFrameMode(const Point *pStartDrag=nullptr)
Definition: select.cxx:702
void DelPrvWord()
Definition: delete.cxx:651
void LeaveSelFrameMode()
Definition: select.cxx:720
bool DelLeft()
Definition: delete.cxx:134
SAL_DLLPRIVATE bool PrvWrdForDelete()
Definition: wrtsh4.cxx:154
bool TryRemoveIndent()
Definition: delete.cxx:62
SAL_DLLPRIVATE tools::Long SetCursor(const Point *, bool bProp=false)
Definition: select.cxx:304
void Insert(const OUString &)
Definition: wrtsh1.cxx:224
void ResetCursorStack()
Definition: wrtsh.hxx:644
SelectionType GetSelectionType() const
Definition: wrtsh1.cxx:1706
void EnterStdMode()
Definition: select.cxx:551
SAL_DLLPRIVATE void SttWrd()
Definition: wrtsh4.cxx:32
SAL_DLLPRIVATE bool BwdSentence_()
Definition: wrtsh4.cxx:193
void DelToStartOfSentence()
Definition: delete.cxx:585
SAL_DLLPRIVATE void OpenMark()
Definition: delete.cxx:40
bool IsBlockMode() const
Definition: wrtsh.hxx:168
void InfoReadOnlyDialog(bool bAsync=false)
Definition: wrtsh1.cxx:2656
void DelToEndOfPara()
Definition: delete.cxx:547
bool DelRight(bool isReplaceHeuristic=false)
Definition: delete.cxx:291
void DelLine()
Description: Erase the line.
Definition: delete.cxx:101
bool HasSelection() const
Definition: wrtsh.hxx:147
SAL_DLLPRIVATE bool FwdSentence_()
Definition: wrtsh4.cxx:176
SAL_DLLPRIVATE void EndWrd()
Definition: wrtsh4.cxx:52
SAL_DLLPRIVATE bool NxtWrdForDelete()
Definition: wrtsh4.cxx:131
bool DelToEndOfSentence()
Definition: delete.cxx:594
void UnSelectFrame()
Definition: select.cxx:323
bool IsEndWrd()
Definition: wrtsh1.cxx:194
void DelNxtWord()
Definition: delete.cxx:628
void DelToStartOfPara()
Definition: delete.cxx:564
bool Pop(SwCursorShell::PopMode, ::std::optional< SwCallLink > &roLink)
Definition: wrtsh1.cxx:2030
const SwView & GetView() const
Definition: wrtsh.hxx:438
void DelToStartOfLine()
Definition: delete.cxx:118
virtual const SwPosition & GetMarkEnd() const =0
virtual const SwPosition & GetMarkStart() const =0
static bool isIVSSelector(sal_uInt32 nCode)
static bool isCJKIVSCharacter(sal_uInt32 nCode)
SelectionType
anchor
constexpr TypedWhichId< SvxLRSpaceItem > RES_LR_SPACE(91)
#define CH_TXT_TRACKED_DUMMY_CHAR
Definition: hintids.hxx:187
sal_uInt16 nCode
constexpr T & temporary(T &&x)
bool GoCurrPara(SwPaM &rPam, SwMoveFnCollection const &aPosPara)
Definition: pam.cxx:1224
SwMoveFnCollection const & fnParaStart
Definition: paminit.cxx:48
SwMoveFnCollection const & fnParaEnd
Definition: paminit.cxx:49
Marks a position in the document model.
Definition: pam.hxx:37
const SwContentNode * GetContentNode() const
Definition: pam.hxx:83
sal_Int32 GetContentIndex() const
Definition: pam.hxx:84
RndStdIds