Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set space to <Space> #526

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion autoload/lsp/signature.vim
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,11 @@ export def BufferInit(lspserver: dict<any>)

# map characters that trigger signature help
for ch in lspserver.caps.signatureHelpProvider.triggerCharacters
exe $"inoremap <buffer> <silent> {ch} {ch}<C-R>=g:LspShowSignature()<CR>"
var mapChar = ch
if ch =~ ' '
mapChar = '<Space>'
endif
exe $"inoremap <buffer> <silent> {mapChar} {mapChar}<C-R>=g:LspShowSignature()<CR>"
Comment on lines +61 to +64
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that maybe weird to make space as trg, e.g repeat inputting space for indent, then how it work?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You might be right here. Maybe it should be skipped.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nah, not sure about this. It seems to be working just fine

endfor

# close the signature popup when leaving insert mode
Expand Down