Skip to content
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

New feature : LSP gutter support #2009

Open
angelozerr opened this issue Aug 27, 2024 · 1 comment
Open

New feature : LSP gutter support #2009

angelozerr opened this issue Aug 27, 2024 · 1 comment

Comments

@angelozerr
Copy link
Contributor

In IntelliJ, there is gutter support https://www.jetbrains.com/help/idea/guided-tour-around-the-user-interface.html#gutter which is very nice to execute action with a gutter which is an icon displays on the left of the editor for a given line.

For instance for some command like, run,debug, language server displays a Codelens which polluate the editor (if there are some other codelens like references, implementations).

If you see redhat-developer/lsp4ij#479, you can see Run, Debug codelens for rust-analyzer

image

IMHO Ithink it should be better to display those Run, Debug codelens as gutter:

image

image

//cc @fbricon @datho7561 @rgrunber

@jwortmann
Copy link

Afaik there is nothing preventing IntelliJ to implement the code lenses in form of gutter icons. In general, many of the features from the LSP specs are designed to be Editor UI agnostic, i.e. the client can decide how to implement the UI.

For example this is how code lenses are presented by default in Sublime Text, in form of a floating annotation at the righthand side:

code-lens-annotation

However, something which I imagine might be useful for your use case would be to add an optional kind property or similar to the CodeLens object, with values like test, references, etc.; then this could be used to determine an icon for the code lens (or perhaps you only want to present test in the gutter, but other code lens kinds inline for example).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants