From a823047104911122519dcd38b05fd5c7046bfb54 Mon Sep 17 00:00:00 2001 From: deepend Date: Thu, 26 Feb 2026 08:26:03 -0700 Subject: [PATCH] Fixed imported GTK3 theme precedence so theme CSS can override ZoiteChat app-level CSS (including button background rules) by changing the provider priority from GTK_STYLE_PROVIDER_PRIORITY_APPLICATION to GTK_STYLE_PROVIDER_PRIORITY_USER. Updated the inline comment to document why user-level priority is needed for correct themed button styling behavior. --- src/fe-gtk/fe-gtk.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/fe-gtk/fe-gtk.c b/src/fe-gtk/fe-gtk.c index 3b4f048e..a845de10 100644 --- a/src/fe-gtk/fe-gtk.c +++ b/src/fe-gtk/fe-gtk.c @@ -736,9 +736,9 @@ fe_apply_gtk3_theme_with_reload (const char *theme_name, gboolean force_reload, gtk_style_context_add_provider_for_screen ( screen, GTK_STYLE_PROVIDER (gtk3_theme_provider), - /* Use application priority so imported GTK3 themes consistently - * override the desktop theme for ZoiteChat widgets. */ - GTK_STYLE_PROVIDER_PRIORITY_APPLICATION); + /* Use user priority so imported GTK3 themes can also override + * ZoiteChat's own application CSS (for example, button backgrounds). */ + GTK_STYLE_PROVIDER_PRIORITY_USER); gtk_style_context_reset_widgets (screen); }