Re: RE: Changing color/style on a scrollbar inaGtkScrolledWindow
| From: | Madeleine D. | Date: | Fri, 30 Jul 2004 21:16:54 +0000 |
| Subject: | Re: RE: Changing color/style on a scrollbar inaGtkScrolledWindow | ||
| Groups: | php.gtk.general | ||
| Request: | Send a blank email to php-gtk-general+get-4902@lists.php.net to get a copy of this message | ||
Dave -
I'm not sure you can do what you're attempting.
It looks to me as though style has to be applied to a widget, and
vadjustment is described as an object in the Gtk docs. If I'm right, it
makes sense that it wouldn't accept a set_style.
I can give you a quick example of the kind of style setting that has worked
for us - a clist row highlight. It might lead you to what you need for the
Scroll Window:
function PMformatRowStyle($clist,$count) {
$color1 = &new GdkColor('#000000');
$color2 = &new GdkColor('#ffe4c4');
$style = &new GtkStyle;
$style->fg[GTK_STATE_NORMAL] = $color1;
$style->base[GTK_STATE_NORMAL] = $color2;
$style->font =
gdk::font_load("-adobe-tahoma-medium-r-normal--*-120-*-*-*-*-*-*,*");
$clist->set_row_style($count,$style);
} // end format row function
My experience with style has been fairly brutal - it never really does what
we think it should - so maybe I'm off base here, in which case one of the
real experts can step in.
Madeleine D.