From 595a7dcaffe360d4d817459408c2964fa5dabc94 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Fri, 4 Nov 2016 12:47:10 +0200 Subject: [PATCH] Enable attribute Qt::AA_EnableHighDpiScaling for support HighDpi displays. --HG-- branch : develop --- src/app/tape/main.cpp | 4 ++++ src/app/valentina/main.cpp | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/src/app/tape/main.cpp b/src/app/tape/main.cpp index 42e1d5e4f..81574be0a 100644 --- a/src/app/tape/main.cpp +++ b/src/app/tape/main.cpp @@ -49,6 +49,10 @@ int main(int argc, char *argv[]) qt_qhash_seed.store(0); // Lock producing random attribute order in XML +#if QT_VERSION >= QT_VERSION_CHECK(5, 6, 0) + QApplication::setAttribute(Qt::AA_EnableHighDpiScaling); // DPI support +#endif + MApplication app(argc, argv); app.InitOptions(); diff --git a/src/app/valentina/main.cpp b/src/app/valentina/main.cpp index 353e33aae..60348d25f 100644 --- a/src/app/valentina/main.cpp +++ b/src/app/valentina/main.cpp @@ -53,6 +53,10 @@ int main(int argc, char *argv[]) qt_qhash_seed.store(0); // Lock producing random attribute order in XML +#if QT_VERSION >= QT_VERSION_CHECK(5, 6, 0) + QApplication::setAttribute(Qt::AA_EnableHighDpiScaling); // DPI support +#endif + VApplication app(argc, argv); app.InitOptions();