SHA256
1
0
forked from pool/gucharmap
gucharmap/gucharmap-no-force-light-theme.patch

37 lines
1.3 KiB
Diff
Raw Normal View History

From a5b046870b62393bb10ed649072c00a0c88d5e1e Mon Sep 17 00:00:00 2001
From: Christian Persch <chpe@gnome.org>
Date: Tue, 15 Nov 2016 21:10:00 +0100
Subject: charmap: Conditionalise forcing the light theme on gtk < 3.22
Apparently this is fixed on gtk+ 3.22, so only force the variant
to 'light' on < 3.22.
https://bugzilla.gnome.org/show_bug.cgi?id=741939#c28
---
gucharmap/main.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/gucharmap/main.c b/gucharmap/main.c
index 877398b..a07403f 100644
--- a/gucharmap/main.c
+++ b/gucharmap/main.c
@@ -275,8 +275,12 @@ main (int argc, char **argv)
g_application_register (G_APPLICATION (application), NULL, NULL);
- /* Gucharmap doesn't work right with the dark theme, see #741939 */
- g_object_set (gtk_settings_get_default (), "gtk-application-prefer-dark-theme", FALSE, NULL);
+ /* Gucharmap doesn't work right with the dark theme, see #741939.
+ * Apparently this got fixed in gtk+ some time before 3.22, so
+ * only work around this on older versions.
+ */
+ if (gtk_check_version (3, 22, 0) != NULL /* < 3.22.0 */)
+ g_object_set (gtk_settings_get_default (), "gtk-application-prefer-dark-theme", FALSE, NULL);
window = gucharmap_window_new (application);
--
cgit v0.12