OmniSharp / omnisharp-vim

Vim omnicompletion (intellisense) and more for C#
http://www.omnisharp.net
MIT License
1.72k stars 168 forks source link

Add an option to trigger the pop up (ex: parameter of function preview) while in "Insert mode" #661

Closed krehwell closed 3 years ago

krehwell commented 3 years ago

when we want to write a function, the parameter only be shown as the first time the intellisense suggest the function name with its parameter. however while we are about to fill the function parameter, there is no pop up anymore which shows what's the function's arguments was.

Output: image

Expected Ouput: image

also maybe to be added to a way to trigger the intellisense, usually IDE map it as Ctrl-Space to trigger it just in case it does not appear

nickspoons commented 3 years ago

I think you're looking for :h \(omnisharp_signature_help) which can be used in both insert-mode and normal mode.

Ctrl-Space mappings are a bit tricky in Vim. In gvim on Windows I can use this:

imap <silent> <buffer> <C-Space> <Plug>(omnisharp_signature_help)

But that doesn't work in terminal vim. In Terminal vim in arch linux I can use this:

imap <silent> <buffer> <C-@> <Plug>(omnisharp_signature_help)

But that doesn't work in gvim.

The example .vimrc and the OmniSharp helper plugin nickspoons/vim-sharpenup both use default mapping <C-\> (Ctrl+Backslash) for this.

nickspoons commented 3 years ago

Also, take a look at the README section on popup mappings, which explains some of the default temporary mappings available when the signature help popup is open. It is possible to cycle through overloads, which can be useful.

krehwell commented 3 years ago

signature help and type look up is the one I am looking for. thank you.