MCPcopy Create free account
hub / github.com/KDE/kdevelop / textFromDoc

Function textFromDoc

plugins/qmljs/kdevqmljsplugin.cpp:112–114  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

110}
111
112const QString textFromDoc(const IDocument* doc, const KTextEditor::Range& range) {
113 return doc->textDocument()->line(range.start().line()).mid(range.start().column(), range.end().column()-range.start().column());
114}
115
116// Finds how many spaces the given string has at one end.
117// direction=+1 -> left end of the string, -1 for right end.

Calls 6

midMethod · 0.80
lineMethod · 0.45
textDocumentMethod · 0.45
startMethod · 0.45
columnMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected