From 272dafa2317a9ac6602cf595b7571ed5bb96decc Mon Sep 17 00:00:00 2001 From: Cody Russell Date: Thu, 15 Jul 2010 11:21:39 -0500 Subject: Force IdoRange to style itself by name rather than by class. Otherwise they all have the style used by the last one created. --- src/idorange.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/idorange.c b/src/idorange.c index 315d7fd..ba5c2c8 100644 --- a/src/idorange.c +++ b/src/idorange.c @@ -141,6 +141,9 @@ ido_range_constructed (GObject *object) "range-style", &style, NULL); + g_snprintf (buf, sizeof (buf), "idorange-%p", range); + gtk_widget_set_name (GTK_WIDGET (range), buf); + if (style == IDO_RANGE_STYLE_SMALL) { gint width, height; @@ -154,8 +157,8 @@ ido_range_constructed (GObject *object) "style \"ido-range\" {\n" " GtkRange::slider-width = %d\n" " GtkScale::slider-length = %d\n" - "} class \"IdoRange\" style \"ido-range\"\n", - width, height); + "} widget \"*.idorange-%p\" style \"ido-range\"\n", + width, height, range); gtk_rc_parse_string (buf); } -- cgit v1.2.3