Genio
Genio copied to clipboard
Outline: Mark current position of editor view
I was wondering... Would it be useful to mark the symbols in the outline view that currently shown in the editor view? Esp. for long functions, you'd have a reminder in which function you're are right now and what are the functions above/below it.
The outline list could bolden all symbol items that currently visible in the editor view. I suppose the outline list should NOT auto-scroll to have those bolded symbols always visible. This would collide with the user scrolling the outline list 'manually'.
Just to add, maybe using a tinted background for the marked items would look nicer?
Just a few thoughts on it. There is no easy way to determine the symbols currently shown in the editor but we may determine the range and do a search in the outline to pick the symbols that completely fall into it. As usual this should be done when idle only.
I was wondering... Would it be useful to mark the symbols in the outline view that currently shown in the editor view? Esp. for long functions, you'd have a reminder in which function you're are right now and what are the functions above/below it.
Yes, it would be very useful. Eclipse (which I used as a "template" for the Outline) selects the symbol in the outline where the caret is in the editor. We'd just have to find out a way to do that.
Implemented in #396
Appears to work nicely! At least wrt the smaller goal to show the symbol of the cursor position. The cherry on top would be to tint the background of the symbol items in the Outline pane that are currently visible in the editor. In case you're just scrolling around without moving the cursor position...
I appreciate that this may be more difficult. :) I suppose you'd have to check the top line and bottom line of the current editor view periodically and determine what symbols they belong to and tint all symbol items in the Outline pane between...
Anyway, nice change!
I see your idea but I'm afraid it can't be implemented simply because the list of symbols may be not following the code order.. For example clangd orders first the attributes then the methods of a class.
I think the feature you describe is the "MiniMap/code-scroller": a zoomed out view of the code that you can quickly navigate.
Possibly. Maybe as another tab to add tot he right Outline pane someday. Or some keyboard key that collapses all blocks in the editor view and zoom to 25% while holding. That should compress things nicely and still allows you to orient yourself.
Implemented in #396
Nice work! Can we close this ? The other request seems interesting, but maybe a bit unrealistic for now.