kateundo.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
#ifndef kate_undo_h
00022
#define kate_undo_h
00023
00024
#include <qptrlist.h>
00025
#include <qstring.h>
00026
00027
class KateDocument;
00028
class KateUndo;
00029
00033 class KateUndoGroup
00034 {
00035
public:
00040
KateUndoGroup (KateDocument *doc);
00041
00045
~KateUndoGroup ();
00046
00047
public:
00051
void undo ();
00052
00056
void redo ();
00057
00058
public:
00062 enum UndoType
00063 {
00064 editInsertText,
00065 editRemoveText,
00066 editWrapLine,
00067 editUnWrapLine,
00068 editInsertLine,
00069 editRemoveLine,
00070 editMarkLineAutoWrapped,
00071 editInvalid
00072 };
00073
00082
void addItem (KateUndoGroup::UndoType type, uint line, uint col, uint len,
const QString &text);
00083
00089
bool merge(
KateUndoGroup* newGroup);
00090
00091
private:
00096 KateUndoGroup::UndoType singleType();
00097
00103
bool isOnlyType(KateUndoGroup::UndoType type);
00104
00109
void addItem (KateUndo *u);
00110
00111
private:
00115 KateDocument *m_doc;
00116
00120
QPtrList<KateUndo> m_items;
00121 };
00122
00123
#endif
00124
00125
This file is part of the documentation for kate Library Version 3.3.0.