35#include <rtl/character.hxx>
36#include <osl/diagnose.h>
73 if (aOldFirstLineOfst > 0)
78 else if (aOldFirstLineOfst < 0)
93 aAttrSet.
Put(firstLine);
94 aAttrSet.
Put(leftMargin);
114 bool bRet =
Delete(
false);
124 bool bRet =
Delete(
false);
132 bool bRet =
Delete(
false);
141 if( nCmp & nSelType )
155 if ( nCmp & nSelType )
215 bDoSomething = pIsInTableNd == pWasInTableNd;
225 bDoSomething = pSNdOld == pSNdNew;
249 if (pFm && pFm->GetMarkEnd() == *pCurPos)
263 sal_uInt32 nCode =
GetChar(
false);
264 if ( rtl::isSurrogate( nCode ) )
312 Delete(isReplaceHeuristic);
340 bool bDelFull =
false;
341 bool bDoNothing =
false;
353 bDelFull = bCheckDelFull && pCurrTableNd && pCurrTableNd != pWasInTableNd;
354 if (!bDelFull && (
IsCursorInTable() || (pCurrTableNd != pWasInTableNd)))
363 bDoNothing = pSNdOld != pSNdNew;
375 if (bDelFull || bDoNothing)
382 if (pFm && pFm->GetMarkStart() == *
GetCursor()->GetPoint())
414 std::optional<SwPosition> oAnchor;
415 RndStdIds eAnchorId = RndStdIds::FLY_AT_PARA;
425 if (
IsRedlineOn() && (eAnchorId != RndStdIds::FLY_AS_CHAR &&
426 eAnchorId != RndStdIds::FLY_AT_CHAR) )
435 if ((eAnchorId == RndStdIds::FLY_AS_CHAR || eAnchorId == RndStdIds::FLY_AT_CHAR)
448 ( eAnchorId == RndStdIds::FLY_AT_CHAR || eAnchorId == RndStdIds::FLY_AS_CHAR ) )
450 sal_Int32 nRedlineLength = 1;
454 if ( eAnchorId == RndStdIds::FLY_AT_CHAR )
503 "<SwWrtShell::DelRight(..)> - <SwWrtShell::UnSelectFrame()> should unmark all objects" );
506 if (
GetView().GetDrawFuncPtr())
548 bool bRet =
Delete(
false);
565 bool bRet =
Delete(
false);
633 bool bRet =
Delete(
false);
657 bool bRet =
Delete(
false);
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)
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
void SetTextFirstLineOffset(const short nF, const sal_uInt16 nProp=100)
short GetTextFirstLineOffset() const
void SetTextLeft(const tools::Long nL, const sal_uInt16 nProp=100)
tools::Long GetTextLeft() const
Class for automated call of Start- and EndAction().
bool Pop(PopMode, ::std::optional< SwCallLink > &roLink)
void Push()
store a copy of the current cursor on the cursor stack
const SwTableNode * IsCursorInTable() const
Check if Point of current cursor is placed within a table.
bool IsEndOfTable() const
at the very last SwPosition inside a table
virtual SwCursor & GetCurrentShellCursor() override
Return the current shell cursor.
void NormalizePam(bool bPointFirst=true)
Ensure point and mark of the current PaM are in a specific order.
bool MovePara(SwWhichPara, SwMoveFnCollection const &)
bool RightMargin(bool bAPI=false)
SwCursor * GetCursor(bool bMakeTableCursor=true) const
Return pointer to the current shell cursor.
OUString GetSelText() const
get selected text of a node at current cursor
bool IsStartOfDoc() const
bool Right(sal_uInt16 nCnt, SwCursorSkipMode nMode, bool bAllowVisual=false)
bool Left(sal_uInt16 nCnt, SwCursorSkipMode nMode, bool bAllowVisual=false)
bool IsStartWord(sal_Int16 nWordType=css::i18n::WordType::ANYWORD_IGNOREWHITESPACES) const
sal_Unicode GetChar(bool bEnd=true, tools::Long nOffset=0)
get the nth character of the current SSelection
void SetAttr(const SfxPoolItem &, SwFormat &)
Set attribute in given format.1y If Undo is enabled, the old values is added to the Undo history.
virtual void Deactivate()
bool GetCurAttr(SfxItemSet &, const bool bMergeIndentValuesOfNumRule=false) const
void StartAllAction()
For all views of this document.
bool Delete(bool isArtificialSelection=false)
Delete content of all ranges.
void SetRedlineFlags(RedlineFlags eMode)
void SetAttrSet(const SfxItemSet &, SetAttrMode nFlags=SetAttrMode::DEFAULT, SwPaM *pCursor=nullptr, const bool bParagraphSetting=false)
RedlineFlags GetRedlineFlags() const
For Redlining.
bool DelFullPara()
Remove a complete paragraph.
SwFlyFrame * GetSelectedFlyFrame() const
bool SetFlyFrameAttr(SfxItemSet &rSet)
bool GotoNextFly(GotoObjFlags eType=GotoObjFlags::FlyAny)
Independent selecting of flys.
bool IsFrameSelected() const
SwRect GetObjRect() const
For adjustment of PosAttr when anchor changes.
bool GetFlyFrameAttr(SfxItemSet &rSet) const
general base class for all free-flowing frames
virtual const SwFlyFrameFormat * GetFormat() const override
SwTextNode * GetTextNode()
Inline methods from Node.hxx.
const SwStartNode * FindTableBoxStartNode() const
SwNode & GetPointNode() const
const SwPosition * GetPoint() const
Starts a section of nodes in the document model.
const SwFormatField & GetFormatField() const
SwTextNode is a paragraph in the document model.
SwTextField * GetFieldTextAttrAt(const sal_Int32 nIndex, ::sw::GetTextAttrMode const eMode=::sw::GetTextAttrMode::Expand) const
rtl::Reference< SwDoc > mxDoc
The document; never 0.
const IDocumentMarkAccess * getIDocumentMarkAccess() const
Provides access to the document bookmark interface.
const SfxItemPool & GetAttrPool() const
SwDrawBase * GetDrawFuncPtr() const
void SetDrawFuncPtr(std::unique_ptr< SwDrawBase > pFuncPtr)
SAL_DLLPRIVATE void CloseMark(bool bOkFlag)
void EnterSelFrameMode(const Point *pStartDrag=nullptr)
SAL_DLLPRIVATE bool PrvWrdForDelete()
SAL_DLLPRIVATE tools::Long SetCursor(const Point *, bool bProp=false)
void Insert(const OUString &)
SelectionType GetSelectionType() const
SAL_DLLPRIVATE void SttWrd()
SAL_DLLPRIVATE bool BwdSentence_()
void DelToStartOfSentence()
SAL_DLLPRIVATE void OpenMark()
bool DelRight(bool isReplaceHeuristic=false)
void DelLine()
Description: Erase the line.
bool HasSelection() const
SAL_DLLPRIVATE bool FwdSentence_()
SAL_DLLPRIVATE void EndWrd()
SAL_DLLPRIVATE bool NxtWrdForDelete()
bool DelToEndOfSentence()
bool Pop(SwCursorShell::PopMode, ::std::optional< SwCallLink > &roLink)
const SwView & GetView() const
static bool isVariationSelector(sal_uInt32 nCode)
constexpr TypedWhichId< SvxFirstLineIndentItem > RES_MARGIN_FIRSTLINE(91)
constexpr TypedWhichId< SvxTextLeftMarginItem > RES_MARGIN_TEXTLEFT(92)
#define CH_TXT_TRACKED_DUMMY_CHAR
constexpr T & temporary(T &&x)
bool GoCurrPara(SwPaM &rPam, SwMoveFnCollection const &aPosPara)
SwMoveFnCollection const & fnParaStart
SwMoveFnCollection const & fnParaEnd
Marks a position in the document model.
const SwContentNode * GetContentNode() const
sal_Int32 GetContentIndex() const