Scribus
Open source desktop publishing at your fingertips
UndoGui Class Referenceabstract

UndoGui is a virtual superclass for undo/redo widgets. More...

#include <undogui.h>

Inheritance diagram for UndoGui:
Collaboration diagram for UndoGui:

Public Slots

virtual void insertUndoItem (UndoObject *target, UndoState *state)=0
 Insert a new undo item. More...
 
virtual void insertRedoItem (UndoObject *target, UndoState *state)=0
 Insert a new redo item. More...
 
virtual void updateUndo (int steps)=0
 Update undo stack representation with number of steps. More...
 
virtual void updateRedo (int steps)=0
 Update redo stack representation with number of steps. More...
 
virtual void updateUndoActions ()=0
 Update the scrActions.
 
virtual void clearRedo ()=0
 Clear the redo action items.
 
virtual void popBack ()=0
 Remove the last (oldest) item from the undo stack representation.
 
- Public Slots inherited from ScDockPalette
virtual void setPaletteShown (bool)
 
virtual void setFontSize ()
 

Public Member Functions

 UndoGui (QWidget *parent=0, const char *name="UndoGui", Qt::WindowFlags f=0)
 Creates a new UndoGui instance. More...
 
virtual ~UndoGui ()
 Destroys the widget.
 
virtual void clear ()=0
 Empties the undo stack representation.
 
virtual void languageChange ()
 Sets GUI strings on language change.
 
- Public Member Functions inherited from ScDockPalette
 ScDockPalette (QWidget *parent=NULL, const QString &prefsContext=QString::null, Qt::WindowFlags f=0)
 
virtual void hide ()
 Sample way to grab keystrokes, simply calls superclass at this point.
 
void startup ()
 

Additional Inherited Members

- Signals inherited from ScDockPalette
void paletteShown (bool)
 Let the action for this palette know when something changes and it hasnt caused it.
 
- Protected Member Functions inherited from ScDockPalette
virtual void setPrefsContext (QString context)
 Set the Preferences context to be used for storage of startup visibility and position and size.
 
void storePosition ()
 
void storePosition (int newX, int newY)
 
void storeSize ()
 
void storeVisibility (bool)
 
void storeDockState ()
 
virtual void showEvent (QShowEvent *showEvent)
 Restore the geometry of the window when showing it.
 
virtual void closeEvent (QCloseEvent *closeEvent)
 Captures the close event and changes it to hide.
 
virtual void hideEvent (QHideEvent *)
 Stores the geometry of the window when hiding.
 
- Protected Attributes inherited from ScDockPalette
PrefsContextpalettePrefs
 
QString prefsContextName
 
bool visibleOnStartup
 
QWidget * originalParent
 
QWidget * tempParent
 

Detailed Description

UndoGui is a virtual superclass for undo/redo widgets.

UndoGui is a virtual superclass for all the classes that wants to represent undo/redo data. Subclasses must be registered to the UndoManager instance. Subclasses are expected to keep the whole stack with them and they must be able to work undo/redo situations by themselves. Only new undo actions and steps (undo or redo) are reported back.

See also
UndoWidget
UndoPalette
Author
Riku Leino tsoot.nosp@m.s@gm.nosp@m.ail.c.nosp@m.om
Date
December 2004

Constructor & Destructor Documentation

UndoGui::UndoGui ( QWidget *  parent = 0,
const char *  name = "UndoGui",
Qt::WindowFlags  f = 0 
)

Creates a new UndoGui instance.

Parameters
parentParent object for UndoGui
nameName of the object
fwidget flags

Member Function Documentation

virtual void UndoGui::insertRedoItem ( UndoObject target,
UndoState state 
)
pure virtualslot

Insert a new redo item.

Parameters
targetTarget of the redo action
stateState describing the action
virtual void UndoGui::insertUndoItem ( UndoObject target,
UndoState state 
)
pure virtualslot

Insert a new undo item.

Insert a new undo item. After an undoable action has happened and if this UndoGui is registered to the UndoManager this slot will be used to register the action to the widget.

Parameters
targetTarget of the undo action
stateState describing the action
virtual void UndoGui::updateRedo ( int  steps)
pure virtualslot

Update redo stack representation with number of steps.

When some other registered UndoGui subclass has received a redo request this slot is used to inform this UndoGui to update it's undo stack representation.

Parameters
stepsNumber of steps to take
virtual void UndoGui::updateUndo ( int  steps)
pure virtualslot

Update undo stack representation with number of steps.

When some other UndoGui subclass has received an undo request this slot is used to inform this UndoGui to update it's UndoStack representation.

Parameters
stepsNumber of steps to take

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