Signed-off-by: Jeremy Plsek <jeremyplsek@gmail.com>
*/
#include <QtGlobal>
+#include <cmath>
#include <csignal>
#ifdef Q_OS_UNIX
#include <QMessageBox>
#include <QDebug>
#include <QQuickStyle>
+#include <QQuickWindow>
using namespace OCC;
return 0;
}
+#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
+ QQuickWindow::setTextRenderType(QQuickWindow::NativeTextRendering);
+#else
+ // See https://bugreports.qt.io/browse/QTBUG-70481
+ if (std::fmod(app.devicePixelRatio(), 1) == 0) {
+ QQuickWindow::setTextRenderType(QQuickWindow::NativeTextRendering);
+ }
+#endif
+
// check a environment variable for core dumps
#ifdef Q_OS_UNIX
if (!qEnvironmentVariableIsEmpty("OWNCLOUD_CORE_DUMP")) {