2 * Copyright (C) 2004 Morten Welinder
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Library General Public License for more details.
14 * You should have received a copy of the GNU Library General Public
15 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
22 main (int argc, char **argv)
24 GtkWidget *window, *mainbox;
27 gtk_init (&argc, &argv);
29 window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
30 g_signal_connect (window, "delete_event", gtk_main_quit, NULL);
32 mainbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 2);
33 gtk_container_add (GTK_CONTAINER (window), mainbox);
35 for (max = 9; max <= 999999999; max = max * 10 + 9) {
36 GtkAdjustment *adj = gtk_adjustment_new (max,
42 GtkWidget *spin = gtk_spin_button_new (adj, 1.0, 0);
43 GtkWidget *hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 2);
45 gtk_box_pack_start (GTK_BOX (hbox),
51 gtk_container_add (GTK_CONTAINER (mainbox), hbox);
55 gtk_widget_show_all (window);