mirror of
https://github.com/WerWolv/ImHex.git
synced 2026-03-30 13:05:25 -05:00
fix: Properly apply backing scaling to pixel perfect default font
This commit is contained in:
@@ -55,7 +55,7 @@ namespace hex::fonts {
|
||||
// If there's no custom font set, or it failed to load, fall back to the default font
|
||||
if (!defaultFont.has_value()) {
|
||||
if (pixelPerfectFont) {
|
||||
fontSize = std::max(1.0F, std::floor(ImHexApi::System::getGlobalScale() * 13.0F));
|
||||
fontSize = std::max(1.0F, std::floor(ImHexApi::System::getGlobalScale() * ImHexApi::System::getBackingScaleFactor() * 13.0F));
|
||||
defaultFont = fontAtlas->addDefaultFont();
|
||||
} else
|
||||
defaultFont = fontAtlas->addFontFromRomFs("fonts/JetBrainsMono.ttf", fontSize, true, ImVec2());
|
||||
|
||||
Reference in New Issue
Block a user