1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
21 #include "textundo.hxx"
22 #include <vcl/textdata.hxx>
24 class TextUndoDelPara
: public TextUndo
29 TextNode
* mpNode
; // points at the valid not-destroyed object
32 TextUndoDelPara( TextEngine
* pTextEngine
, TextNode
* pNode
, sal_uInt32 nPara
);
33 virtual ~TextUndoDelPara() override
;
35 virtual void Undo() override
;
36 virtual void Redo() override
;
38 virtual OUString
GetComment () const override
;
41 class TextUndoConnectParas
: public TextUndo
48 TextUndoConnectParas( TextEngine
* pTextEngine
, sal_uInt32 nPara
, sal_Int32 nSepPos
);
49 virtual ~TextUndoConnectParas() override
;
51 virtual void Undo() override
;
52 virtual void Redo() override
;
54 virtual OUString
GetComment () const override
;
57 class TextUndoSplitPara
: public TextUndo
64 TextUndoSplitPara( TextEngine
* pTextEngine
, sal_uInt32 nPara
, sal_Int32 nSepPos
);
65 virtual ~TextUndoSplitPara() override
;
67 virtual void Undo() override
;
68 virtual void Redo() override
;
70 virtual OUString
GetComment () const override
;
73 class TextUndoInsertChars
: public TextUndo
80 TextUndoInsertChars( TextEngine
* pTextEngine
, const TextPaM
& rTextPaM
, OUString aStr
);
82 virtual void Undo() override
;
83 virtual void Redo() override
;
85 virtual bool Merge( SfxUndoAction
*pNextAction
) override
;
87 virtual OUString
GetComment () const override
;
90 class TextUndoRemoveChars
: public TextUndo
97 TextUndoRemoveChars( TextEngine
* pTextEngine
, const TextPaM
& rTextPaM
, OUString aStr
);
99 virtual void Undo() override
;
100 virtual void Redo() override
;
102 virtual OUString
GetComment () const override
;
105 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */