[cairo-commit] goocanvas/demo demo.c,1.23,1.24 mv-demo.c,1.8,1.9
Damon Chaplin
commit at pdx.freedesktop.org
Tue Mar 27 04:41:05 PDT 2007
Committed by: damon
Update of /cvs/cairo/goocanvas/demo
In directory kemper:/tmp/cvs-serv6973/demo
Modified Files:
demo.c mv-demo.c
Log Message:
2007-03-27 Damon Chaplin <damon at gnome.org>
* src/goocanvas.c: added "background-color" and "background-color-rgb"
properties to set the background color of the canvas, based on a patch
from Gian Mario Tagliaretti.
* demo/demo.c (create_canvas_primitives):
* demo/mv-demo.c (create_canvas_primitives): use above properties.
Index: demo.c
===================================================================
RCS file: /cvs/cairo/goocanvas/demo/demo.c,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -d -r1.23 -r1.24
--- demo.c 8 Mar 2007 13:58:45 -0000 1.23
+++ demo.c 27 Mar 2007 11:40:56 -0000 1.24
@@ -388,7 +388,6 @@
GtkWidget *scrolled_win, *canvas;
GtkAdjustment *adj;
GSList *group = NULL;
- GdkColor bg_color = { 0, 50000, 50000, 65535 };
vbox = gtk_vbox_new (FALSE, 4);
gtk_container_set_border_width (GTK_CONTAINER (vbox), 4);
@@ -405,7 +404,9 @@
/* Create the canvas */
canvas = goo_canvas_new ();
- gtk_widget_modify_base (canvas, GTK_STATE_NORMAL, &bg_color);
+ g_object_set (G_OBJECT (canvas),
+ "background-color-rgb", 0xC3C3FF,
+ NULL);
goo_canvas_set_bounds (GOO_CANVAS (canvas), 0, 0, 604, 454);
/* Zoom */
Index: mv-demo.c
===================================================================
RCS file: /cvs/cairo/goocanvas/demo/mv-demo.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- mv-demo.c 8 Mar 2007 13:58:45 -0000 1.8
+++ mv-demo.c 27 Mar 2007 11:40:56 -0000 1.9
@@ -355,7 +355,6 @@
GtkWidget *scrolled_win, *canvas;
GtkAdjustment *adj;
GSList *group = NULL;
- GdkColor bg_color = { 0, 50000, 50000, 65535 };
vbox = gtk_vbox_new (FALSE, 4);
gtk_container_set_border_width (GTK_CONTAINER (vbox), 4);
@@ -372,7 +371,9 @@
/* Create the canvas */
canvas = goo_canvas_new ();
- gtk_widget_modify_base (canvas, GTK_STATE_NORMAL, &bg_color);
+ g_object_set (G_OBJECT (canvas),
+ "background-color-rgb", 0xC3C3FF,
+ NULL);
goo_canvas_set_bounds (GOO_CANVAS (canvas), 0, 0, 604, 454);
g_signal_connect (canvas, "item_created",
More information about the cairo-commit
mailing list