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

`app_id` declared by `QWaylandWindow::initWindow()` is empty if the executable starts with a dot

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 5.15.10
    • QPA: Wayland
    • None
    • Linux/Wayland

    Description

      On NixOS, a Linux distribution, a lot of programs are wrapped by shell scripts to inject e.g. additional variables or CLI flags. This means that `foo` is a shell-script and `.foo-wrapped` is the actual program being execed into by the wrapper.

      The `app_id` on Wayland (in `QWaylandWindow::initWindow()`) is determined by using `QFileInfo::baseName()` on the application's file path (`QCoreApplication::instance()->applicationFilePath()`).

      Since the `applicationFilePath` is usually the one where the filename is `.foo-wrapped`, the base-name is empty and thus the `app_id` is also empty.

      A possible workaround for this is to use `QFileInfo::fileName()` instead.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qt.team.graphics.and.multimedia Qt Graphics Team
            ma27 Maximilian Bosch
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes