Skip to content
Snippets Groups Projects
Commit c3e581ce authored by Yuya Nishihara's avatar Yuya Nishihara
Browse files

Add example of enabling pass-through dpi scaling

parent 92d6272e
No related branches found
No related tags found
No related merge requests found
......@@ -4,6 +4,10 @@
int main(int argc, char *argv[])
{
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
QGuiApplication::setHighDpiScaleFactorRoundingPolicy(
Qt::HighDpiScaleFactorRoundingPolicy::PassThrough);
#endif
QGuiApplication app(argc, argv);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment