diff --git a/hosts/s-home.nix b/hosts/s-home.nix index 23b9ca9..0de5256 100644 --- a/hosts/s-home.nix +++ b/hosts/s-home.nix @@ -4,15 +4,16 @@ home.packages = [ pkgs.nvtopPackages.nvidia # Wrap krita so Qt's GTK3 platform theme can find the GSettings schemas - # it needs. Without this, opening any file dialog on GNOME crashes: - # qgtk3 -> g_settings_new("org.gtk.Settings.FileChooser") -> glib abort - # because the gtk3 schema dir isn't in XDG_DATA_DIRS for this process. + # it needs (file dialog crash workaround), and force the Wayland Qt platform + # plugin (defaults to xcb, which hits XWayland's max-clients limit once Slack/ + # Discord/Chrome are open — Wayland-native also gives working Wacom pressure). (pkgs.symlinkJoin { name = "krita"; paths = [ pkgs.krita ]; nativeBuildInputs = [ pkgs.makeWrapper ]; postBuild = '' wrapProgram $out/bin/krita \ + --set QT_QPA_PLATFORM wayland \ --prefix XDG_DATA_DIRS : "${pkgs.gtk3}/share/gsettings-schemas/${pkgs.gtk3.name}" \ --prefix XDG_DATA_DIRS : "${pkgs.gsettings-desktop-schemas}/share/gsettings-schemas/${pkgs.gsettings-desktop-schemas.name}" '';