From 10cb81e81a3782b56ced3d00d7f5b912841b80a2 Mon Sep 17 00:00:00 2001 From: toofar Date: Sat, 23 Sep 2023 16:15:31 +1200 Subject: Disable accelerated 2d canvas by default. Ideally we would only enable this if we detected Intel graphics. But that kind of feature detection is difficult to do cross platform. It's easy to do with Qt (version.py) ... but it needs a QApplication and we are trying to figure out what CLI args to pass to Qt, so we can't do that. So just disable it for everyone for now. TODO: * tests * change to tri-state option, auto by default and make auto look at the webengine version and on for Qt6 < 6.7.0 --- qutebrowser/config/configdata.yml | 14 ++++++++++++++ qutebrowser/config/qtargs.py | 4 ++++ 2 files changed, 18 insertions(+) diff --git a/qutebrowser/config/configdata.yml b/qutebrowser/config/configdata.yml index e8eba9de3..f9058e875 100644 --- a/qutebrowser/config/configdata.yml +++ b/qutebrowser/config/configdata.yml @@ -385,6 +385,20 @@ qt.workarounds.locale: However, It is expected that distributions shipping QtWebEngine 5.15.3 follow up with a proper fix soon, so it is disabled by default. +qt.workarounds.disable_accelerated_2d_canvas: + default: true + type: Bool + backend: QtWebEngine + restart: true + desc: >- + Disable accelerated 2d canvas to avoid graphical glitches. + + On some setups graphical issues can occur on sites like Google sheets + and PDF.js. These don't occur when accelerated 2d canvas is turned off, + so we do that by default. + + So far these glitches only occur on some Intel graphics devices. + ## auto_save auto_save.interval: diff --git a/qutebrowser/config/qtargs.py b/qutebrowser/config/qtargs.py index 7513554b3..63c1c6b0a 100644 --- a/qutebrowser/config/qtargs.py +++ b/qutebrowser/config/qtargs.py @@ -324,6 +324,10 @@ _WEBENGINE_SETTINGS: Dict[str, Dict[Any, Optional[str]]] = { 'auto': '--enable-experimental-web-platform-features' if machinery.IS_QT5 else None, }, + 'qt.workarounds.disable_accelerated_2d_canvas': { + True: '--disable-accelerated-2d-canvas', + False: None, + }, } -- cgit v1.2.3-54-g00ecf