From 39f7ad24c5cd9cde3fa2a2d90e17fda24e288b52 Mon Sep 17 00:00:00 2001 From: Joe Cooper Date: Mon, 24 Nov 2025 12:02:24 -0600 Subject: [PATCH] Fix scale factor bug on Linux/MacOS --- Source/PluginEditor.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Source/PluginEditor.cpp b/Source/PluginEditor.cpp index fd97fbf8..a5f1b3f1 100644 --- a/Source/PluginEditor.cpp +++ b/Source/PluginEditor.cpp @@ -445,9 +445,8 @@ float DexedAudioProcessorEditor::getLargestScaleFactor() { // validate if there is really a display that can show the complete plugin size for (auto& display : Desktop::getInstance().getDisplays().displays) { - float ratio = display.scale; - int height = ratio * display.userArea.getHeight(); - int width = ratio * display.userArea.getWidth(); + const int height = display.userArea.getHeight(); + const int width = display.userArea.getWidth(); TRACE("Testing size %d x %d < Dexed Window %d x %d", height, width, rect.getWidth(), rect.getHeight() ); if ( height > rect.getHeight() && width > rect.getWidth() ) { @@ -583,4 +582,4 @@ bool DexedAudioProcessorEditor::keyPressed(const KeyPress& key, Component* origi } return false; -} \ No newline at end of file +}