button's bg color + some themes



With some themes when I set a button's background, it doesn't color the
whole background but rather just the border (themes such as lush). Other
themes appear correctly like xfce. Could someone explain this to me?

Here's a sniplet of example code ('widget' is an already visible
gtkbutton):

    GtkStyle *style;
    GdkColor c;
                                                                               
    style = gtk_widget_get_style (widget);
    c = style->bg[GTK_STATE_PRELIGHT];
    gtk_widget_modify_bg(widget, GTK_STATE_NORMAL, &c);

Matt





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]