Changing the window background for all windows



Hi,

is there an easy way to change the background color for all
windows of the application? Buttons and other widgets may/should
keep their default light gray but I would like to change
the color of GtkWindow, Frames etc.

Maybe similar to changing the font? acano systec com kindly donated this
code to change the application font globally:

  GtkStyle *default_style, *new_style;
  gchar *fontname;

  fontname = ...
  default_style = gtk_widget_get_default_style ();
  new_style = gtk_style_copy (default_style);
  new_style->font = gdk_font_load (fontname);
  gtk_widget_push_style (new_style);

I figured maybe gtk_style_set_background or gtk_style_apply_default_background
can be used here but both need a GdkWindow reference (so they don't work globally)
and I am not sure about the meaning of their other params. They don't take a color 
so this does not help probably.

Regards,
WL




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