mirror of
https://github.com/moonlight-stream/moonlight-qt.git
synced 2025-07-01 23:35:55 +00:00
Avoid enabling High DPI mode on EGLFS to fix font rendering
This commit is contained in:
parent
77386f8dfc
commit
0437835bde
12
app/main.cpp
12
app/main.cpp
@ -285,13 +285,17 @@ int main(int argc, char *argv[])
|
|||||||
AntiHookingDummyImport();
|
AntiHookingDummyImport();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Enable High DPI support
|
// Avoid using High DPI on EGLFS. It breaks font rendering.
|
||||||
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
// https://bugreports.qt.io/browse/QTBUG-64377
|
||||||
|
if (QGuiApplication::platformName() != "eglfs") {
|
||||||
|
// Enable High DPI support
|
||||||
|
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
||||||
|
|
||||||
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
|
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
|
||||||
// Enable fractional High DPI scaling on Qt 5.14 and later
|
// Enable fractional High DPI scaling on Qt 5.14 and later
|
||||||
QGuiApplication::setHighDpiScaleFactorRoundingPolicy(Qt::HighDpiScaleFactorRoundingPolicy::PassThrough);
|
QGuiApplication::setHighDpiScaleFactorRoundingPolicy(Qt::HighDpiScaleFactorRoundingPolicy::PassThrough);
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
// This avoids using the default keychain for SSL, which may cause
|
// This avoids using the default keychain for SSL, which may cause
|
||||||
// password prompts on macOS.
|
// password prompts on macOS.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user