Add an option to enable/disable case insensitive completion.

Options:
- Global option: g:jedi#case_insensitive_completion
- Buffer-local option: b:jedi_case_insensitive_completion

Values:
- 0 to disable case insensitive completion.
- 1 to enable case insensitive completion (default).
This commit is contained in:
James Cherti
2022-01-29 16:02:37 -05:00
parent 08ad42efed
commit 873ee9325d
4 changed files with 20 additions and 0 deletions

View File

@@ -321,6 +321,10 @@ def get_pos(column=None):
@_check_jedi_availability(show_error=False)
@catch_and_print_exceptions
def completions():
jedi.settings.case_insensitive_completion = \
bool(int(vim_eval("get(b:, 'jedi_case_insensitive_completion', "
"g:jedi#case_insensitive_completion)")))
row, column = vim.current.window.cursor
# Clear call signatures in the buffer so they aren't seen by the completer.
# Call signatures in the command line can stay.