|KateRegExpSearch (const KTextEditor::Document *document, Qt::CaseSensitivity caseSensitivity)|
|QVector< KTextEditor::Range >||search (const QString &pattern, const KTextEditor::Range &inputRange, bool backwards=false)|
|static QString||buildReplacement (const QString &text, const QStringList &capturedTexts, int replacementCounter)|
|static QString||escapePlaintext (const QString &text)|
Object to help to search for regexp.
This should be NO QObject, it is created to often! I measured that, if you create it 20k times to replace for example " " in a document, that takes seconds on a modern machine!
Member Function Documentation
Returns a modified version of text where.
- escape sequences are resolved, e.g. "\\n" to "\n",
- references are resolved, e.g. "\\1" to 1st entry in capturedTexts, and
- counter sequences are resolved, e.g. "\\#...#" to replacementCounter.
text text containing escape sequences, references, and counter sequences capturedTexts list of substitutes for references replacementCounter value for replacement counter
- resolved text
|QVector< KTextEditor::Range > KateRegExpSearch::search||(||const QString &||pattern,|
|const KTextEditor::Range &||inputRange,|
Search for the regular expression
pattern inside the range
backwards is true, the search direction will be reversed.
pattern text to search for inputRange Range to search in backwards if true, the search will be backwards
- Vector of ranges, one for each capture. The first range (index zero) spans the full match. If the pattern does not match the vector has length 1 and holds the invalid range (see Range::isValid()).
The documentation for this class was generated from the following files: