summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorOwen Taylor <otaylor@redhat.com>2002-02-01 20:14:02 +0000
committerOwen Taylor <otaylor@src.gnome.org>2002-02-01 20:14:02 +0000
commitff95eb051b5297ce0747f61e420f4cdcb2805344 (patch)
tree3f27894a1da3c08e2b8522ffce88cf2cdc9d9d53 /tests
parentdcd6d764a72735889ce111f241841ed1ed13dceb (diff)
downloadgtk+-ff95eb051b5297ce0747f61e420f4cdcb2805344.tar.gz
Handle reparsing any strings if the theme changes. (#69465)
Fri Feb 1 14:50:36 2002 Owen Taylor <otaylor@redhat.com> * gtk/gtkrc.c (gtk_rc_parse_string): Handle reparsing any strings if the theme changes. (#69465) * tests/testgtk.c: Add a test for gtk_rc_parse_string().
Diffstat (limited to 'tests')
-rw-r--r--tests/testgtk.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/testgtk.c b/tests/testgtk.c
index 667eef0442..f60fd6fa58 100644
--- a/tests/testgtk.c
+++ b/tests/testgtk.c
@@ -11033,6 +11033,7 @@ create_main_window (void)
label = gtk_label_new (buffer);
gtk_box_pack_start (GTK_BOX (box1), label, FALSE, FALSE, 0);
+ gtk_widget_set_name (label, "testgtk-version-label");
scrolled_window = gtk_scrolled_window_new (NULL, NULL);
gtk_container_set_border_width (GTK_CONTAINER (scrolled_window), 10);
@@ -11263,7 +11264,17 @@ main (int argc, char *argv[])
"debug_msg",
1,
GTK_TYPE_STRING, "GtkWidgetClass <ctrl><release>9 test");
+
+ /* We use gtk_rc_parse_string() here so we can make sure it works across theme
+ * changes
+ */
+ gtk_rc_parse_string ("style \"testgtk-version-label\" { "
+ " fg[NORMAL] = \"#ff0000\"\n"
+ " font = \"Sans 18\"\n"
+ "}\n"
+ "widget \"*.testgtk-version-label\" style \"testgtk-version-label\"");
+
create_main_window ();
gtk_main ();