LibreOffice Module sw (master)  1
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
SwUndoInsert Class Reference

#include <UndoInsert.hxx>

Inheritance diagram for SwUndoInsert:
[legend]
Collaboration diagram for SwUndoInsert:
[legend]

Public Member Functions

 SwUndoInsert (const SwNodeIndex &rNode, sal_Int32 nContent, sal_Int32 nLen, const SwInsertFlags nInsertFlags, bool bWDelim=true)
 
 SwUndoInsert (const SwNodeIndex &rNode)
 
virtual ~SwUndoInsert () override
 
virtual void UndoImpl (::sw::UndoRedoContext &) override
 
virtual void RedoImpl (::sw::UndoRedoContext &) override
 
virtual void RepeatImpl (::sw::RepeatContext &) override
 
virtual SwRewriter GetRewriter () const override
 Returns rewriter for this undo object. More...
 
void SetWithRsid ()
 
- Public Member Functions inherited from SwUndo
 SwUndo (SwUndoId const nId, const SwDoc *pDoc)
 
virtual ~SwUndo () override
 
SwUndoId GetId () const
 
virtual OUString GetComment () const override
 Returns textual comment for this undo object. More...
 
ViewShellId GetViewShellId () const override
 See SfxUndoAction::GetViewShellId(). More...
 
RedlineFlags GetRedlineFlags () const
 
void SetRedlineFlags (RedlineFlags eMode)
 
bool IsDelBox () const
 
void IgnoreRepeat ()
 
- Public Member Functions inherited from SfxUndoAction
 SfxUndoAction ()
 
virtual ~SfxUndoAction () COVERITY_NOEXCEPT_FALSE
 
virtual bool Merge (SfxUndoAction *pNextAction)
 
virtual OUString GetRepeatComment (SfxRepeatTarget &) const
 
const DateTimeGetDateTime () const
 
virtual void dumpAsXml (xmlTextWriterPtr pWriter) const
 

Private Member Functions

bool CanGrouping (sal_Unicode cIns)
 
bool CanGrouping (const SwPosition &rPos)
 
void Init (const SwNodeIndex &rNode)
 
boost::optional< OUString > GetTextFromDoc () const
 
- Private Member Functions inherited from SwUndoSaveContent
 SwUndoSaveContent ()
 
 ~SwUndoSaveContent () COVERITY_NOEXCEPT_FALSE
 
void DelContentIndex (const SwPosition &pMark, const SwPosition &pPoint, DelContentType nDelContentType=DelContentType::AllMask)
 

Private Attributes

std::unique_ptr< SwNodeIndexm_pUndoNodeIndex
 start of Content in UndoNodes for Redo More...
 
boost::optional< OUString > maText
 
boost::optional< OUString > maUndoText
 
std::unique_ptr< SwRedlineDatapRedlData
 
sal_uLong nNode
 
sal_Int32 nContent
 
sal_Int32 nLen
 
bool const bIsWordDelim: 1
 
bool const bIsAppend: 1
 
bool m_bWithRsid: 1
 
const SwInsertFlags m_nInsertFlags
 
SwDocpDoc
 
- Private Attributes inherited from SwUndoSaveContent
std::unique_ptr< SwHistorypHistory
 

Friends

class ::sw::DocumentContentOperationsManager
 

Additional Inherited Members

- Static Public Member Functions inherited from SwUndo
static bool FillSaveData (const SwPaM &rRange, SwRedlineSaveDatas &rSData, bool bDelRange=true, bool bCopyNext=true)
 
static bool FillSaveDataForFormat (const SwPaM &, SwRedlineSaveDatas &)
 
static void SetSaveData (SwDoc &rDoc, SwRedlineSaveDatas &rSData)
 
static bool HasHiddenRedlines (const SwRedlineSaveDatas &rSData)
 
- Static Protected Member Functions inherited from SwUndo
static void RemoveIdxFromSection (SwDoc &, sal_uLong nSttIdx, const sal_uLong *pEndIdx=nullptr)
 
static void RemoveIdxFromRange (SwPaM &rPam, bool bMoveNext)
 
static void RemoveIdxRel (sal_uLong, const SwPosition &)
 
static bool CanRedlineGroup (SwRedlineSaveDatas &rCurr, const SwRedlineSaveDatas &rCheck, bool bCurrIsEnd)
 
- Protected Attributes inherited from SwUndo
bool bCacheComment
 
boost::optional< OUString > maComment
 
- Static Private Member Functions inherited from SwUndoSaveContent
static void MoveToUndoNds (SwPaM &rPam, SwNodeIndex *pNodeIdx, sal_uLong *pEndNdIdx=nullptr)
 
static void MoveFromUndoNds (SwDoc &rDoc, sal_uLong nNodeIdx, SwPosition &rInsPos, const sal_uLong *pEndNdIdx=nullptr, bool bForceCreateFrames=false)
 
static bool MovePtBackward (SwPaM &rPam)
 
