-
Notifications
You must be signed in to change notification settings - Fork 471
Support inlay hints for parameter names #2354
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
Conversation
I need to :
|
You will not able to do that, since LSP4E doesn't support InlayHint because LSP4J doesn't provide InlayHint eclipse-lsp4j/lsp4j#570 |
Yes but Eclipse does have Parameter Name Code Minings ;) . I meant more just things about the feature which users may have complained about. |
This PR supports inlay hints for parameter names. Meanwhile, a new client setting 'java.inlayHints.parameterNames.enabled' is added to specify how the inlay hints will be displayed in editor, where: - none: disable parameter name hints - literals: enable parameter name hints only for literal arguments - all: enable parameter name hints for literal and non-literal arguments Signed-off-by: sheche <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The change looks fine to me.
One thing I noticed (maybe on Linux?) is that I would be near the top of a file (line 0) with maybe 30 lines being shown below. However, I would see the client requesting inlay hints for a range of line 0 to 85. This is probably more to do with the OS / Desktop Environment but just wondering if others have seen this behaviour.
I can also observe this behavior in VS Code running on Windows. Might be related with VS Code's viewport calculation strategy? Or maybe a bug in VS Code. |
fix #2099
requires eclipse-jdtls/eclipse.jdt.ls#2019
Signed-off-by: sheche [email protected]