Desktop::setGlobalScaleFactor() issues

For my plugin UI rescaling I’m trying to make the change from setScaleFactor() to Desktop::setGlobalScaleFactor() as has been recommended with the recent changes. However, there’s a couple of blocking issues:

  1. ProTools does not scale the UI window. When changing the desktop scale factor the content and layout of the UI is scaled correctly, but the window size itself does not update. This means the UI is cropped.

  2. On all plugin formats there is something wrong with the mouse over coordinates. I have a few components using mouseEnter() as well as Slider tooltips, and they are not triggered at the correct mouse position when desktopScaleFactor != 1. Sometimes it works with a fresh plugin instance, but after moving the plugin window the coordinates seem to have shifted and the mouseEnter() is called at the wrong position. Mouse clicks and drags work correctly.

I’m on the latest JUCE develop branch.
@ed95 is this something you can have a look at?


1 Like

Thanks for reporting. Both of these issues should now be fixed on the develop and juce6 branches:


Nice, both seem to work great now.

Hi Ericsen,

Can you help me out what you did exactly. We’re trying to set the scale in our AAX plugin (win and mac). We used to apply setScaleFactor(). But as suggested, we now use Desktop::setGlobalScaleFactor() but no result. The Editor is scaling correctly but the window isn’t. I’ve also tried setting the scale by using setTransform() in the editor with an AffineTransform. Also no luck.
All methods seem to work great for the other plugin formats.
We’re using Juce 6.0.1at the moment.


Hi Milan,

Apologies for the late reply.

I don’t think I did anything besides using setSize() to define the UI dimensions, and then Desktop::getInstance().setGlobalScaleFactor() to set the scale. I believe I might have called setSize after changing scale.