-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathsignature_help.txt
193 lines (154 loc) · 6.2 KB
/
signature_help.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
*denops-signature_help.txt* Show signature help from lsp server
Author : matsui54 <[email protected]>
License: MIT license
CONTENTS *denops-signature_help-contents*
Introduction |denops-signature_help-introduction|
Usage |denops-signature_help-usage|
Install |denops-signature_help-install|
Interface |denops-signature_help-interface|
Variables |denops-signature_help-variables|
Functions |denops-signature_help-functions|
Highlight |denops-signature_help-highlight|
Options |denops-signature_help-options|
Configuration |denops-signature_help-configuration|
Example |denops-signature_help-example|
==============================================================================
INTRODUCTION *denops-signature_help-introduction*
*denops-signature_help* shows signature help from lsp server (nvim-lsp and
vim-lsp). This works in both Vim and Neovim.
==============================================================================
USAGE *denops-signature_help-usage*
You need to start manually.
>
call signature_help#enable()
" if you use with vim-lsp, disable vim-lsp's signature help feature
let g:lsp_signature_help_enabled = 0
>
==============================================================================
INSTALL *denops-signature_help-install*
Use your favorite plugin manager.
==============================================================================
INTERFACE *denops-signature_help-interface*
------------------------------------------------------------------------------
FUNCTIONS *denops-signature_help-functions*
signature_help#enable() *signature_help#enable()*
Enables |denops-signature_help|.
signature_help#disable() *signature_help#disable()*
Disables |denops-signature_help|.
signature_help#is_enabled() *signature_help#is_enabled()*
Returns weather |denops-signature_help| plugin is enabled. This
function returns 1 if |denops-signature_help| is enabled, zero
otherwise.
signature_help#scroll({count}) *signature_help#scroll()*
Scroll floating window with {count}.
Example: >
inoremap <buffer> <expr><c-f> signature_help#scroll(+4)
inoremap <buffer> <expr><c-d> signature_help#scroll(-4)
------------------------------------------------------------------------------
HIGHLIGHTS *denops-signature_help-highlights*
These are Neovim only
SignatureHelpDocument *hl-SignatureHelpDocument*
A highlight used for background of floating window.
default: links to |hl-NormalFloat|
SignatureHelpBorder *hl-SignatureHelpBorder*
A highlight used for border of floating window.
default: links to FloatBorder
SignatureHelpVirtual *hl-SignatureHelpVirtual*
A highlight used for virtual text.
default: links to Error.
SignatureHelpGhostText *hl-SignatureHelpGhostText*
A highlight used for ghost text (virtual lines).
default: links to Comment.
Additionally, you can configure highlight of the active parameter in the
signature help via |hl-LspSignatureActiveParameter|.
==============================================================================
OPTIONS *denops-signature_help-options*
You can customize |denops-signature_help| with global variable
|g:signature_help_config|.
|g:signature_help_config| is a dictionary which has the following keys.
border *denops-signature_help-option-border*
If it is true, border of floating window is shown.
(default: v:true)
maxWidth *denops-signature_help-option-maxWidth*
Max width of floating window.
(default: 80)
maxHeight *denops-signature_help-option-maxHeight*
Max height of floating window.
(default: 30)
winblend *denops-signature_help-option-winblend*
'winblend' of the floating window
(Only in Neovim)
(default: 'winblend')
style *denops-signature_help-option-style*
DEPRECATED:
This option will be removed.
Use `contentsStyle` and `viewStyle` options instead,
following the alternate config below.
"full": Same as >
contentsStyle: "full",
viewStyle: "floating"
<
"labelOnly": Same as >
contentsStyle: "labels",
viewStyle: "floating"
<
"currentLabelOnly":
Same as >
contentsStyle: "currentLabel",
viewStyle: "floating"
<
"virtual": Same as >
contentsStyle: "remainingLabels",
viewStyle: "virtual"
<
contentsStyle *denops-signature_help-option-contentsStyle*
Style of contents of signature help.
"full": Show all information from lsp server.
"labels": Show only labels. Documentation is omitted.
"currentLabel": Show only current parameter.
This is the minimal style.
"remainingLabels":
Show parameters after cursor position.
(default: "full")
viewStyle *denops-signature_help-option-viewStyle*
UI style of signature help.
"virtual": Use virtual text UI.
It works in both Vim and Neovim.
In Vim, popup window is used.
In Neovim, |nvim_buf_set_extmark()| is used.
"floating": Use floating/popup window.
"ghost": Use neovim's ghost text (virt lines) feature.
This works only in Neovim.
(default: "floating")
onTriggerChar *denops-signature_help-option-onTriggerChar*
If it is true, signature help window (or virtual text) is
shown only when trigger character (like "(" and ",") is typed.
(default: v:false)
multiLabel *denops-signature_help-option-multiLabel*
If it is true, all labels are shown when there are multiple
labels.
This option is only available when
|denops-signature_help-option-style| is "full" or "labelOnly".
(default: v:false)
fallbackToBelow *denops-signature_help-option-fallbackToBelow*
If it is true, the floating window opens below the cursor if
there is not enough space above the cursor; If false, floating
window doesn't open in such cases.
(default: v:true)
==============================================================================
EXAMPLE *denops-signature_help-example*
This is the default config.
>
let g:signature_help_config = {
\ 'border': v:true,
\ 'maxWidth': 80,
\ 'maxHeight': 30,
\ 'contentsStyle': 'full',
\ 'viewStyle': 'floating',
\ 'onTriggerChar': v:false,
\ 'multiLabel': v:false,
\ 'fallbackToBelow': v:true,
\ }
>
==============================================================================
vim:tw=78:ts=8:ft=help:norl:noet:fen: