Index: tests/testicontheme.c
===================================================================
RCS file: /cvs/gnome/gtk+/tests/testicontheme.c,v
retrieving revision 1.3
diff -u -p -r1.3 testicontheme.c
--- tests/testicontheme.c	19 Oct 2004 04:30:35 -0000	1.3
+++ tests/testicontheme.c	19 Oct 2004 05:15:00 -0000
@@ -1,5 +1,4 @@
-#include <config.h>
-#include <gtk/gtkicontheme.h>
+#include <gtk/gtk.h>
 #include <stdlib.h>
 #include <string.h>
 #include <locale.h>
@@ -28,8 +27,7 @@ main (int argc, char *argv[])
   int size = 48;
   int i;
   
-  g_type_init ();
-  setlocale (LC_ALL, "");
+  gtk_init (&argc, &argv);
 
   if (argc < 3)
     {
@@ -43,7 +41,31 @@ main (int argc, char *argv[])
   
   gtk_icon_theme_set_custom_theme (icon_theme, themename);
 
-  if (strcmp (argv[1], "list") == 0)
+  if (strcmp (argv[1], "display") == 0)
+    {
+      GtkWidget *window, *image;
+      GtkIconSize size;
+
+      if (argc < 4)
+	{
+	  g_object_unref (icon_theme);
+	  usage ();
+	  return 1;
+	}
+      
+      if (argc >= 5)
+	size = atoi (argv[4]);
+      else 
+	size = GTK_ICON_SIZE_BUTTON;
+      
+      window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
+      image = gtk_image_new_from_icon_name (argv[3], size); 
+      gtk_container_add (GTK_CONTAINER (window), image);
+      gtk_widget_show_all (window);
+      
+      gtk_main ();
+    }
+  else if (strcmp (argv[1], "list") == 0)
     {
       if (argc >= 4)
 	context = argv[3];
