Open timsueberkrueb opened 5 years ago
Since QCoreApplication::setAttribute is a static function, wrapping it should be very easy. As of enum Qt::ApplicationAttribute, there are quite a few values, but nothing extraordinary. Also in that case, QCoreApplication::testAttribute complementary function should be implemented as well.
Note that setting this attribute manually is not required in Qt6 anymore, and new projects generated by Qt Creator contain this version guard boilerplate:
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
#endif
This would be useful in general. For writing QtQuick Controls apps, specifically (e.g. see my template for Ubuntu touch it would be useful to be able to enable High Dpi Scaling. I'm not sure how this should get implemented. Should we try to wrap all attributes or add a specific function for enablling High Dpi scaling only?