static void MovePtForward (SwPaM &rPam, bool bMvBkwrd)
 

Detailed Description

Definition at line 40 of file UndoInsert.hxx.

Constructor & Destructor Documentation

SwUndoInsert::SwUndoInsert ( const SwNodeIndex rNode,
sal_Int32  nContent,
sal_Int32  nLen,
const SwInsertFlags  nInsertFlags,
bool  bWDelim = true 
)

Definition at line 106 of file unins.cxx.

References Init(), and TYPING.

SwUndoInsert::SwUndoInsert ( const SwNodeIndex rNode)

Definition at line 119 of file unins.cxx.

References EMPTYEXPAND, Init(), and SPLITNODE.

SwUndoInsert::~SwUndoInsert ( )
overridevirtual

Member Function Documentation

bool SwUndoInsert::CanGrouping ( sal_Unicode  cIns)
private
bool SwUndoInsert::CanGrouping ( const SwPosition rPos)
private
SwRewriter SwUndoInsert::GetRewriter ( ) const
overridevirtual

Returns rewriter for this undo object.

The returned rewriter has the following rule:

$1 -> '<inserted text>'

<inserted text>=""> is shortened to a length of nUndoStringLength.

Returns
rewriter for this undo object

Reimplemented from SwUndo.

Definition at line 454 of file unins.cxx.

References SwRewriter::AddRule(), aStr, DenoteSpecialCharacters(), maText, maUndoText, nUndoStringLength, ShortenString(), SwResId(), and UndoArg1.

boost::optional< OUString > SwUndoInsert::GetTextFromDoc ( ) const
private
void SwUndoInsert::Init ( const SwNodeIndex rNode)
private
void SwUndoInsert::RedoImpl ( ::sw::UndoRedoContext rContext)
overridevirtual
void SwUndoInsert::RepeatImpl ( ::sw::RepeatContext rContext)
overridevirtual
void SwUndoInsert::SetWithRsid ( )
inline

Definition at line 88 of file UndoInsert.hxx.

References m_bWithRsid.

Referenced by SwDoc::UpdateRsid().

void SwUndoInsert::UndoImpl ( ::sw::UndoRedoContext rContext)
overridevirtual

Friends And Related Function Documentation

friend class ::sw::DocumentContentOperationsManager
friend

Definition at line 55 of file UndoInsert.hxx.

Member Data Documentation

bool const SwUndoInsert::bIsAppend
private

Definition at line 50 of file UndoInsert.hxx.

Referenced by CanGrouping(), RedoImpl(), RepeatImpl(), and UndoImpl().

bool const SwUndoInsert::bIsWordDelim
private

Definition at line 49 of file UndoInsert.hxx.

Referenced by CanGrouping().

bool SwUndoInsert::m_bWithRsid
private

Definition at line 51 of file UndoInsert.hxx.

Referenced by RedoImpl(), SetWithRsid(), and UndoImpl().

const SwInsertFlags SwUndoInsert::m_nInsertFlags
private

Definition at line 53 of file UndoInsert.hxx.

Referenced by RedoImpl().

std::unique_ptr<SwNodeIndex> SwUndoInsert::m_pUndoNodeIndex
private

start of Content in UndoNodes for Redo

Definition at line 43 of file UndoInsert.hxx.

Referenced by RedoImpl(), UndoImpl(), and ~SwUndoInsert().

boost::optional<OUString> SwUndoInsert::maText
private

Definition at line 44 of file UndoInsert.hxx.

Referenced by GetRewriter(), RedoImpl(), UndoImpl(), and ~SwUndoInsert().

boost::optional<OUString> SwUndoInsert::maUndoText
private

Definition at line 45 of file UndoInsert.hxx.

Referenced by CanGrouping(), GetRewriter(), Init(), RedoImpl(), and UndoImpl().

sal_Int32 SwUndoInsert::nContent
private

Definition at line 48 of file UndoInsert.hxx.

Referenced by CanGrouping(), GetTextFromDoc(), RedoImpl(), RepeatImpl(), and UndoImpl().

sal_Int32 SwUndoInsert::nLen
private

Definition at line 48 of file UndoInsert.hxx.

Referenced by CanGrouping(), GetTextFromDoc(), RedoImpl(), RepeatImpl(), and UndoImpl().

sal_uLong SwUndoInsert::nNode
private

Definition at line 47 of file UndoInsert.hxx.

Referenced by CanGrouping(), GetTextFromDoc(), RedoImpl(), RepeatImpl(), and UndoImpl().

SwDoc* SwUndoInsert::pDoc
private

Definition at line 59 of file UndoInsert.hxx.

Referenced by GetTextFromDoc(), Init(), and UndoImpl().

std::unique_ptr<SwRedlineData> SwUndoInsert::pRedlData
private

Definition at line 46 of file UndoInsert.hxx.

Referenced by CanGrouping(), Init(), RedoImpl(), and ~SwUndoInsert().


The documentation for this class was generated from the following files: