Index: gtk/gtkrange.c
===================================================================
RCS file: /cvs/gnome/gtk+/gtk/gtkrange.c,v
retrieving revision 1.126
diff -u -p -r1.126 gtkrange.c
--- gtk/gtkrange.c	18 May 2006 11:39:42 -0000	1.126
+++ gtk/gtkrange.c	6 Jun 2006 16:14:48 -0000
@@ -1360,19 +1360,22 @@ coord_to_value (GtkRange *range,
 {
   gdouble frac;
   gdouble value;
+  gint stepper_spacing;
+  
+  gtk_range_get_props (range, NULL, NULL, NULL, &stepper_spacing, NULL, NULL);
   
   if (range->orientation == GTK_ORIENTATION_VERTICAL)
     if (range->layout->trough.height == range->layout->slider.height)
       frac = 1.0;
     else 
-      frac = ((coord - range->layout->trough.y) /
-	      (gdouble) (range->layout->trough.height - range->layout->slider.height));
+      frac = ((coord - range->layout->trough.y - stepper_spacing) /
+	      (gdouble) (range->layout->trough.height - range->layout->slider.height - 2 * stepper_spacing));
   else
     if (range->layout->trough.width == range->layout->slider.width)
       frac = 1.0;
     else
-      frac = ((coord - range->layout->trough.x) /
-	      (gdouble) (range->layout->trough.width - range->layout->slider.width));
+      frac = ((coord - range->layout->trough.x - stepper_spacing) /
+	      (gdouble) (range->layout->trough.width - range->layout->slider.width - 2 * stepper_spacing));
 
   if (should_invert (range))
     frac = 1.0 - frac;
