Bug - Window Relative to mouse scaling is wrong with high DPI Display

https://ianknowles.blob.core.windows.net/temp/2019-02-04%2020-51-15.mp4

Mouse position relative to window when dragging is off in both axis…
Latest version of SDK and fresh audio app project.

Is this only happening with JUCE apps? Are you running on a Windows machine or in a VM? I’ve just tried this using Parallels on my macbook connected to a 4k screen and whilst the mouse position is incorrect like in your video it’s also happening for all the native apps.

Nope this was happening on a Desktop machine not a VM with 2 displays

So I think what’s happening is this.
I have a large 4K display and a normal 2k one off to the side for extra real estate. Both have differing scaling applied to keep icons / window size and text consistant across both. Having played around further I find that moving window around on the second display is as expected. I also noticed that older VST project with standalone app wrapper moves correctly. And that moving window between the 2 differing monitors scales as expected but in some cases I think the window is inheriting the wrong scale for positioning. I can’t replicate with other applications.

I know this isn’t really a problem. I just thought I’d bring it to your attention.

Does the 4k monitor have a custom scaling factor set? If you got to the display settings in Windows 10 you can see the scale factor that each window has and whether it has custom scaling applied. It’d also be useful to compare this value to the value that we have for the display in JUCE by doing something like this:

for (auto& d : Desktop::getInstance().getDisplays().displays)
    DBG (d.scale);

Although all we do is query the scale factor from Windows so I can’t see why it would be off.

Yes it does. Scaling factor is 1.5 and in windows display settings it’s set to 150% so matches.