From 84b2d43d958a9f4e6a952d7e533d365eef6e5aa8 Mon Sep 17 00:00:00 2001 From: Owen Taylor Date: Fri, 11 Dec 1998 10:52:30 +0000 Subject: [PATCH] Add in a "style_set" handler so that the background of the clist changes Fri Dec 11 05:49:30 1998 Owen Taylor * gtk/gtkclist.c (gtk_clist_style_set): Add in a "style_set" handler so that the background of the clist changes with the theme. --- ChangeLog | 6 ++++++ ChangeLog.pre-2-0 | 6 ++++++ ChangeLog.pre-2-10 | 6 ++++++ ChangeLog.pre-2-2 | 6 ++++++ ChangeLog.pre-2-4 | 6 ++++++ ChangeLog.pre-2-6 | 6 ++++++ ChangeLog.pre-2-8 | 6 ++++++ gtk/gtkclist.c | 7 +++++++ 8 files changed, 49 insertions(+) diff --git a/ChangeLog b/ChangeLog index 3805d5158a..0ddd8bafe4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Fri Dec 11 05:49:30 1998 Owen Taylor + + * gtk/gtkclist.c (gtk_clist_style_set): Add in a "style_set" + handler so that the background of the clist changes + with the theme. + Thu Dec 10 22:02:49 CST 1998 Shawn T. Amundson * Released GTK+ 1.1.7 diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index 3805d5158a..0ddd8bafe4 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,9 @@ +Fri Dec 11 05:49:30 1998 Owen Taylor + + * gtk/gtkclist.c (gtk_clist_style_set): Add in a "style_set" + handler so that the background of the clist changes + with the theme. + Thu Dec 10 22:02:49 CST 1998 Shawn T. Amundson * Released GTK+ 1.1.7 diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 3805d5158a..0ddd8bafe4 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,9 @@ +Fri Dec 11 05:49:30 1998 Owen Taylor + + * gtk/gtkclist.c (gtk_clist_style_set): Add in a "style_set" + handler so that the background of the clist changes + with the theme. + Thu Dec 10 22:02:49 CST 1998 Shawn T. Amundson * Released GTK+ 1.1.7 diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 3805d5158a..0ddd8bafe4 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,9 @@ +Fri Dec 11 05:49:30 1998 Owen Taylor + + * gtk/gtkclist.c (gtk_clist_style_set): Add in a "style_set" + handler so that the background of the clist changes + with the theme. + Thu Dec 10 22:02:49 CST 1998 Shawn T. Amundson * Released GTK+ 1.1.7 diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 3805d5158a..0ddd8bafe4 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,9 @@ +Fri Dec 11 05:49:30 1998 Owen Taylor + + * gtk/gtkclist.c (gtk_clist_style_set): Add in a "style_set" + handler so that the background of the clist changes + with the theme. + Thu Dec 10 22:02:49 CST 1998 Shawn T. Amundson * Released GTK+ 1.1.7 diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 3805d5158a..0ddd8bafe4 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,9 @@ +Fri Dec 11 05:49:30 1998 Owen Taylor + + * gtk/gtkclist.c (gtk_clist_style_set): Add in a "style_set" + handler so that the background of the clist changes + with the theme. + Thu Dec 10 22:02:49 CST 1998 Shawn T. Amundson * Released GTK+ 1.1.7 diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 3805d5158a..0ddd8bafe4 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,9 @@ +Fri Dec 11 05:49:30 1998 Owen Taylor + + * gtk/gtkclist.c (gtk_clist_style_set): Add in a "style_set" + handler so that the background of the clist changes + with the theme. + Thu Dec 10 22:02:49 CST 1998 Shawn T. Amundson * Released GTK+ 1.1.7 diff --git a/gtk/gtkclist.c b/gtk/gtkclist.c index fc5fdc2413..5d54fd078e 100644 --- a/gtk/gtkclist.c +++ b/gtk/gtkclist.c @@ -4689,6 +4689,13 @@ gtk_clist_style_set (GtkWidget *widget, clist = GTK_CLIST (widget); + if (GTK_WIDGET_REALIZED (widget)) + { + gtk_style_set_background (widget->style, widget->window, widget->state); + gtk_style_set_background (widget->style, clist->title_window, GTK_STATE_SELECTED); + gdk_window_set_background (clist->clist_window, &widget->style->bg[GTK_STATE_PRELIGHT]); + } + /* Fill in data after widget has correct style */ /* text properties */