gtk-color-scheme in gtk_rc_parse_string not like the current theme leads to infinite loops



Here is an example that trigger the inifinite loop. If  one restore 
tooltip_bg_color:#F5F5B5 instead of F5F5B2 the program does not loop
indefinitely.

This may be related to no support for multiple gtk-color-scheme as told
in http://live.gnome.org/GnomeArt/Tutorials/GtkThemes/SymbolicColors/


What should I do for the program that include gtk-color-scheme in its
string to be parsed (xmj  http://mahjong.julianbradfield.org/ 1.10b1) .
Tell the author to remove this line or attempt to find what s wrong and
a workaround for current behaviour of gtk+ ?

Best regards
Alban

------------------------------------------------------

#include <gtk/gtk.h>

int
main (int argc, char *argv[])
{

char *gtk_rc_data =
"" "\n"
"gtk-color-scheme =
\"base_color:#ffffff\\nfg_color:#000000\\ntooltip_fg_color:#000000\\nselected_bg_color:#86ABD9\\nselected_fg_color:#ffffff\\ntext_color:#1A1A1A\\nbg_color:#EDECEB\\ntooltip_bg_color:#F5F5B2\""
"\n"
;

  gchar *rc_files = { NULL };
  gtk_rc_set_default_files(&rc_files);
  gtk_init (&argc, &argv);
  gtk_rc_parse_string(gtk_rc_data);


}

---------------------------------------------------------------------------------------------------------
gcc $(pkg-config --cflags  --libs gtk+-2.0) gtk_color_scheme_parse.c



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