Change KateKeywordCompletionModel::matchingItem to return
HideListIfAutomaticInvocation so that the completions menu is hidden for
typed keywords, e.g. typing "return" the menu get auto hidden.
Details
Details
- Reviewers
cullmann dhaumann brauch - Group Reviewers
KTextEditor KDevelop - Commits
- R39:e852d990eb5a: Make keyword completion model return HideListIfAutomaticInvocation by default
- Enable keyword completion in kate
- Open a file and change the mode to a language where return is a keyword say Python
- Type "return", check that when the word is fully typed the completions menu is hidden
Diff Detail
Diff Detail
- Repository
- R39 KTextEditor
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Comment Actions
Independent of anything else I think this is a very sensible change, and seems like an oversight / bug.
One of the more core kate guys should approve, but +1 from me.
Comment Actions
Hmm, does that really work this way? At least for me, even with and without that patch, I get with C++ more proposals than just return on typing return.
And for other things like the completion already now disappears.
Comment Actions
I messed up the test plan; try with the mode set to Python. It looks like a corner case where if there's only one exact match, the completions menu doesn't get auto hidden.
Comment Actions
FWIW, the combined effect of this patch and D22477, hopefully you'll no longer see the Q_RETRUN_ARG and co. completions unless the menu is manually invoked with the mode set to C++.