diff --git a/.config/qutebrowser/config.py b/.config/qutebrowser/config.py index 94b2b0943e92f19e55a98ba81482a96f8818f4de..909285dd140439736542be5c32a536532fabe89d 100644 --- a/.config/qutebrowser/config.py +++ b/.config/qutebrowser/config.py @@ -2,6 +2,8 @@ # Documentation: # qute://help/configuring.html # qute://help/settings.html +from subprocess import run +from os import environ # Stop flake8 nagging c = c # noqa: F821 @@ -83,3 +85,6 @@ config.bind('b', 'set-cmd-text -s :buffer') # config.bind('K', 'scroll-page 0 -1') config.bind('J', 'tab-next') config.bind('K', 'tab-prev') + +if run(["modprobe", "nvidia"]).returncode == 0 and environ["XDG_SESSION_TYPE"] == "wayland": + c.qt.environ = {"QMLSCENE_DEVICE": "softwarecontext"}