mirror of
https://github.com/WerWolv/ImHex.git
synced 2026-03-29 00:10:02 -05:00
fix: Font being scaled too large if main screen DPI is higher than secondary screen DPIs
#2419
This commit is contained in:
@@ -16,6 +16,7 @@
|
||||
#include <nlohmann/json.hpp>
|
||||
|
||||
#include <string>
|
||||
#include <hex/api/events/events_lifecycle.hpp>
|
||||
|
||||
namespace hex::fonts { bool setupFonts(); }
|
||||
|
||||
@@ -108,8 +109,10 @@ namespace hex::plugin::builtin {
|
||||
ImHexApi::System::impl::setGlobalScale(interfaceScaling);
|
||||
});
|
||||
|
||||
const auto nativeScale = ImHexApi::System::getNativeScale();
|
||||
EventDPIChanged::post(nativeScale, nativeScale);
|
||||
EventImHexStartupFinished::subscribe([] {
|
||||
const auto nativeScale = ImHexApi::System::getNativeScale();
|
||||
EventDPIChanged::post(nativeScale, nativeScale);
|
||||
});
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user