vscode-docs-view icon indicating copy to clipboard operation
vscode-docs-view copied to clipboard

Add a second view with signature information

Open mjbvz opened this issue 5 years ago • 3 comments

Request

Add another view called Signature Info that shows the signature help (parameter hints) information at the current cursor position.

From: https://github.com/microsoft/vscode/issues/51253

mjbvz avatar Oct 03 '20 00:10 mjbvz

@mjbvz What is precisely meant by parameter info? Does Documentation view already shows that info? If I understand clearly what is different about Signature information which is not already covered by Documentation, I could submit an (almost ready) PR.

BTW if Signature Info is not part of Hover, is there an API to get it in extension code? Actually figured it out:

private getSignatureHelpAtCurrentPositionInEditor(editor: vscode.TextEditor) {
		return vscode.commands.executeCommand<vscode.SignatureHelp[]>(
			'vscode.executeSignatureHelpProvider',
			editor.document.uri,
			editor.selection.active);
}

sandipchitale avatar Jul 20 '22 01:07 sandipchitale

@sandipchitale Yep, the signature help is what I meant. Looks like you already found the right api to use for it too! Let me know if you run into any issues working on this

mjbvz avatar Jul 20 '22 04:07 mjbvz

Feel free to adjust the formatting. Note that it shows a green square next to the active (current) signature. Shows a black square next to the inactive signature.

sandipchitale avatar Jul 20 '22 21:07 sandipchitale