mirror of
https://github.com/mawww/kakoune.git
synced 2024-12-18 17:02:06 +03:00
6f7c5aed10
As reported in [1], completions provided by "set global completers option=my_completion" activate insert mode autocompletion, even when the autocomplete option does not have the insert mode flag. This happens because InsertCompleter::on_option_changed() calls InsertCompleter::setup_ifn(), which shows the completion pager. Fix this by computing whether the completion pager is enabled; otherwise we can return early from setup_ifn(). The completion pager is enabled if the autocompletion bit is set, or if the user has requested explicit completion. [1]: https://github.com/kak-lsp/kak-lsp/issues/585
11 lines
498 B
Plaintext
11 lines
498 B
Plaintext
ui_out -ignore 4
|
|
ui_in '{ "jsonrpc": "2.0", "method": "keys", "params": [ "i" ] }'
|
|
sleep .2 # trigger insert completion auto update
|
|
# Implicit completion is disabled via autocomplete.
|
|
ui_in '{ "jsonrpc": "2.0", "method": "keys", "params": [ "<c-n><esc>" ] }'
|
|
# Implicit completion can be toggled.
|
|
ui_in '{ "jsonrpc": "2.0", "method": "keys", "params": [ "ji<c-o><c-n><esc>" ] }'
|
|
# Explicit completion still works.
|
|
ui_in '{ "jsonrpc": "2.0", "method": "keys", "params": [ "ji./ui-<c-x>f<c-n>" ] }'
|
|
|