Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-75732

Automatically select the wayland platform plugin when WAYLAND_DISPLAY is set

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Done
    • P3: Somewhat important
    • 6.0.0
    • 5.12.3
    • QPA: Wayland
    • None
    • Linux/Wayland
    • 400fb27208ae32b9080e12b17d875179b27689f4 (qt/qtbase/dev)

    Description

      We currently use XDG_SESSION_TYPE for detecting whether to use Wayland or XCB, but that environment variable is a non-standardized part of systemd, and for instance not set by compositors when started from the command line.

      Sway users often complain about this.

      If we check WAYLAND_DISPLAY, instead, we can cover more cases. Although libwayland defaults to wayland-0 if WAYLAND_DISPLAY is not set, the general consensus in the wayland community seems to be that compositors should set WAYLAND_DISPLAY, and that adding the default to libwayland was a mistake. Therefore, we can be reasonably sure that a compositor is going to set WAYLAND_DISPLAY.

      Attachments

        For Gerrit Dashboard: QTBUG-75732
        # Subject Branch Project Status CR V

        Activity

          People

            esabraha Eskil Abrahamsen Blomfeldt
            johanhelsing Johan Helsing
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes