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

Color indent guide lines #164

Closed
Phoenix616 opened this issue Jul 27, 2018 · 24 comments
Closed

Color indent guide lines #164

Phoenix616 opened this issue Jul 27, 2018 · 24 comments

Comments

@Phoenix616
Copy link

Expected Behavior

  • There should be an option to color the indent guide lines the same as the curly brackets on that level:
    With bracket colors

  • Maybe it could use a sightly opaque/darker version of the bracket color as the bright one might be a bit much:
    With darker bracket colors

Current Behavior

  • Indent guide lines use one color for everything:
    Current coloring

Your Environment

  • Plugin version: 5.9.1
  • IDE & Operating System version:
IntelliJ IDEA 2018.1.1 EAP (Ultimate Edition)
Build #IU-181.4445.4, built on March 29, 2018

JRE: 1.8.0_152-release-1136-b27 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Windows 7 6.1
@izhangzhihao
Copy link
Owner

Some useful info : Change color of code fold markers and guide lines. If we are going to implement this feature we need to override the built-in color settings.

@kamronbatman
Copy link

@izhangzhihao, I think that is expected?

@izhangzhihao
Copy link
Owner

It's a nice to have feature I think.

@Polyterative
Copy link

This would be absolutely fantastic

@RacerDelux
Copy link

Agreed. Very useful feature. Helps to distinguish code blocks a bit better.

@YiiGuxing
Copy link
Collaborator

We need to paint our own indent guide:

  1. Create a range highlighter and add it to MarkupModel : MarkupModel.addRangeHighlighter() ;
  2. Add a CustomHighlighterRenderer to the range highlighter: RangeHighlighter.setCustomRenderer(CustomHighlighterRenderer) ;
  3. Paint custom indent guides in CustomHighlighterRenderer.paint() .

See: com.intellij.codeInsight.daemon.impl.IndentsPass .

@vroudge
Copy link

vroudge commented Feb 26, 2019

I would L O V E this feature

@shoelessness
Copy link

Perhaps there could also be an option to color the indents, not just the guides, as vscode-indent-rainbow does?

@JTBrinkmann
Copy link

this probably is beyond the scope of this plugin, but the indent guide highlighting of the Atom package indent-guide-improved might offer some inspiration for good UX.

screenrecording of indent-guide-improved

@willemjanvdun
Copy link

Love this idea! You have got my vote ;)

@TheBestPessimist
Copy link

Btw, intellij already provides this in a way:
intellij

@mattbishop
Copy link

I'd like to see this much more explicit. VS Code has a plugin that colorizes the indent space: https://marketplace.visualstudio.com/items?itemName=oderwat.indent-rainbow

@charl-nml
Copy link

The VS Code plugin @mattbishop mentions above is super handy.
image

@tomcatnach
Copy link

+1 for this issue, really makes me want to use VSCode as somebody who has to format YAML.

@YiiGuxing
Copy link
Collaborator

It's Coming Soon!!!

IndentGuide

@vroudge
Copy link

vroudge commented Sep 26, 2019 via email

@YiiGuxing
Copy link
Collaborator

img

@Phoenix616
Copy link
Author

That looks really cool! I could imagine that the highlighting could get annoying after a while so maybe there could be an option to toggle that behaviour? (if that isn't already planed)

@YiiGuxing
Copy link
Collaborator

YiiGuxing commented Sep 27, 2019

@Phoenix616 The default is disabled because it is not perfect and there are still some issues that need to be resolved.
image

@Phoenix616
Copy link
Author

I was more referring to an option disabling the highlight effect when selecting the block (so that it just stays the same color without getting brighter)

@YiiGuxing
Copy link
Collaborator

YiiGuxing commented Sep 28, 2019

@Phoenix616 Highlighting is not easy to trigger.

@RacerDelux
Copy link

Looks like it does not work in .vue files.

@TheBestPessimist
Copy link

TheBestPessimist commented Oct 28, 2019

There's 1 thing which could be improved for this feature: when the cursor is over a bracket (and the bracket and its pair are highlighted), the corresonding indent guide should also be highlighted.

wdyt about this?

image

@JJCUBER
Copy link

JJCUBER commented Nov 1, 2019

I have this enabled, however it is not working in any of my file types (including .cs). Rainbow Brackets also isn't working as a whole for .shader files for me. Could someone please inform me on how to solve these issues? I am on the latest version of Rider currently.

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

No branches or pull requests