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

Method cursorPosition

kdevplatform/shell/textdocument.cpp:445–459  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

443}
444
445KTextEditor::Cursor KDevelop::TextDocument::cursorPosition() const
446{
447 Q_D(const TextDocument);
448
449 if (!d->document) {
450 return KTextEditor::Cursor::invalid();
451 }
452
453 KTextEditor::View *view = activeTextView();
454
455 if (view)
456 return view->cursorPosition();
457
458 return KTextEditor::Cursor::invalid();
459}
460
461void TextDocument::setCursorPosition(const KTextEditor::Cursor &cursor)
462{

Callers 4

textLineMethod · 0.45
textWordMethod · 0.45
viewStatusMethod · 0.45
populateContextMenuMethod · 0.45

Calls 1

invalidFunction · 0.50

Tested by

no test coverage detected