| 
| Trigger textDocument/hover in LSP4E [message #1803823] | Mon, 11 March 2019 10:43 |  | 
| Eclipse User  |  |  |  |  | This questions does not relate directly to LSP4J, but to the plugin connecting a language server with the Eclipse IDE. I registered a run configuration with a file ending via the LSP4E plugin, and the language server starts correctly when I open a file and syncs the text files when the file gets edited.
 
 In the LanguageServer.initialized() implementation I registered  the hover capability with :
 
 
 
	public CompletableFuture<InitializeResult> initialize(InitializeParams params) {
		
		final InitializeResult res = new InitializeResult(new ServerCapabilities());
		res.getCapabilities().setHoverProvider(Boolean.TRUE);
		res.getCapabilities().setTextDocumentSync(TextDocumentSyncKind.Full);
		.... (more)
		return CompletableFuture.supplyAsync(() -> res);
	}
 The server response correctly after initialize :
 
 {"jsonrpc":"2.0","id":"1","result":{"capabilities":{"textDocumentSync":1,"hoverProvider":true}}}
 
 Via the the console jsonrpc message exchange is logged, when I try to rename or jump to definition the appropriate request is made. But not so with the hover request (Im  putting the mouse cursor over a text token or select a word). It seems to me, the hover is not triggered by the plugin.
 
 Any ideas would be greatly appreciated.
 |  |  |  | 
Powered by 
FUDForum. Page generated in 0.04827 seconds