summaryrefslogtreecommitdiff
path: root/test/test-eel-background.c
diff options
context:
space:
mode:
authorPerberos <[email protected]>2011-12-01 22:24:23 -0300
committerPerberos <[email protected]>2011-12-01 22:24:23 -0300
commit0e004c696b0e68b2cff37a4c3315b022a35eaf43 (patch)
tree43261e815529cb9518ed7be37af13b846af8b26b /test/test-eel-background.c
downloadcaja-0e004c696b0e68b2cff37a4c3315b022a35eaf43.tar.bz2
caja-0e004c696b0e68b2cff37a4c3315b022a35eaf43.tar.xz
moving from https://github.com/perberos/mate-desktop-environment
Diffstat (limited to 'test/test-eel-background.c')
-rw-r--r--test/test-eel-background.c38
1 files changed, 38 insertions, 0 deletions
diff --git a/test/test-eel-background.c b/test/test-eel-background.c
new file mode 100644
index 00000000..6f5bba23
--- /dev/null
+++ b/test/test-eel-background.c
@@ -0,0 +1,38 @@
+/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
+
+#include <eel/eel-background.h>
+#include <gtk/gtk.h>
+
+#define PATTERNS_DIR "/mate-source/eel/data/patterns"
+
+int
+main (int argc, char *argv[])
+{
+ GtkWidget *window;
+ EelBackground *background;
+ char *image_uri;
+
+ gtk_init (&argc, &argv);
+
+ window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
+ g_signal_connect (window, "destroy",
+ gtk_main_quit, NULL);
+
+ background = eel_get_widget_background (window);
+
+ eel_background_set_color (background,
+ "red-blue:h");
+
+ image_uri = g_filename_to_uri (PATTERNS_DIR "/50s.png", NULL, NULL);
+
+#if 1
+ eel_background_set_image_uri (background, image_uri);
+#endif
+ g_free (image_uri);
+
+
+ gtk_widget_show_all (window);
+ gtk_main ();
+
+ return 0;
+}