[quote=“Anomareh”]
[quote=“ajpalkovic”]Additionally, as some people point out the active one shows up one tab higher than where they should. My screenshot shows that too.
I’m torn on this. On the one hand, I think it’s smart to do that for normal statements. However, for lines that are indented, (like for loops, html tags) I hate it. Maybe you could use the grammar indent rules to determine if it should show the active guide one column higher or at the current column, if that makes sense. Like, if the indent rules say dont indent this line, then do what sublime does now. If the indent rules say indent the next line. then show the active guide at the beginning of the text, like the beginning of the for loop, not two spaces before the for loop.[/quote]
Kinda hard to parse what you mean :s Maybe a picture? I think the expected behavior would be to check the character to the right of the guide, if it’s whitespace or the end of the line show it, if it’s anything else don’t. Being able to see where lines that contain nothing but whitespace are indented to is really important, especially in languages like Python.[/quote]
Let’s say I have this code:
TAB TAB if(true) {
TAB TAB TAB doSomething();
TAB TAB }
Right now, if I click anywhere on line 0 or line 2, sublime shows an active indent guide to the right of the first tab.
If I click anywhere on line 1, sublime shows an active indent guide to the right of the second tab.
I suggest this:
If I click before the if on line 0, it shows an active indent guide at the tab closest to where I clicked.
If I click anywhere at or after the if, it shows an active indent guide to the right of the second tab. (This is because the grammar would say that line 0 changes the indent of the next line, so it shows the active indent guide at that line. The idea is the active indent guide runs from the ‘i’ to the ‘}’)
If I click before doSomething, it shows an active indent guide at the tab closest to where I clicked.
If I clicked on or after doSomething, it shows an active indent guide to the right of the second tab. (This is what sublime does now. The idea is this line does not change the indent level, show show the active indent guide at the ‘parent scope’).