edbee - Qt Editor Library
Public Member Functions | List of all members
edbee::ReplaceSelectionCommand Class Reference

This command can be used to replace the current selection with a given text. More...

#include <replaceselectioncommand.h>

+ Inheritance diagram for edbee::ReplaceSelectionCommand:
+ Collaboration diagram for edbee::ReplaceSelectionCommand:

Public Member Functions

 ReplaceSelectionCommand (const QString &text, int caolesceId)
 The constructor of the replaceSelection command. More...
 
virtual int commandId ()
 
virtual void execute (TextEditorController *controller)
 Executes the replace selection command. More...
 
virtual QString toString ()
 Converts the current command to a string. More...
 
- Public Member Functions inherited from edbee::TextEditorCommand
 TextEditorCommand ()
 The default constructor. More...
 
virtual ~TextEditorCommand ()
 A blank virtual destructor. More...
 

Detailed Description

This command can be used to replace the current selection with a given text.

Constructor & Destructor Documentation

◆ ReplaceSelectionCommand()

edbee::ReplaceSelectionCommand::ReplaceSelectionCommand ( const QString &  text,
int  coalesceId 
)

The constructor of the replaceSelection command.

Parameters
textthe text to replace
coalesceIdthe coalesceId top merge undo operations

Member Function Documentation

◆ commandId()

virtual int edbee::ReplaceSelectionCommand::commandId ( )
inlinevirtual

◆ execute()

void edbee::ReplaceSelectionCommand::execute ( TextEditorController controller)
virtual

Executes the replace selection command.

Parameters
controllerthe controller context this command runs ons

Implements edbee::TextEditorCommand.

◆ toString()

QString edbee::ReplaceSelectionCommand::toString ( )
virtual

Converts the current command to a string.

Implements edbee::TextEditorCommand.


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