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

Marks on scrollbar: smarter navigation (center the mark vertically) #13449

Open
jkuebart opened this issue Jul 7, 2022 · 4 comments
Open

Marks on scrollbar: smarter navigation (center the mark vertically) #13449

jkuebart opened this issue Jul 7, 2022 · 4 comments
Labels
Area-Settings Issues related to settings and customizability, for console or terminal Area-TerminalControl Issues pertaining to the terminal control (input, selection, keybindings, mouse interaction, etc.) Issue-Task It's a feature request, but it doesn't really need a major design. Product-Terminal The new Windows Terminal.
Milestone

Comments

@jkuebart
Copy link

jkuebart commented Jul 7, 2022

Description of the new feature/enhancement

Since #12948 we have the long-awaited marks on the scrollbar, along with the possibility to navigate between them.

Unfortunately, the navigation isn't very smart yet. When jumping to the previous/next mark, the window area merely scrolls such that the marked line becomes visible.

It would be much nicer if

  • the marked line would end up somewhere near the middle of the window – more often than not, what I'm interested in is the content directly above or below the mark, and this would then be immediately visible.
  • the line was highlighted (briefly) after the navigation action – this would make it easy to immediately find the marked line visually.

Proposed technical implementation details (optional)

The »jump to mark« command should scroll the window area such that the target line ends up near the middle of the screen whenever possible. A temporary highlight effect should be used to visually guide the user to the target line.

@jkuebart jkuebart added the Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. label Jul 7, 2022
@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Jul 7, 2022
@zadjii-msft
Copy link
Member

These are great ideas to include as a part of #11000. I'm gonna split this into two issues to help better track these requests. Let's use this thread for "the target line ends up near the middle of the screen", and I'll fork off the other request.

@zadjii-msft zadjii-msft changed the title Marks on scrollbar: smarter navigation Marks on scrollbar: smarter navigation (center the mark vertically) Jul 7, 2022
@zadjii-msft zadjii-msft added Area-TerminalControl Issues pertaining to the terminal control (input, selection, keybindings, mouse interaction, etc.) Area-Settings Issues related to settings and customizability, for console or terminal Product-Terminal The new Windows Terminal. Issue-Task It's a feature request, but it doesn't really need a major design. and removed Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. labels Jul 7, 2022
@ghost ghost removed the Needs-Tag-Fix Doesn't match tag requirements label Jul 7, 2022
@zadjii-msft zadjii-msft added this to the Backlog milestone Jul 7, 2022
@zadjii-msft zadjii-msft removed the Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting label Jul 7, 2022
@Jaykul
Copy link
Contributor

Jaykul commented Jul 11, 2022

Are we sure we want the target near the middle of the screen? If we're auto-marking prompts, the most common marks are going to be at the start (or end, depending on how you think of it) of a command.

With that turned on (the way I have it right now) I want to see the mark at or near the top of the screen, so I can see as much of the output as possible.

Incidentally, it would be nice if the mark functionality followed the behavior of (and even key-bindings for) search, regardless -- so if we had a way to make it appear near the center of the screen, it should be optional, and should would work for both.

@zadjii-msft
Copy link
Member

Don't worry, that's how I already interpreted this request - as a request for an optional setting here:

Frankly, I'm a huge fan of the "scroll s.t. the mark appears at the top of the viewport" style, for the same reason you've mentioned above. But if folks want to optionally scroll the prompt to the middle of the viewport, that doesn't seem terribly difficult to implement or maintain.

@jkuebart
Copy link
Author

jkuebart commented Jul 11, 2022

Are we sure we want the target near the middle of the screen? If we're auto-marking prompts, the most common marks are going to be at the start (or end, depending on how you think of it) of a command.

With that turned on (the way I have it right now) I want to see the mark at or near the top of the screen, so I can see as much of the output as possible.

While this sounds convincing, I have thought about it and this is how I can describe the use case: The marked prompts are indeed between the interesting content which is the command output. In my experience, very frequently I need the end of the output of some historical command just before the next prompt. For example, this is the case for error messages at the end of a compilation run whose complete output doesn't fit on a screen.

With the current behaviour, finding this requires skipping one prompt further up and then back down again to reveal the end of the command output, which is inconvenient.

Hope I could provide some explanation for this feature request ;-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Settings Issues related to settings and customizability, for console or terminal Area-TerminalControl Issues pertaining to the terminal control (input, selection, keybindings, mouse interaction, etc.) Issue-Task It's a feature request, but it doesn't really need a major design. Product-Terminal The new Windows Terminal.
Projects
None yet
Development

No branches or pull requests

3 participants