From 1ed364a00067c76b5b0e581d82ab9597f28bbe62 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Sun, 3 Dec 2017 19:03:48 +0100 Subject: [PATCH] widgetbowl: Add some more widget types --- demos/gtk-demo/widgetbowl.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/demos/gtk-demo/widgetbowl.c b/demos/gtk-demo/widgetbowl.c index 9b137095d4..33a929f391 100644 --- a/demos/gtk-demo/widgetbowl.c +++ b/demos/gtk-demo/widgetbowl.c @@ -36,6 +36,24 @@ create_level_bar (void) return w; } +static GtkWidget * +create_spinner (void) +{ + GtkWidget *w = gtk_spinner_new (); + + gtk_spinner_start (GTK_SPINNER (w)); + + return w; +} + +static GtkWidget * +create_spinbutton (void) +{ + GtkWidget *w = gtk_spin_button_new_with_range (0, 10, 1); + + return w; +} + static GtkWidget * create_label (void) { @@ -55,6 +73,8 @@ static const struct { { "Fontbutton", create_font_button }, { "Levelbar" , create_level_bar }, { "Label" , create_label }, + { "Spinner" , create_spinner }, + { "Spinbutton", create_spinbutton }, }; static int selected_widget_type = -1;