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

Terminal hover positioning is unfriendly #162336

Open
jrieken opened this issue Sep 29, 2022 · 6 comments
Open

Terminal hover positioning is unfriendly #162336

jrieken opened this issue Sep 29, 2022 · 6 comments
Assignees
Labels
confirmed Issue has been confirmed by VS Code Team member feature-request Request for new features or functionality terminal-links ux User experience issues
Milestone

Comments

@jrieken
Copy link
Member

jrieken commented Sep 29, 2022

  • have a long'ish link, like echo https://github.com/microsoft/vscode/pull/162335
  • mouse-hover over the number
  • 🐛 the link hover appears left aligned, ignores my mouse x-coordinate, and forces me to move the cursor into it (which can be finicky)
Screen.Recording.2022-09-29.at.14.21.44.mov
@Tyriar
Copy link
Member

Tyriar commented Sep 29, 2022

The terminal does exactly what the editor does:

image

@Tyriar Tyriar added the under-discussion Issue is under discussion for relevance, priority, approach label Sep 29, 2022
@alexdima alexdima added the editor-hover Editor mouse hover label Sep 30, 2022
@daviddossett
Copy link
Contributor

Do we know if there's a good reason we haven't respected the mouse position in the editor case? Seems like it would be a good idea to update both if there isn't one.

@Tyriar
Copy link
Member

Tyriar commented Oct 3, 2022

@daviddossett these are general editor hovers rules I think, for example it works well here as you read the symbol and info is directly above:

image

Not sure about the decision that went into that, but it's probably something around keyboard interaction being the typical way to trigger the hovers, which doesn't apply as much to links.

@alexdima
Copy link
Member

Do we know if there's a good reason we haven't respected the mouse position in the editor case? Seems like it would be a good idea to update both if there isn't one.

The reason was, as @Tyriar mentioned, to align the hover with the current word / symbol being hovered. Over the years, we've added a range property to a hover result, where a hover provider can express what range their hover applies to, and we moved to use that. Most of the times, that range is something sensible, like the current word/symbol. But I agree that this doesn't work very well if the range is a lot larger, if it begins far away from the mouse position or on a wrapped line, etc. This came up a lot over the years, I'll look into improving things.

@alexdima
Copy link
Member

The editor positioning is now improved via #163970 , let's keep this issue around to track the terminal hover positioning.

@alexdima alexdima removed the editor-hover Editor mouse hover label Oct 19, 2022
@alexdima alexdima removed their assignment Oct 19, 2022
@Tyriar Tyriar modified the milestones: October 2022, On Deck Oct 24, 2022
@Tyriar Tyriar added feature-request Request for new features or functionality ux User experience issues terminal General terminal issues that don't fall under another label and removed under-discussion Issue is under discussion for relevance, priority, approach labels Oct 24, 2022
@daviddossett daviddossett removed their assignment Dec 6, 2022
@Tyriar Tyriar added the workbench-hover Hover issues in the workbench label May 12, 2023
@legomushroom
Copy link
Member

Was able to repro this today on stable 1.95.3(f1a4fb) so the issue still exists.

@legomushroom legomushroom added the confirmed Issue has been confirmed by VS Code Team member label Dec 10, 2024
@Tyriar Tyriar modified the milestones: On Deck, Backlog Dec 16, 2024
@Tyriar Tyriar added terminal-links and removed terminal General terminal issues that don't fall under another label workbench-hover Hover issues in the workbench labels Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
confirmed Issue has been confirmed by VS Code Team member feature-request Request for new features or functionality terminal-links ux User experience issues
Projects
None yet
Development

No branches or pull requests

5 participants