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

Debug hover is show on top of the item I wanted the hover for #107695

Closed
sandy081 opened this issue Sep 29, 2020 · 8 comments
Closed

Debug hover is show on top of the item I wanted the hover for #107695

sandy081 opened this issue Sep 29, 2020 · 8 comments
Assignees
Labels
debug Debug viewlet, configurations, breakpoints, adapter issues under-discussion Issue is under discussion for relevance, priority, approach
Milestone

Comments

@sandy081
Copy link
Member

Testing #107156

  • I am debugging the tree view sample extension in our extension samples and when I hovered on following rootPath value in vscode.workspace.rootPath, the debug hover is shown covering the item completely

image

image

@isidorn
Copy link
Contributor

isidorn commented Sep 29, 2020

The debug hover currently sets the preference to be placed above the location here. It is up to the editor to choose the exact location, and in this particular case the editor decided to show the hover covering the item completely.

I am not sure if we can do anything regarding this.

fyi @alexdima for potential ideas

@isidorn isidorn added debug Debug viewlet, configurations, breakpoints, adapter issues under-discussion Issue is under discussion for relevance, priority, approach labels Sep 29, 2020
@isidorn isidorn added this to the Backlog milestone Sep 29, 2020
@alexdima
Copy link
Member

@isidorn Maybe there is a missing layoutContentWidget call after changing the inside of the debug hover?

The positioning code will measure the widget and then cache its height. It looks like the editor positions the widget as if it would be only one line height high (i.e. without the wrapping seen in the picture)

@isidorn
Copy link
Contributor

isidorn commented Sep 30, 2020

@alexdima good idea, but that does not seem to be the case looking at the code.
I always first set the content of the widget, and only then call the layoutContentWidget
However the widget word wraps, and in this particualr case it looks like the css breaks the widget in two lines. So I am not aware how many lines the widget will be, it is all handled by css.

@alexdima
Copy link
Member

alexdima commented Oct 1, 2020

@isidorn How about this code path --

this.toDispose.push(this.tree.onDidChangeContentHeight(() => this.layoutTreeAndContainer(false)));
.. Shouldn't layoutContentWidget be called if there is a chance that the tree has expanded its height?

isidorn added a commit that referenced this issue Oct 1, 2020
@isidorn
Copy link
Contributor

isidorn commented Oct 1, 2020

@alexdima You are correct.
I have pushed a change to tackle that code path. However I do not expect this to fix @sandy081 case since in his case the debug hover is not a tree, but a simple value (which is a different code path).
Though might fix it... @sandy081 let me know if you no longer see this

@sandy081
Copy link
Member Author

sandy081 commented Oct 1, 2020

Is this in today's insiders?

@isidorn
Copy link
Contributor

isidorn commented Oct 1, 2020

@sandy081 no, will be tomorrow. I just pushed 1 hour ago :)

msftwindowslinux pushed a commit to msftwindowslinux/vscode that referenced this issue Oct 2, 2020
msftwindowslinux pushed a commit to msftwindowslinux/vscode that referenced this issue Oct 2, 2020
@isidorn
Copy link
Contributor

isidorn commented Nov 2, 2020

Closing as I pushed an improvment for this and no further actoin is planned

@isidorn isidorn closed this as completed Nov 2, 2020
@github-actions github-actions bot locked and limited conversation to collaborators Dec 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
debug Debug viewlet, configurations, breakpoints, adapter issues under-discussion Issue is under discussion for relevance, priority, approach
Projects
None yet
Development

No branches or pull requests

3 participants