about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/qgnomeplatform
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2023-08-23 10:09:14 +0000
committerAlyssa Ross <hi@alyssa.is>2023-08-26 09:07:03 +0000
commit63dabcc77ef9a56655e1ca2ab2e25e6163a72c1f (patch)
treed58934cb48f9c953b19a0d0d5cffc0d0c5561471 /nixpkgs/pkgs/development/libraries/qgnomeplatform
parentc4eef3dacb2a3d359561f30917d9e3cc4e041be9 (diff)
parent91a22f76cd1716f9d0149e8a5c68424bb691de15 (diff)
downloadnixlib-63dabcc77ef9a56655e1ca2ab2e25e6163a72c1f.tar
nixlib-63dabcc77ef9a56655e1ca2ab2e25e6163a72c1f.tar.gz
nixlib-63dabcc77ef9a56655e1ca2ab2e25e6163a72c1f.tar.bz2
nixlib-63dabcc77ef9a56655e1ca2ab2e25e6163a72c1f.tar.lz
nixlib-63dabcc77ef9a56655e1ca2ab2e25e6163a72c1f.tar.xz
nixlib-63dabcc77ef9a56655e1ca2ab2e25e6163a72c1f.tar.zst
nixlib-63dabcc77ef9a56655e1ca2ab2e25e6163a72c1f.zip
Merge branch 'nixos-unstable' of https://github.com/NixOS/nixpkgs
Conflicts:
	nixpkgs/pkgs/build-support/go/module.nix
	nixpkgs/pkgs/development/python-modules/django-mailman3/default.nix
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/qgnomeplatform')
-rw-r--r--nixpkgs/pkgs/development/libraries/qgnomeplatform/default.nix6
-rw-r--r--nixpkgs/pkgs/development/libraries/qgnomeplatform/qt6-cursor-fix.patch53
2 files changed, 58 insertions, 1 deletions
diff --git a/nixpkgs/pkgs/development/libraries/qgnomeplatform/default.nix b/nixpkgs/pkgs/development/libraries/qgnomeplatform/default.nix
index b32414f855d0..4c75b475c17c 100644
--- a/nixpkgs/pkgs/development/libraries/qgnomeplatform/default.nix
+++ b/nixpkgs/pkgs/development/libraries/qgnomeplatform/default.nix
@@ -33,6 +33,10 @@ stdenv.mkDerivation rec {
       src = ./hardcode-gsettings.patch;
       gds_gsettings_path = glib.getSchemaPath gsettings-desktop-schemas;
     })
+
+    # Backport cursor fix for Qt6 apps
+    # Ajusted from https://github.com/FedoraQt/QGnomePlatform/pull/138
+    ./qt6-cursor-fix.patch
   ];
 
   nativeBuildInputs = [
@@ -69,7 +73,7 @@ stdenv.mkDerivation rec {
     description = "QPlatformTheme for a better Qt application inclusion in GNOME";
     homepage = "https://github.com/FedoraQt/QGnomePlatform";
     license = licenses.lgpl21Plus;
-    maintainers = teams.gnome.members ++ (with maintainers; [ ]);
+    maintainers = with maintainers; [ ];
     platforms = platforms.linux;
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/qgnomeplatform/qt6-cursor-fix.patch b/nixpkgs/pkgs/development/libraries/qgnomeplatform/qt6-cursor-fix.patch
new file mode 100644
index 000000000000..40438aae33ed
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/qgnomeplatform/qt6-cursor-fix.patch
@@ -0,0 +1,53 @@
+diff --git a/src/common/gnomesettings.cpp b/src/common/gnomesettings.cpp
+index 961f75d..d947eb2 100644
+--- a/src/common/gnomesettings.cpp
++++ b/src/common/gnomesettings.cpp
+@@ -210,7 +210,7 @@ GnomeSettingsPrivate::GnomeSettingsPrivate(QObject *parent)
+                                               QStringLiteral("SettingChanged"), this, SLOT(portalSettingChanged(QString,QString,QDBusVariant)));
+     }
+ 
+-    if (QGuiApplication::platformName() != QStringLiteral("xcb")) {
++    if (true) {
+         cursorSizeChanged();
+         cursorThemeChanged();
+     }
+@@ -347,11 +347,11 @@ void GnomeSettingsPrivate::gsettingPropertyChanged(GSettings *settings, gchar *k
+     } else if (changedProperty == QStringLiteral("monospace-font-name")) {
+         gnomeSettings->fontChanged();
+     } else if (changedProperty == QStringLiteral("cursor-size")) {
+-        if (QGuiApplication::platformName() != QStringLiteral("xcb")) {
++        if (true) {
+             gnomeSettings->cursorSizeChanged();
+         }
+     } else if (changedProperty == QStringLiteral("cursor-theme")) {
+-        if (QGuiApplication::platformName() != QStringLiteral("xcb")) {
++        if (true) {
+             gnomeSettings->cursorThemeChanged();
+         }
+     // Org.gnome.wm.preferences
+@@ -393,13 +393,23 @@ void GnomeSettingsPrivate::cursorBlinkTimeChanged()
+ void GnomeSettingsPrivate::cursorSizeChanged()
+ {
+     int cursorSize = getSettingsProperty<int>(QStringLiteral("cursor-size"));
+-    qputenv("XCURSOR_SIZE", QString::number(cursorSize).toUtf8());
++    if (QGuiApplication::platformName() != QStringLiteral("xcb")) {
++        qputenv("XCURSOR_SIZE", QString::number(cursorSize).toUtf8());
++    }
++#if QT_VERSION >= QT_VERSION_CHECK(6, 5, 0)
++    m_hints[QPlatformTheme::MouseCursorSize] = QSize(cursorSize, cursorSize);
++#endif
+ }
+ 
+ void GnomeSettingsPrivate::cursorThemeChanged()
+ {
+     const QString cursorTheme = getSettingsProperty<QString>(QStringLiteral("cursor-theme"));
+-    qputenv("XCURSOR_THEME", cursorTheme.toUtf8());
++    if (QGuiApplication::platformName() != QStringLiteral("xcb")) {
++        qputenv("XCURSOR_THEME", cursorTheme.toUtf8());
++    }
++#if QT_VERSION >= QT_VERSION_CHECK(6, 5, 0)
++    m_hints[QPlatformTheme::MouseCursorTheme] = cursorTheme;
++#endif
+ }
+ 
+ void GnomeSettingsPrivate::fontChanged()