summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <matthiasc@src.gnome.org>2001-10-18 20:15:53 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2001-10-18 20:15:53 +0000
commitb75d0e8f3866e3e9e7ab951c74115a55c7f4d90d (patch)
tree5f7822d64d7e1991deec258a389b28ef7568c634
parentb7b2a5ca647ad05df2bbbffa982ea4e206428960 (diff)
downloadgtk+-b75d0e8f3866e3e9e7ab951c74115a55c7f4d90d.tar.gz
Don't restrict the width of the spinbutton entry field to 10 digits.
* gtk/gtkspinbutton.c (gtk_spin_button_size_request): Don't restrict the width of the spinbutton entry field to 10 digits. (#58681)
-rw-r--r--ChangeLog6
-rw-r--r--ChangeLog.pre-2-06
-rw-r--r--ChangeLog.pre-2-106
-rw-r--r--ChangeLog.pre-2-26
-rw-r--r--ChangeLog.pre-2-46
-rw-r--r--ChangeLog.pre-2-66
-rw-r--r--ChangeLog.pre-2-86
-rw-r--r--gtk/gtkspinbutton.c7
8 files changed, 47 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 82a1ed5b59..fe7ce65187 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2001-10-18 Matthias Clasen <matthiasc@poet.de>
+
+ * gtk/gtkspinbutton.c (gtk_spin_button_size_request):
+ Don't restrict the width of the spinbutton entry field
+ to 10 digits. (#58681)
+
Thu Oct 18 14:58:14 2001 Jonathan Blandford <jrb@redhat.com>
* tests/testtreeflow.c: new test program for the tree.
diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0
index 82a1ed5b59..fe7ce65187 100644
--- a/ChangeLog.pre-2-0
+++ b/ChangeLog.pre-2-0
@@ -1,3 +1,9 @@
+2001-10-18 Matthias Clasen <matthiasc@poet.de>
+
+ * gtk/gtkspinbutton.c (gtk_spin_button_size_request):
+ Don't restrict the width of the spinbutton entry field
+ to 10 digits. (#58681)
+
Thu Oct 18 14:58:14 2001 Jonathan Blandford <jrb@redhat.com>
* tests/testtreeflow.c: new test program for the tree.
diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10
index 82a1ed5b59..fe7ce65187 100644
--- a/ChangeLog.pre-2-10
+++ b/ChangeLog.pre-2-10
@@ -1,3 +1,9 @@
+2001-10-18 Matthias Clasen <matthiasc@poet.de>
+
+ * gtk/gtkspinbutton.c (gtk_spin_button_size_request):
+ Don't restrict the width of the spinbutton entry field
+ to 10 digits. (#58681)
+
Thu Oct 18 14:58:14 2001 Jonathan Blandford <jrb@redhat.com>
* tests/testtreeflow.c: new test program for the tree.
diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2
index 82a1ed5b59..fe7ce65187 100644
--- a/ChangeLog.pre-2-2
+++ b/ChangeLog.pre-2-2
@@ -1,3 +1,9 @@
+2001-10-18 Matthias Clasen <matthiasc@poet.de>
+
+ * gtk/gtkspinbutton.c (gtk_spin_button_size_request):
+ Don't restrict the width of the spinbutton entry field
+ to 10 digits. (#58681)
+
Thu Oct 18 14:58:14 2001 Jonathan Blandford <jrb@redhat.com>
* tests/testtreeflow.c: new test program for the tree.
diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4
index 82a1ed5b59..fe7ce65187 100644
--- a/ChangeLog.pre-2-4
+++ b/ChangeLog.pre-2-4
@@ -1,3 +1,9 @@
+2001-10-18 Matthias Clasen <matthiasc@poet.de>
+
+ * gtk/gtkspinbutton.c (gtk_spin_button_size_request):
+ Don't restrict the width of the spinbutton entry field
+ to 10 digits. (#58681)
+
Thu Oct 18 14:58:14 2001 Jonathan Blandford <jrb@redhat.com>
* tests/testtreeflow.c: new test program for the tree.
diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6
index 82a1ed5b59..fe7ce65187 100644
--- a/ChangeLog.pre-2-6
+++ b/ChangeLog.pre-2-6
@@ -1,3 +1,9 @@
+2001-10-18 Matthias Clasen <matthiasc@poet.de>
+
+ * gtk/gtkspinbutton.c (gtk_spin_button_size_request):
+ Don't restrict the width of the spinbutton entry field
+ to 10 digits. (#58681)
+
Thu Oct 18 14:58:14 2001 Jonathan Blandford <jrb@redhat.com>
* tests/testtreeflow.c: new test program for the tree.
diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8
index 82a1ed5b59..fe7ce65187 100644
--- a/ChangeLog.pre-2-8
+++ b/ChangeLog.pre-2-8
@@ -1,3 +1,9 @@
+2001-10-18 Matthias Clasen <matthiasc@poet.de>
+
+ * gtk/gtkspinbutton.c (gtk_spin_button_size_request):
+ Don't restrict the width of the spinbutton entry field
+ to 10 digits. (#58681)
+
Thu Oct 18 14:58:14 2001 Jonathan Blandford <jrb@redhat.com>
* tests/testtreeflow.c: new test program for the tree.
diff --git a/gtk/gtkspinbutton.c b/gtk/gtkspinbutton.c
index a767d88994..7be68ce10f 100644
--- a/gtk/gtkspinbutton.c
+++ b/gtk/gtkspinbutton.c
@@ -583,6 +583,7 @@ gtk_spin_button_size_request (GtkWidget *widget,
gint width;
gint w;
gint string_len;
+ gint max_string_len;
gint digit_width;
context = gtk_widget_get_pango_context (widget);
@@ -598,14 +599,16 @@ gtk_spin_button_size_request (GtkWidget *widget,
/* Get max of MIN_SPIN_BUTTON_WIDTH, size of upper, size of lower */
width = MIN_SPIN_BUTTON_WIDTH;
+ max_string_len = MAX (10, compute_double_length (1e9 * spin_button->adjustment->step_increment,
+ spin_button->digits));
string_len = compute_double_length (spin_button->adjustment->upper,
spin_button->digits);
- w = MIN (string_len, 10) * digit_width;
+ w = MIN (string_len, max_string_len) * digit_width;
width = MAX (width, w);
string_len = compute_double_length (spin_button->adjustment->lower,
spin_button->digits);
- w = MIN (string_len, 10) * digit_width;
+ w = MIN (string_len, max_string_len) * digit_width;
width = MAX (width, w);
requisition->width = width + ARROW_SIZE + 2 * widget->style->xthickness;