summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/python-mapnik/python-mapnik_std_optional.patch
diff options
context:
space:
mode:
authorMaximilian Bosch <maximilian@mbosch.me>2021-12-11 15:24:09 +0100
committerMaximilian Bosch <maximilian@mbosch.me>2021-12-24 15:36:52 +0100
commitb3823a35e5579e5d1a051f6011bc86ea0e754b50 (patch)
tree1170c90747dbc3271584a9daa88692e1750979e1 /pkgs/development/python-modules/python-mapnik/python-mapnik_std_optional.patch
parente2b2136d6302cd2936b49eeda58b55816758a3aa (diff)
qtwayland: declare proper `app_id` for wrapped executables
Since NixOS 21.11 it seems as if QT uses Wayland if possible[1]. However, my `pinentry-qt` flavor stopped floating because it's now running in Wayland-mode rather than in XWayland mode where this seems to be fine. I wanted to add a rule to my `sway(1)`-config for that, but realized that `pinentry` is missing an `app_id` to match: $ swaymsg -t get_tree | jq '.nodes[2].nodes[1].nodes[1].nodes[1].app_id' "" This is because `QWaylandWindow::initWindow()` uses the application's `baseName` to determine the app window. Unfortunately the `baseName` drops all chars of the filename after the first dot[2]. This means that every wrapped Nix package (i.e. `pkgs.foo` with `$out/bin/.foo-wrapped`) will have an empty-string as baseName because the first character of the filename is a dot. Since we're using the `wrapQtAppsHook` quite excessively, a lot of programs are affected by this. In order to work around this, I implemented a small patch for `qtwayland` that strips away the `nixpkgs`-specific `.(name)-wrapped` of a filename if needed and then sets the `app_id` to the expected `baseName`. This is useful to make e.g. `sway`-configs with `for_window`[3]-expressions from other distros compatible. With this change, the `app_id` is set as I'd expect it: $ swaymsg -t get_tree | jq '.nodes[2].nodes[1].nodes[1].nodes[1].app_id' "pinentry-qt" Even though we'll need the patch to get e.g. `foo` from `.foo-wrapped`, I decided to file a bug-report against upstream[4]. [1] https://nixos.org/manual/nixos/stable/release-notes.html#sec-release-21.11 [2] https://doc.qt.io/qt-5/qfileinfo.html#baseName [3] https://man.archlinux.org/man/sway.5.en [4] https://bugreports.qt.io/browse/QTBUG-99137
Diffstat (limited to 'pkgs/development/python-modules/python-mapnik/python-mapnik_std_optional.patch')
0 files changed, 0 insertions, 0 deletions