[gtk+] Add GtkSpinner to the widget gallery



commit 9112194791bb451a0ab952d2bd1d2158c6a6d664
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed Oct 14 13:52:52 2009 -0400

    Add GtkSpinner to the widget gallery
    
    Yes, our documentation setup is wierd and wonderful.

 docs/reference/gtk/Makefile.am        |    1 +
 docs/reference/gtk/images/spinner.png |  Bin 0 -> 3531 bytes
 docs/reference/gtk/visual_index.xml   |    3 +++
 docs/tools/widgets.c                  |   21 +++++++++++++++++++++
 4 files changed, 25 insertions(+), 0 deletions(-)
---
diff --git a/docs/reference/gtk/Makefile.am b/docs/reference/gtk/Makefile.am
index 6a0b30a..f37ae1c 100644
--- a/docs/reference/gtk/Makefile.am
+++ b/docs/reference/gtk/Makefile.am
@@ -335,6 +335,7 @@ HTML_IMAGES = \
 	$(srcdir)/images/scrolledwindow.png				\
 	$(srcdir)/images/separator.png					\
 	$(srcdir)/images/spinbutton.png					\
+	$(srcdir)/images/spinner.png					\
 	$(srcdir)/images/statusbar.png					\
 	$(srcdir)/images/toggle-button.png				\
 	$(srcdir)/images/toolbar.png					\
diff --git a/docs/reference/gtk/images/spinner.png b/docs/reference/gtk/images/spinner.png
new file mode 100644
index 0000000..895a888
Binary files /dev/null and b/docs/reference/gtk/images/spinner.png differ
diff --git a/docs/reference/gtk/visual_index.xml b/docs/reference/gtk/visual_index.xml
index db86512..faae348 100644
--- a/docs/reference/gtk/visual_index.xml
+++ b/docs/reference/gtk/visual_index.xml
@@ -39,6 +39,9 @@
   <link linkend="GtkImage">
     <inlinegraphic fileref="image.png" format="PNG"></inlinegraphic>
   </link>
+  <link linkend="GtkSpinner">
+    <inlinegraphic fileref="spinner.png" format="PNG"></inlinegraphic>
+  </link>
   <link linkend="GtkLabel">
     <inlinegraphic fileref="label.png" format="PNG"></inlinegraphic>
   </link>
diff --git a/docs/tools/widgets.c b/docs/tools/widgets.c
index 3f512fb..02dd031 100644
--- a/docs/tools/widgets.c
+++ b/docs/tools/widgets.c
@@ -940,6 +940,26 @@ create_image (void)
 }
 
 static WidgetInfo *
+create_spinner (void)
+{
+  GtkWidget *widget;
+  GtkWidget *align, *vbox;
+
+  widget = gtk_spinner_new ();
+  gtk_widget_set_size_request (widget, 24, 24);
+
+  vbox = gtk_vbox_new (FALSE, 3);
+  align = gtk_alignment_new (0.5, 0.5, 0.0, 0.0);
+  gtk_container_add (GTK_CONTAINER (align), widget);
+  gtk_box_pack_start (GTK_BOX (vbox), align, FALSE, FALSE, 0);
+  gtk_box_pack_start (GTK_BOX (vbox),
+		      gtk_label_new ("Spinner"),
+		      FALSE, FALSE, 0);
+
+  return new_widget_info ("spinner", vbox, SMALL);
+}
+
+static WidgetInfo *
 create_volume_button (void)
 {
   GtkWidget *button, *widget;
@@ -985,6 +1005,7 @@ get_all_widgets (void)
 {
   GList *retval = NULL;
 
+  retval = g_list_prepend (retval, create_spinner ());
   retval = g_list_prepend (retval, create_about_dialog ());
   retval = g_list_prepend (retval, create_accel_label ());
   retval = g_list_prepend (retval, create_button ());



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