Index: trunk/BNC/qwt/qwt_abstract_slider.cpp
===================================================================
--- trunk/BNC/qwt/qwt_abstract_slider.cpp	(revision 8127)
+++ trunk/BNC/qwt/qwt_abstract_slider.cpp	(revision 9383)
@@ -18,5 +18,5 @@
 #endif
 
-static double qwtAlignToScaleDiv( 
+static double qwtAlignToScaleDiv(
     const QwtAbstractSlider *slider, double value )
 {
@@ -28,5 +28,5 @@
         return sd.lowerBound();
 
-    if ( tValue == slider->transform( sd.lowerBound() ) )
+    if ( tValue == slider->transform( sd.upperBound() ) )
         return sd.upperBound();
 
@@ -107,5 +107,5 @@
 }
 
-/*! 
+/*!
   Set the value to be valid/invalid
 
@@ -122,6 +122,6 @@
 
         Q_EMIT valueChanged( d_data->value );
-    }   
-}   
+    }
+}
 
 //! \return True, when the value is invalid
@@ -129,5 +129,5 @@
 {
     return d_data->isValid;
-}   
+}
 
 /*!
@@ -168,7 +168,7 @@
   \brief Enables or disables tracking.
 
-  If tracking is enabled, the slider emits the valueChanged() 
-  signal while the movable part of the slider is being dragged. 
-  If tracking is disabled, the slider emits the valueChanged() signal 
+  If tracking is enabled, the slider emits the valueChanged()
+  signal while the movable part of the slider is being dragged.
+  If tracking is disabled, the slider emits the valueChanged() signal
   only when the user releases the slider.
 
@@ -288,5 +288,5 @@
    Wheel Event handler
 
-   In/decreases the value by s number of steps. The direction 
+   In/decreases the value by s number of steps. The direction
    depends on the invertedControls() property.
 
@@ -459,5 +459,5 @@
 
   The range of the slider is divided into a number of steps from
-  which the value increments according to user inputs depend. 
+  which the value increments according to user inputs depend.
 
   The default setting is 100.
@@ -485,5 +485,5 @@
 
   The range of the slider is divided into a number of steps from
-  which the value increments according to user inputs depend. 
+  which the value increments according to user inputs depend.
 
   \param stepCount Number of steps
@@ -495,5 +495,5 @@
 {
     d_data->singleSteps = stepCount;
-}   
+}
 
 /*!
@@ -504,11 +504,11 @@
 {
     return d_data->singleSteps;
-}   
-
-/*! 
+}
+
+/*!
   \brief Set the number of steps for a page increment
-    
+
   The range of the slider is divided into a number of steps from
-  which the value increments according to user inputs depend. 
+  which the value increments according to user inputs depend.
 
   \param stepCount Number of steps
@@ -541,11 +541,11 @@
 */
 void QwtAbstractSlider::setStepAlignment( bool on )
-{   
+{
     if ( on != d_data->stepAlignment )
     {
         d_data->stepAlignment = on;
     }
-}   
-    
+}
+
 /*!
   \return True, when step alignment is enabled
@@ -586,6 +586,6 @@
 
 /*!
-  If wrapping is true stepping up from upperBound() value will 
-  take you to the minimum() value and vice versa. 
+  If wrapping is true stepping up from upperBound() value will
+  take you to the minimum() value and vice versa.
 
   \param on En/Disable wrapping
@@ -595,10 +595,10 @@
 {
     d_data->wrapping = on;
-}   
+}
 
 /*!
   \return True, when wrapping is set
   \sa setWrapping()
- */ 
+ */
 bool QwtAbstractSlider::wrapping() const
 {
@@ -609,6 +609,6 @@
   Invert wheel and key events
 
-  Usually scrolling the mouse wheel "up" and using keys like page 
-  up will increase the slider's value towards its maximum. 
+  Usually scrolling the mouse wheel "up" and using keys like page
+  up will increase the slider's value towards its maximum.
   When invertedControls() is enabled the value is scrolled
   towards its minimum.
@@ -645,5 +645,5 @@
 void QwtAbstractSlider::incrementValue( int stepCount )
 {
-    const double value = incrementedValue( 
+    const double value = incrementedValue(
         d_data->value, stepCount );
 
@@ -656,12 +656,12 @@
 
 /*!
-  Increment a value 
-
-  \param value Value 
+  Increment a value
+
+  \param value Value
   \param stepCount Number of steps
 
   \return Incremented value
  */
-double QwtAbstractSlider::incrementedValue( 
+double QwtAbstractSlider::incrementedValue(
     double value, int stepCount ) const
 {
@@ -684,5 +684,5 @@
         // we need equidant steps according to
         // paint device coordinates
-        const double range = transformation->transform( maximum() ) 
+        const double range = transformation->transform( maximum() )
             - transformation->transform( minimum() );
 
@@ -691,5 +691,5 @@
         double v = transformation->transform( value );
 
-        v = qRound( v / stepSize ) * stepSize; 
+        v = qRound( v / stepSize ) * stepSize;
         v += stepCount * range / d_data->totalSteps;
 
@@ -757,5 +757,5 @@
         if ( stepSize > 0.0 )
         {
-            value = lowerBound() + 
+            value = lowerBound() +
                 qRound( ( value - lowerBound() ) / stepSize ) * stepSize;
         }
