diff --git a/src/plugins/cmakeprojectmanager/cmakeeditor.cpp b/src/plugins/cmakeprojectmanager/cmakeeditor.cpp index d3a4fd1d29a..351c08c6f9b 100644 --- a/src/plugins/cmakeprojectmanager/cmakeeditor.cpp +++ b/src/plugins/cmakeprojectmanager/cmakeeditor.cpp @@ -45,6 +45,7 @@ #include #include +#include #include #include @@ -71,7 +72,7 @@ void CMakeEditor::contextHelp(const HelpCallback &callback) const break; chr = characterAt(pos); if (chr == QLatin1Char('(')) { - callback({}); + BaseTextEditor::contextHelp(callback); return; } } while (chr.unicode() != QChar::ParagraphSeparator); @@ -97,12 +98,13 @@ void CMakeEditor::contextHelp(const HelpCallback &callback) const // Not a command if (chr != QLatin1Char('(')) { - callback({}); + BaseTextEditor::contextHelp(callback); return; } const QString id = "command/" + textAt(begin, end - begin).toLower(); - callback(id); + callback( + {{id, Utils::Text::wordUnderCursor(editorWidget()->textCursor())}, {}, HelpItem::Unknown}); } //