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
Scope highlight: highlight the "parent PSI" as well #2396
Comments
Hey @TheBestPessimist 👋, Thank you for opening an issue/feature request. We will get back to you as soon as we can. PS.: We offer |
Closed because there was no plan to implement it this way. |
@izhangzhihao can i ask why not? To me, having the "function definition" highlighted too seems much more natural when reading a single piece of code. |
Considering the significant differences in PSI trees across different languages, it is challenging to create a universal implementation for highlighting "parent PSI." This is because the varying PSI tree structures in different languages would result in completely different user experiences. Given that this is not a universally applicable solution, it is currently not included in the plan. |
Please check
Your programming languages
Kotlin, JSON
Expected Behavior
Current Behavior
Possible Solution
Code snippet
I'm not sure how to explain what I want, as I don't know intellij's PSI names, so I will try to explain what I want by examples. This is why i did not use the template correctly either.
This is about the feature "Scope highlight", via Ctrl+Right Click or Alt+Right Click.
Sample image:
Currently, when highlighting a particular object, only the portion between curly brackets, including the brackets themselves (
{}
) is selected.What I would like is to also highlight the "parent object" to which those curly brackets belong to.
Current highlighting:
Desired highlighting:
Current highlighting:
Desired highlighting:
I believe this would make the highlighted portions give a bit more context, especially when doing a screen sharing session with a person unfamiliar with the code.
This thing already happens for XML, as far as i can see:
In the case where I would like to highlight the following piece of code (cursor/right click is at position
|
), this happens just as i want it.Your Environment
izhangzhihao.rainbow.brackets (6.21)
The text was updated successfully, but these errors were encountered: