Skip to content

Conversation

@SamBent
Copy link
Contributor

@SamBent SamBent commented Mar 31, 2022

Fixes #6220

Description

In high DPI environment, most tooltips opened by the mouse close immediately.

This is because the SafeArea uses unscaled coordinates, while the current mouse point uses scaled coordinates. In high DPI, these are different, leading to false negatives from the containment test "is the mouse within the SafeArea".

Fixed by using unscaled coordinates for the mouse point. (And incidentally improving the perf by avoiding a lot of unnecessary transformations into, and out of, scaled coordinates.)

Customer Impact

Make ToolTips great again (in high DPI).

Regression

Regression in PR #5931.

Testing

Tested by hand, but thoroughly, in .NET 4.8.1. The automated tests don't cover high DPI, unless you explicitly run them on a machine whose primary monitor is high DPI.

This is a straightforward port of the .NET Fx fix, but should be tested in .NET Core anyway.

Risk

@SamBent SamBent requested a review from a team as a code owner March 31, 2022 00:21
@ghost ghost added the PR metadata: Label to tag PRs, to facilitate with triage label Mar 31, 2022
@ghost ghost requested review from dipeshmsft and singhashish-wpf March 31, 2022 00:21
@barnum1
Copy link

barnum1 commented Apr 5, 2022

Is there an estimated date for a version of .NET with a fix for this?
It's very awkward to explain to our users why tooltips do not work in our application.
Thanks.

@singhashish-wpf singhashish-wpf merged commit b0a8579 into dotnet:main Apr 5, 2022
@ghost ghost assigned SamBent Apr 5, 2022
@singhashish-wpf
Copy link
Contributor

We are trying to push this to 6.0.5; may servicing release. Will keep you posted.

@lindexi
Copy link
Member

lindexi commented Apr 20, 2022

I picked this PR to my application and I tested the my app for a week. This issue has been fixed and no new issues have been introduced.

@AlquistArj
Copy link

I'm also seeing the disappearing Tooltips in my WPF apps (using various versions of .NET from 4 up to 4.8). These have worked for years but stopped recently for some reason. Tooltips continue to work in Winforms and in WPF apps built with .NET5/6.

@barnum1
Copy link

barnum1 commented May 6, 2022

We are trying to push this to 6.0.5; may servicing release. Will keep you posted.

Hi, when is the estimated date for 6.0.5 release?

@barnum1
Copy link

barnum1 commented May 10, 2022

@singhashish-wpf
Could you please give us an estimated date of 6.0.5 release?
It is very difficult for us to explain this malfunction of our application to our users.
(We have no way to pull a PR and build a version ourselves.)

@singhashish-wpf
Copy link
Contributor

You can expect it to be out by tomorrow PST.

@singhashish-wpf Ashish Singh FTE Could you please give us an estimated date of 6.0.5 release? It is very difficult for us to explain this malfunction of our application to our users. (We have no way to pull a PR and build a version ourselves.)

@ghost ghost locked as resolved and limited conversation to collaborators Jun 9, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

PR metadata: Label to tag PRs, to facilitate with triage

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tooltip flicker in Ribbon Elements that are inside menu/dropdown

5 participants