Kate
KateCommands::SedReplace Class Reference
Support vim/sed style search and replace. More...
#include <katecmds.h>
Inheritance diagram for KateCommands::SedReplace:

Public Member Functions | |
const QStringList & | cmds () |
bool | exec (class KTextEditor::View *view, const QString &cmd, QString &errorMsg, const KTextEditor::Range &r) |
bool | exec (class KTextEditor::View *view, const QString &cmd, QString &errorMsg) |
bool | help (class KTextEditor::View *, const QString &, QString &) |
bool | supportsRange (const QString &) |
Detailed Description
Support vim/sed style search and replace.
Definition at line 94 of file katecmds.h.
Member Function Documentation
const QStringList& KateCommands::SedReplace::cmds | ( | ) | [inline] |
bool KateCommands::SedReplace::exec | ( | class KTextEditor::View * | view, | |
const QString & | cmd, | |||
QString & | errorMsg, | |||
const KTextEditor::Range & | r | |||
) |
Definition at line 545 of file katecmds.cpp.
bool KateCommands::SedReplace::exec | ( | class KTextEditor::View * | view, | |
const QString & | cmd, | |||
QString & | errorMsg | |||
) |
Execute command.
Valid command strings are:
- s/search/replace/ find
search
, replace it withreplace
on this line - %s/search/replace/ do the same to the whole file
- s/search/replace/i do the search and replace case insensitively
- $s/search/replace/ do the search are replacement to the selection only
- Note:
- $s/// is currently unsupported
- Parameters:
-
view view to use for execution cmd cmd string errorMsg error to return if no success
- Returns:
- success
Definition at line 540 of file katecmds.cpp.
bool KateCommands::SedReplace::help | ( | class KTextEditor::View * | , | |
const QString & | , | |||
QString & | ||||
) | [inline] |
This command does not have help.
- See also:
- KTextEditor::Command::help
Definition at line 120 of file katecmds.h.
bool KateCommands::SedReplace::supportsRange | ( | const QString & | ) | [inline] |
Definition at line 117 of file katecmds.h.
The documentation for this class was generated from the following files: