You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a problem with the scaling of the context menu of WebView2.
We are developing a C++ MFC application in which various instances of WebView2 are integrated.
For various reasons, we set the scaling factors manually. Depending on which Windows DPI setting is currently selected by the user (125%, 150%, ...).
To accomplish this, I first call the function put_ShouldDetectMonitorScaleChanges(FALSE)
and afterwards put_RasterizationScale().
I call these directly in the ICoreWebView2CreateCoreWebView2ControllerCompletedHandler after successfully instantiating WebView2.
Since this call alone is apparently not sufficient to scale the content at all, I also call put_RasterizationScale() after each navigation event (in ICoreWebView2NavigationCompletedEventHandler).
(by the way: the official documentation of WebView2 is very sparse...)
The actual content of Webiew2 is scaled correctly, but the right-click context menu is not. This looks like this (depending on the Windows DPI setting):
Am I using the call to put_RasterizationScale() in the wrong place?
When should this call be made correctly?
Or is this still a bug?
Thanks for your bug report. I've assigned this to a dev that can best try to follow up on this. If they find that it is a bug, then we will add it to our tracked backlog to prioritize further!
edit: it is currently something we are already tracking in our backlog and is being worked on. In general could be a couple months out.
Description
I have a problem with the scaling of the context menu of WebView2.
We are developing a C++ MFC application in which various instances of WebView2 are integrated.
For various reasons, we set the scaling factors manually. Depending on which Windows DPI setting is currently selected by the user (125%, 150%, ...).
To accomplish this, I first call the function
put_ShouldDetectMonitorScaleChanges(FALSE)
and afterwards
put_RasterizationScale().
I call these directly in the ICoreWebView2CreateCoreWebView2ControllerCompletedHandler after successfully instantiating WebView2.
Since this call alone is apparently not sufficient to scale the content at all, I also call put_RasterizationScale() after each navigation event (in ICoreWebView2NavigationCompletedEventHandler).
(by the way: the official documentation of WebView2 is very sparse...)
The actual content of Webiew2 is scaled correctly, but the right-click context menu is not. This looks like this (depending on the Windows DPI setting):
Am I using the call to put_RasterizationScale() in the wrong place?
When should this call be made correctly?
Or is this still a bug?
A little help would be great!
Version
SDK: 1.0.1370.28
Runtime: 107.0.1418.24
Framework: Win32, MFC
OS: Win10, v1909 (Build 18363.2274)
AB#
The text was updated successfully, but these errors were encountered: