32#include <osl/diagnose.h>
62 , m_pOldField(rOldField.CopyField())
63 , m_pNewField(rNewField.CopyField())
68 OSL_ENSURE(
m_pDoc,
"No document!");
113 Any aOldVal, Any aNewVal,
115 :
SwUndoField(rPos), m_aOldVal(
std::move(aOldVal)), m_aNewVal(
std::move(aNewVal)), m_nWhich(_nWhich)
virtual SwFieldType * GetFieldType(SwFieldIds nResId, const OUString &rName, bool bDbFieldMatching) const =0
virtual bool UpdateField(SwTextField *rDstFormatField, SwField &rSrcField, bool bUpdateTableFields)=0
Updates a field.
Marks a character position inside a document model content node (SwContentNode)
IDocumentUndoRedo & GetIDocumentUndoRedo()
IDocumentFieldsAccess const & getIDocumentFieldsAccess() const
SwDocShell * GetDocShell()
Base class of all fields.
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt16 nWhichId)
SwFieldType * GetTyp() const
Base class of the Writer document model elements.
SwContentNode * GetContentNode()
const SwFormatField & GetFormatField() const
SwUndoFieldFromAPI(const SwPosition &rPos, css::uno::Any aOldVal, css::uno::Any aNewVal, sal_uInt16 nWhich)
virtual void UndoImpl(::sw::UndoRedoContext &) override
virtual void RepeatImpl(::sw::RepeatContext &) override
virtual void RedoImpl(::sw::UndoRedoContext &) override
virtual ~SwUndoFieldFromAPI() override
SwUndoFieldFromDoc(const SwPosition &rPos, const SwField &aOldField, const SwField &aNewField, bool bUpdate)
virtual ~SwUndoFieldFromDoc() override
virtual void UndoImpl(::sw::UndoRedoContext &) override
virtual void RepeatImpl(::sw::RepeatContext &) override
virtual void RedoImpl(::sw::UndoRedoContext &) override
std::unique_ptr< SwField > m_pNewField
std::unique_ptr< SwField > m_pOldField
SwUndoField(const SwPosition &rPos)
virtual ~SwUndoField() override
SwNodeOffset m_nNodeIndex
static SwTextField * GetTextFieldAtPos(const SwPosition &rPos)
Returns the field at a certain position.
static SwField * GetFieldAtPos(const SwPosition &rPos)
Returns the field at a certain position.
std::deque< AttacherIndex_Impl > aIndex
Marks a position in the document model.
SwNodeOffset GetNodeIndex() const
sal_Int32 GetContentIndex() const
SwDoc & GetDoc() const
Returns the document this position is in.