]> spindle.queued.net Git - midori/commitdiff
Make spin buttons smaller
authorChristian Dywan <christian@twotoasts.de>
Wed, 10 Sep 2008 23:49:50 +0000 (01:49 +0200)
committerChristian Dywan <christian@twotoasts.de>
Wed, 10 Sep 2008 23:49:50 +0000 (01:49 +0200)
katze/katze-utils.c

index adb300d91e7aca20d750845fcc15f09f336759f3..061e7c3d396f696b900feccef4228a9ffcef2487 100644 (file)
@@ -249,6 +249,8 @@ katze_property_proxy (gpointer     object,
         widget = gtk_spin_button_new_with_range (
             G_PARAM_SPEC_FLOAT (pspec)->minimum,
             G_PARAM_SPEC_FLOAT (pspec)->maximum, 1);
+        /* Keep it narrow, 5 + 2 digits are usually fine */
+        gtk_entry_set_width_chars (GTK_ENTRY (widget), 5 + 2);
         gtk_spin_button_set_digits (GTK_SPIN_BUTTON (widget), 2);
         gfloat value;
         g_object_get (object, property, &value, NULL);
@@ -261,6 +263,8 @@ katze_property_proxy (gpointer     object,
         widget = gtk_spin_button_new_with_range (
             G_PARAM_SPEC_INT (pspec)->minimum,
             G_PARAM_SPEC_INT (pspec)->maximum, 1);
+        /* Keep it narrow, 5 digits are usually fine */
+        gtk_entry_set_width_chars (GTK_ENTRY (widget), 5);
         gint value;
         g_object_get (object, property, &value, NULL);
         gtk_spin_button_set_value (GTK_SPIN_BUTTON (widget), value);