diff options
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/autoload/provider/clipboard.vim | 8 | ||||
-rw-r--r-- | runtime/doc/options.txt | 2 | ||||
-rw-r--r-- | runtime/lua/vim/lsp/protocol.lua | 5 | ||||
-rw-r--r-- | runtime/lua/vim/lsp/util.lua | 5 |
4 files changed, 14 insertions, 6 deletions
diff --git a/runtime/autoload/provider/clipboard.vim b/runtime/autoload/provider/clipboard.vim index 275d18a5a9..c2195fa02d 100644 --- a/runtime/autoload/provider/clipboard.vim +++ b/runtime/autoload/provider/clipboard.vim @@ -91,19 +91,19 @@ function! provider#clipboard#Executable() abort let s:paste['*'] = s:paste['+'] let s:cache_enabled = 0 return 'pbcopy' - elseif exists('$WAYLAND_DISPLAY') && executable('wl-copy') && executable('wl-paste') + elseif !empty($WAYLAND_DISPLAY) && executable('wl-copy') && executable('wl-paste') let s:copy['+'] = ['wl-copy', '--foreground', '--type', 'text/plain'] let s:paste['+'] = ['wl-paste', '--no-newline'] let s:copy['*'] = ['wl-copy', '--foreground', '--primary', '--type', 'text/plain'] let s:paste['*'] = ['wl-paste', '--no-newline', '--primary'] return 'wl-copy' - elseif exists('$DISPLAY') && executable('xclip') + elseif !empty($DISPLAY) && executable('xclip') let s:copy['+'] = ['xclip', '-quiet', '-i', '-selection', 'clipboard'] let s:paste['+'] = ['xclip', '-o', '-selection', 'clipboard'] let s:copy['*'] = ['xclip', '-quiet', '-i', '-selection', 'primary'] let s:paste['*'] = ['xclip', '-o', '-selection', 'primary'] return 'xclip' - elseif exists('$DISPLAY') && executable('xsel') && s:cmd_ok('xsel -o -b') + elseif !empty($DISPLAY) && executable('xsel') && s:cmd_ok('xsel -o -b') let s:copy['+'] = ['xsel', '--nodetach', '-i', '-b'] let s:paste['+'] = ['xsel', '-o', '-b'] let s:copy['*'] = ['xsel', '--nodetach', '-i', '-p'] @@ -132,7 +132,7 @@ function! provider#clipboard#Executable() abort let s:copy['*'] = s:copy['+'] let s:paste['*'] = s:paste['+'] return 'win32yank' - elseif exists('$TMUX') && executable('tmux') + elseif !empty($TMUX) && executable('tmux') let s:copy['+'] = ['tmux', 'load-buffer', '-'] let s:paste['+'] = ['tmux', 'save-buffer', '-'] let s:copy['*'] = s:copy['+'] diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index d28e0467e9..b83d2c4484 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -2918,6 +2918,8 @@ A jump table for the options with a short description can be found at |Q_op|. *'go-c'* 'c' Use console dialogs instead of popup dialogs for simple choices. + *'go-d'* + 'd' Use dark theme variant if available. *'go-e'* 'e' Add tab pages when indicated with 'showtabline'. 'guitablabel' can be used to change the text in the labels. diff --git a/runtime/lua/vim/lsp/protocol.lua b/runtime/lua/vim/lsp/protocol.lua index 2773f59b45..36c9822e23 100644 --- a/runtime/lua/vim/lsp/protocol.lua +++ b/runtime/lua/vim/lsp/protocol.lua @@ -639,8 +639,11 @@ function protocol.make_client_capabilities() completion = { dynamicRegistration = false; completionItem = { + -- Until we can actually expand snippet, move cursor and allow for true snippet experience, + -- this should be disabled out of the box. + -- However, users can turn this back on if they have a snippet plugin. + snippetSupport = false; - snippetSupport = true; commitCharactersSupport = false; preselectSupport = false; deprecatedSupport = false; diff --git a/runtime/lua/vim/lsp/util.lua b/runtime/lua/vim/lsp/util.lua index b5f171a985..775932c7fd 100644 --- a/runtime/lua/vim/lsp/util.lua +++ b/runtime/lua/vim/lsp/util.lua @@ -492,7 +492,10 @@ function M.convert_signature_help_to_markdown_lines(signature_help) --=== 0`. Whenever possible implementors should make an active decision about --the active signature and shouldn't rely on a default value. local contents = {} - local active_signature = signature_help.activeSignature or 0 + local active_signature = signature_help.activeSignature + if active_signature == vim.NIL or active_signature == nil then + active_signature = 0 + end -- If the activeSignature is not inside the valid range, then clip it. if active_signature >= #signature_help.signatures then active_signature = 0 |