Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Reveal closer to top (center body, not signature) #80727
alexdima left a comment •
This cannot be implemented by changing the behavior of
This could be implemented by adding a new kind of
This needs some testing whether the UX really is better in all cases. I had to make quite a few changes and I removed the
Only the history navigation is different because JetBrains remembers the scroll position of each history entry. If you resize the window it always scrolls like with go to definition. I think VS Code should remember the scroll position, too, but I didn't look into that as part of this PR.
Very small viewports (e.g. when pressing SHIFT+F12) needed some tuning, so you can see enough preceding lines. The code ensures a minimum scroll position of 100px from the top.
What do you think?
@wkornewald I am sorry, but I cannot accept a PR that changes the world, because I cannot estimate its impact. That was really the point of my first review. Can you please make a change that is limited to go to definition or outline? Pick one, and let's tweak that one. If we receive positive feedback (I can also take the change to VSCode's UX call), we can then expand it to the entire universe of reveal calls... but I cannot accept such a huge PR because I cannot take responsibility for such a large impact change.