[0.19][Web] Remove HiDPI fix when using QTWEBVIEW

The screen scale adjustment code here should not be necessary when using
the Chromium-based QtWebView widget, which correctly handles logical vs.
device px units. The scaling causes poor font size choice when used on
ultrawide monitors, as reported in
https://forum.freecadweb.org/viewtopic.php?p=485431
This commit is contained in:
Chris Hennes
2021-03-08 18:51:06 +01:00
committed by wwmayer
parent dfc3e2b9a6
commit 159a71bba7
+2
View File
@@ -239,6 +239,7 @@ Py::Object BrowserViewPy::setHtml(const Py::Tuple& args)
WebView::WebView(QWidget *parent)
: QWEBVIEW(parent)
{
#ifdef QTWEBKIT
// Increase html font size for high DPI displays
#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
QRect mainScreenSize = QApplication::primaryScreen()->geometry();
@@ -248,6 +249,7 @@ WebView::WebView(QWidget *parent)
if (mainScreenSize.width() > 1920){
setTextSizeMultiplier (mainScreenSize.width()/1920.0);
}
#endif
}
#ifdef QTWEBENGINE