• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • tdeui
 

tdeui

Public Member Functions | Protected Member Functions | List of all members
KCommand Class Referenceabstract

#include <kcommand.h>

Inheritance diagram for KCommand:
KNamedCommand KMacroCommand

Public Member Functions

virtual void execute ()=0
 
virtual void unexecute ()=0
 
virtual TQString name () const =0
 

Protected Member Functions

 KCommand ()
 
virtual void virtual_hook (int id, void *data)
 

Detailed Description

The abstract base class for all Commands.

Commands are used to store information needed for Undo/Redo functionality...

Definition at line 37 of file kcommand.h.

Constructor & Destructor Documentation

◆ KCommand()

KCommand::KCommand ( )
inlineprotected

Creates a command.

Definition at line 43 of file kcommand.h.

◆ ~KCommand()

KCommand::~KCommand ( )
virtual

Definition at line 29 of file kcommand.cpp.

Member Function Documentation

◆ execute()

virtual void KCommand::execute ( )
pure virtual

The main method: executes this command.

Implement here what this command is about, and remember to record any information that will be helpful for unexecute.

Implemented in KMacroCommand.

◆ name()

virtual TQString KCommand::name ( ) const
pure virtual
Returns
the name of this command, translated, since it will appear in the menus.

Implemented in KNamedCommand.

◆ unexecute()

virtual void KCommand::unexecute ( )
pure virtual

Unexecutes (undo) this command.

Implement here the steps to take for undoing the command. If your application uses actions for everything (it should), and if you implement unexecute correctly, the application is in the same state after unexecute as it was before execute. This means, the next call to execute will do the same thing as it did the first time.

Implemented in KMacroCommand.

◆ virtual_hook()

void KCommand::virtual_hook ( int  id,
void *  data 
)
protectedvirtual

Definition at line 367 of file kcommand.cpp.


The documentation for this class was generated from the following files:
  • kcommand.h
  • kcommand.cpp

tdeui

Skip menu "tdeui"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

tdeui

Skip menu "tdeui"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdeui by doxygen 1.9.4
This website is maintained by Timothy Pearson.