Index: trunk/BNC/qwt/qwt_abstract_legend.h
===================================================================
--- trunk/BNC/qwt/qwt_abstract_legend.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_abstract_legend.h	(revision 9383)
@@ -22,5 +22,5 @@
 
   Legends, that need to be under control of the QwtPlot layout system
-  need to be derived from QwtAbstractLegend. 
+  need to be derived from QwtAbstractLegend.
 
   \note Other type of legends can be implemented by connecting to
@@ -45,9 +45,9 @@
       \param painter Painter
       \param rect Bounding rectangle
-      \param fillBackground When true, fill rect with the widget background 
+      \param fillBackground When true, fill rect with the widget background
 
       \sa renderLegend() is used by QwtPlotRenderer
     */
-    virtual void renderLegend( QPainter *painter, 
+    virtual void renderLegend( QPainter *painter,
         const QRectF &rect, bool fillBackground ) const = 0;
 
@@ -65,7 +65,7 @@
       \param data List of legend entry attributes for the  item
      */
-    virtual void updateLegend( const QVariant &itemInfo, 
+    virtual void updateLegend( const QVariant &itemInfo,
         const QList<QwtLegendData> &data ) = 0;
 };
 
-#endif 
+#endif
Index: trunk/BNC/qwt/qwt_abstract_scale.cpp
===================================================================
--- trunk/BNC/qwt/qwt_abstract_scale.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_abstract_scale.cpp	(revision 9383)
@@ -72,5 +72,5 @@
 
   \sa lowerBound(), setScale(), setUpperBound()
-  \note For inverted scales the lower bound 
+  \note For inverted scales the lower bound
         is greater than the upper bound
 */
@@ -95,5 +95,5 @@
 
   \sa upperBound(), setScale(), setLowerBound()
-  \note For inverted scales the lower bound 
+  \note For inverted scales the lower bound
         is greater than the upper bound
 */
@@ -115,7 +115,7 @@
   \brief Specify a scale.
 
-  Define a scale by an interval 
-
-  The ticks are calculated using scaleMaxMinor(), 
+  Define a scale by an interval
+
+  The ticks are calculated using scaleMaxMinor(),
   scaleMaxMajor() and scaleStepSize().
 
@@ -123,5 +123,5 @@
   \param upperBound upper limit of the scale interval
 
-  \note For inverted scales the lower bound 
+  \note For inverted scales the lower bound
         is greater than the upper bound
 */
@@ -136,5 +136,5 @@
   Define a scale by an interval
 
-  The ticks are calculated using scaleMaxMinor(), 
+  The ticks are calculated using scaleMaxMinor(),
   scaleMaxMajor() and scaleStepSize().
 
@@ -343,5 +343,5 @@
 
   The scale division might have been assigned explicitly
-  or calculated implicitly by rescale(). 
+  or calculated implicitly by rescale().
  */
 const QwtScaleDiv &QwtAbstractScale::scaleDiv() const
@@ -361,5 +361,5 @@
   Translate a scale value into a widget coordinate
 
-  \param value Scale value 
+  \param value Scale value
   \return Corresponding widget coordinate for value
   \sa scaleMap(), invTransform()
@@ -425,5 +425,5 @@
   \sa scaleChange()
 */
-void QwtAbstractScale::rescale( 
+void QwtAbstractScale::rescale(
     double lowerBound, double upperBound, double stepSize )
 {
Index: trunk/BNC/qwt/qwt_abstract_scale.h
===================================================================
--- trunk/BNC/qwt/qwt_abstract_scale.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_abstract_scale.h	(revision 9383)
@@ -28,7 +28,7 @@
 
   The scale division might be assigned explicitly - but usually
-  it is calculated from the boundaries using a QwtScaleEngine. 
+  it is calculated from the boundaries using a QwtScaleEngine.
 
-  The scale engine also decides the type of transformation of the scale 
+  The scale engine also decides the type of transformation of the scale
   ( linear, logarithmic ... ).
 */
@@ -86,5 +86,5 @@
 
 protected:
-    void rescale( double lowerBound, 
+    void rescale( double lowerBound,
         double upperBound, double stepSize );
 
Index: trunk/BNC/qwt/qwt_abstract_scale_draw.cpp
===================================================================
--- trunk/BNC/qwt/qwt_abstract_scale_draw.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_abstract_scale_draw.cpp	(revision 9383)
@@ -26,6 +26,6 @@
         minExtent( 0.0 )
     {
-        components = QwtAbstractScaleDraw::Backbone 
-            | QwtAbstractScaleDraw::Ticks 
+        components = QwtAbstractScaleDraw::Backbone
+            | QwtAbstractScaleDraw::Ticks
             | QwtAbstractScaleDraw::Labels;
 
@@ -198,5 +198,5 @@
         painter->save();
 
-        QPen pen = painter->pen();
+        pen = painter->pen();
         pen.setColor( palette.color( QPalette::WindowText ) );
         pen.setCapStyle( Qt::FlatCap );
@@ -227,5 +227,5 @@
         painter->save();
 
-        QPen pen = painter->pen();
+        pen = painter->pen();
         pen.setColor( palette.color( QPalette::WindowText ) );
         pen.setCapStyle( Qt::FlatCap );
@@ -393,17 +393,16 @@
     const QFont &font, double value ) const
 {
-    QMap<double, QwtText>::const_iterator it = d_data->labelCache.find( value );
-    if ( it == d_data->labelCache.end() )
-    {
-        QwtText lbl = label( value );
-        lbl.setRenderFlags( 0 );
-        lbl.setLayoutAttribute( QwtText::MinimumLayout );
-
-        ( void )lbl.textSize( font ); // initialize the internal cache
-
-        it = d_data->labelCache.insert( value, lbl );
-    }
-
-    return ( *it );
+    QMap<double, QwtText>::const_iterator it1 = d_data->labelCache.constFind( value );
+    if ( it1 != d_data->labelCache.constEnd() )
+        return *it1;
+
+    QwtText lbl = label( value );
+    lbl.setRenderFlags( 0 );
+    lbl.setLayoutAttribute( QwtText::MinimumLayout );
+
+    ( void )lbl.textSize( font ); // initialize the internal cache
+
+    QMap<double, QwtText>::iterator it2 = d_data->labelCache.insert( value, lbl );
+    return *it2;
 }
 
Index: trunk/BNC/qwt/qwt_abstract_scale_draw.h
===================================================================
--- trunk/BNC/qwt/qwt_abstract_scale_draw.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_abstract_scale_draw.h	(revision 9383)
@@ -55,5 +55,5 @@
     virtual ~QwtAbstractScaleDraw();
 
-    void setScaleDiv( const QwtScaleDiv &s );
+    void setScaleDiv( const QwtScaleDiv & );
     const QwtScaleDiv& scaleDiv() const;
 
@@ -69,5 +69,5 @@
     double maxTickLength() const;
 
-    void setSpacing( double margin );
+    void setSpacing( double );
     double spacing() const;
 
Index: trunk/BNC/qwt/qwt_abstract_slider.cpp
===================================================================
--- trunk/BNC/qwt/qwt_abstract_slider.cpp	(revision 9380)
+++ 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;
         }
Index: trunk/BNC/qwt/qwt_abstract_slider.h
===================================================================
--- trunk/BNC/qwt/qwt_abstract_slider.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_abstract_slider.h	(revision 9383)
@@ -18,12 +18,12 @@
 
   A slider widget displays a value according to a scale.
-  The class is designed as a common super class for widgets like 
+  The class is designed as a common super class for widgets like
   QwtKnob, QwtDial and QwtSlider.
 
-  When the slider is nor readOnly() its value can be modified 
-  by keyboard, mouse and wheel inputs. 
+  When the slider is nor readOnly() its value can be modified
+  by keyboard, mouse and wheel inputs.
 
   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.
   Only for linear scales the number of steps correspond with
   a fixed step size.
@@ -68,5 +68,5 @@
     uint pageSteps() const;
 
-    void setStepAlignment( bool ); 
+    void setStepAlignment( bool );
     bool stepAlignment() const;
 
@@ -81,5 +81,5 @@
 
 public Q_SLOTS:
-    void setValue( double val );
+    void setValue( double value );
 
 Q_SIGNALS:
@@ -88,6 +88,6 @@
       \brief Notify a change of value.
 
-      When tracking is enabled (default setting), 
-      this signal will be emitted every time the value changes. 
+      When tracking is enabled (default setting),
+      this signal will be emitted every time the value changes.
 
       \param value New value
@@ -147,5 +147,5 @@
     virtual double scrolledTo( const QPoint &pos ) const = 0;
 
-    void incrementValue( int numSteps );
+    void incrementValue( int stepCount );
 
     virtual void scaleChange();
@@ -154,5 +154,5 @@
     virtual void sliderChange();
 
-    double incrementedValue( 
+    double incrementedValue(
         double value, int stepCount ) const;
 
Index: trunk/BNC/qwt/qwt_analog_clock.cpp
===================================================================
--- trunk/BNC/qwt/qwt_analog_clock.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_analog_clock.cpp	(revision 9383)
@@ -53,5 +53,5 @@
     setTotalSteps( 60 );
 
-    const int secondsPerHour = 60.0 * 60.0; 
+    const int secondsPerHour = 60.0 * 60.0;
 
     QList<double> majorTicks;
@@ -73,5 +73,5 @@
 
     QColor knobColor = palette().color( QPalette::Active, QPalette::Text );
-    knobColor = knobColor.dark( 120 );
+    knobColor = knobColor.darker( 120 );
 
     QColor handColor;
@@ -83,5 +83,5 @@
         {
             width = 2;
-            handColor = knobColor.dark( 120 );
+            handColor = knobColor.darker( 120 );
         }
         else
@@ -201,5 +201,5 @@
     {
         const double hours = value() / ( 60.0 * 60.0 );
-        const double minutes = 
+        const double minutes =
             ( value() - qFloor(hours) * 60.0 * 60.0 ) / 60.0;
         const double seconds = value() - qFloor(hours) * 60.0 * 60.0
@@ -214,5 +214,5 @@
         {
             const double d = 360.0 - angle[hand] - origin();
-            drawHand( painter, static_cast<Hand>( hand ), 
+            drawHand( painter, static_cast<Hand>( hand ),
                 center, radius, d, colorGroup );
         }
Index: trunk/BNC/qwt/qwt_analog_clock.h
===================================================================
--- trunk/BNC/qwt/qwt_analog_clock.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_analog_clock.h	(revision 9383)
@@ -22,5 +22,5 @@
 
   \par Example
-  \code 
+  \code
   #include <qwt_analog_clock.h>
 
Index: trunk/BNC/qwt/qwt_arrow_button.h
===================================================================
--- trunk/BNC/qwt/qwt_arrow_button.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_arrow_button.h	(revision 9383)
@@ -36,5 +36,5 @@
     virtual void paintEvent( QPaintEvent *event );
 
-    virtual void drawButtonLabel( QPainter *p );
+    virtual void drawButtonLabel( QPainter * );
     virtual void drawArrow( QPainter *,
         const QRect &, Qt::ArrowType ) const;
Index: trunk/BNC/qwt/qwt_clipper.cpp
===================================================================
--- trunk/BNC/qwt/qwt_clipper.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_clipper.cpp	(revision 9383)
@@ -151,27 +151,27 @@
     }
 
-    inline void reset() 
-    { 
-        m_size = 0; 
-    }
-
-    inline int size() const 
-    { 
-        return m_size; 
-    }
-
-    inline Point *data() const 
-    { 
-        return m_buffer; 
-    }
-
-    inline Point &operator[]( int i ) 
-    { 
-        return m_buffer[i]; 
-    }
-
-    inline const Point &operator[]( int i ) const 
-    { 
-        return m_buffer[i]; 
+    inline void reset()
+    {
+        m_size = 0;
+    }
+
+    inline int size() const
+    {
+        return m_size;
+    }
+
+    inline Point *data() const
+    {
+        return m_buffer;
+    }
+
+    inline Point &operator[]( int i )
+    {
+        return m_buffer[i];
+    }
+
+    inline const Point &operator[]( int i ) const
+    {
+        return m_buffer[i];
     }
 
@@ -193,5 +193,5 @@
             m_capacity *= 2;
 
-        m_buffer = static_cast<Point *>( 
+        m_buffer = static_cast<Point *>(
             ::realloc( m_buffer, m_capacity * sizeof( Point ) ) );
     }
Index: trunk/BNC/qwt/qwt_clipper.h
===================================================================
--- trunk/BNC/qwt/qwt_clipper.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_clipper.h	(revision 9383)
@@ -26,10 +26,10 @@
 {
 public:
-    static QPolygon clipPolygon( const QRect &, 
+    static QPolygon clipPolygon( const QRect &,
         const QPolygon &, bool closePolygon = false );
-    static QPolygon clipPolygon( const QRectF &, 
+    static QPolygon clipPolygon( const QRectF &,
         const QPolygon &, bool closePolygon = false );
 
-    static QPolygonF clipPolygonF( const QRectF &, 
+    static QPolygonF clipPolygonF( const QRectF &,
         const QPolygonF &, bool closePolygon = false );
 
Index: trunk/BNC/qwt/qwt_color_map.cpp
===================================================================
--- trunk/BNC/qwt/qwt_color_map.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_color_map.cpp	(revision 9383)
@@ -47,6 +47,6 @@
             a = qAlpha( rgb );
 
-            /* 
-                when mapping a value to rgb we will have to calcualate: 
+            /*
+                when mapping a value to rgb we will have to calcualate:
                    - const int v = int( ( s1.v0 + ratio * s1.vStep ) + 0.5 );
 
@@ -346,5 +346,5 @@
 QColor QwtLinearColorMap::color1() const
 {
-    return QColor( d_data->colorStops.rgb( d_data->mode, 0.0 ) );
+    return QColor::fromRgba( d_data->colorStops.rgb( d_data->mode, 0.0 ) );
 }
 
@@ -355,5 +355,5 @@
 QColor QwtLinearColorMap::color2() const
 {
-    return QColor( d_data->colorStops.rgb( d_data->mode, 1.0 ) );
+    return QColor::fromRgba( d_data->colorStops.rgb( d_data->mode, 1.0 ) );
 }
 
Index: trunk/BNC/qwt/qwt_color_map.h
===================================================================
--- trunk/BNC/qwt/qwt_color_map.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_color_map.h	(revision 9383)
@@ -107,5 +107,5 @@
 
     QwtLinearColorMap( QwtColorMap::Format = QwtColorMap::RGB );
-    QwtLinearColorMap( const QColor &from, const QColor &to,
+    QwtLinearColorMap( const QColor &color1, const QColor &color2,
         QwtColorMap::Format = QwtColorMap::RGB );
 
@@ -185,5 +185,7 @@
     {
         const unsigned int index = colorIndex( interval, value );
-        return colorTable( interval )[index]; // slow
+
+        const QVector<QRgb> rgbTable = colorTable( interval );
+        return rgbTable[index]; // slow
     }
 }
Index: trunk/BNC/qwt/qwt_column_symbol.cpp
===================================================================
--- trunk/BNC/qwt/qwt_column_symbol.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_column_symbol.cpp	(revision 9383)
@@ -115,7 +115,7 @@
         style( QwtColumnSymbol::Box ),
         frameStyle( QwtColumnSymbol::Raised ),
+        palette( Qt::gray ),
         lineWidth( 2 )
     {
-        palette = QPalette( Qt::gray );
     }
 
@@ -288,6 +288,6 @@
         default:
         {
-            painter->fillRect( r, d_data->palette.window() );
-        }
-    }
-}
+            painter->fillRect( r.adjusted( 0, 0, 1, 1 ), d_data->palette.window() );
+        }
+    }
+}
Index: trunk/BNC/qwt/qwt_column_symbol.h
===================================================================
--- trunk/BNC/qwt/qwt_column_symbol.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_column_symbol.h	(revision 9383)
@@ -137,5 +137,5 @@
     virtual ~QwtColumnSymbol();
 
-    void setFrameStyle( FrameStyle style );
+    void setFrameStyle( FrameStyle );
     FrameStyle frameStyle() const;
 
Index: trunk/BNC/qwt/qwt_compass.cpp
===================================================================
--- trunk/BNC/qwt/qwt_compass.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_compass.cpp	(revision 9383)
@@ -18,5 +18,5 @@
 #include <qevent.h>
 
-/*! 
+/*!
   \brief Constructor
 
@@ -49,5 +49,5 @@
 }
 
-/*! 
+/*!
   \brief Constructor
 
@@ -96,5 +96,5 @@
   or returns an null text.
 
-  \return Label, or QString::null
+  \return Label
   \sa labelMap(), setLabelMap()
 */
Index: trunk/BNC/qwt/qwt_compass_rose.cpp
===================================================================
--- trunk/BNC/qwt/qwt_compass_rose.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_compass_rose.cpp	(revision 9383)
@@ -12,6 +12,7 @@
 #include "qwt_painter.h"
 #include <qpainter.h>
-
-static QPointF qwtIntersection( 
+#include <qpainterpath.h>
+
+static QPointF qwtIntersection(
     QPointF p11, QPointF p12, QPointF p21, QPointF p22 )
 {
@@ -213,5 +214,5 @@
 }
 
-/*! 
+/*!
   \return Width of the rose
   \sa setWidth()
Index: trunk/BNC/qwt/qwt_compass_rose.h
===================================================================
--- trunk/BNC/qwt/qwt_compass_rose.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_compass_rose.h	(revision 9383)
@@ -46,5 +46,5 @@
         \param colorGroup Color group
      */
-    virtual void draw( QPainter *painter, 
+    virtual void draw( QPainter *painter,
         const QPointF &center, double radius, double north,
         QPalette::ColorGroup colorGroup = QPalette::Active ) const = 0;
@@ -63,11 +63,11 @@
     virtual ~QwtSimpleCompassRose();
 
-    void setWidth( double w );
+    void setWidth( double );
     double width() const;
 
-    void setNumThorns( int count );
+    void setNumThorns( int );
     int numThorns() const;
 
-    void setNumThornLevels( int count );
+    void setNumThornLevels( int );
     int numThornLevels() const;
 
@@ -79,5 +79,5 @@
 
     static void drawRose( QPainter *, const QPalette &,
-        const QPointF &center, double radius, double origin, double width,
+        const QPointF &center, double radius, double north, double width,
         int numThorns, int numThornLevels, double shrinkFactor );
 
@@ -87,3 +87,3 @@
 };
 
-#endif 
+#endif
Index: trunk/BNC/qwt/qwt_counter.cpp
===================================================================
--- trunk/BNC/qwt/qwt_counter.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_counter.cpp	(revision 9383)
@@ -51,5 +51,5 @@
 
 /*!
-  The counter is initialized with a range is set to [0.0, 1.0] with 
+  The counter is initialized with a range is set to [0.0, 1.0] with
   0.01 as single step size. The value is invalid.
 
@@ -83,6 +83,6 @@
         layout->addWidget( btn );
 
-        connect( btn, SIGNAL( released() ), SLOT( btnReleased() ) );
-        connect( btn, SIGNAL( clicked() ), SLOT( btnClicked() ) );
+        connect( btn, SIGNAL(released()), SLOT(btnReleased()) );
+        connect( btn, SIGNAL(clicked()), SLOT(btnClicked()) );
 
         d_data->buttonDown[i] = btn;
@@ -94,6 +94,5 @@
     layout->addWidget( d_data->valueEdit );
 
-    connect( d_data->valueEdit, SIGNAL( editingFinished() ),
-         SLOT( textChanged() ) );
+    connect( d_data->valueEdit, SIGNAL(editingFinished()), SLOT(textChanged()) );
 
     layout->setStretchFactor( d_data->valueEdit, 10 );
@@ -107,6 +106,6 @@
         layout->addWidget( btn );
 
-        connect( btn, SIGNAL( released() ), SLOT( btnReleased() ) );
-        connect( btn, SIGNAL( clicked() ), SLOT( btnClicked() ) );
+        connect( btn, SIGNAL(released()), SLOT(btnReleased()) );
+        connect( btn, SIGNAL(clicked()), SLOT(btnClicked()) );
 
         d_data->buttonUp[i] = btn;
@@ -131,5 +130,5 @@
 }
 
-/*! 
+/*!
   Set the counter to be in valid/invalid state
 
@@ -137,5 +136,5 @@
   the buttons are disabled.
 
-  \param on If true the counter will be set as valid 
+  \param on If true the counter will be set as valid
 
   \sa setValue(), isValid()
@@ -156,10 +155,10 @@
         else
         {
-            d_data->valueEdit->setText( QString::null );
-        }
-    }   
-}   
-
-/*! 
+            d_data->valueEdit->setText( QString() );
+        }
+    }
+}
+
+/*!
   \return True, if the value is valid
   \sa setValid(), setValue()
@@ -168,5 +167,5 @@
 {
     return d_data->isValid;
-}   
+}
 
 /*!
@@ -181,5 +180,5 @@
 }
 
-/*! 
+/*!
    \return True, when the line line edit is read only. (default is no)
   \sa setReadOnly()
@@ -335,6 +334,6 @@
   \brief En/Disable wrapping
 
-  If wrapping is true stepping up from maximum() value will take 
-  you to the minimum() value and vice versa. 
+  If wrapping is true stepping up from maximum() value will take
+  you to the minimum() value and vice versa.
 
   \param on En/Disable wrapping
Index: trunk/BNC/qwt/qwt_counter.h
===================================================================
--- trunk/BNC/qwt/qwt_counter.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_counter.h	(revision 9383)
@@ -25,7 +25,7 @@
   and a step size. When the wrapping property is set
   the counter is circular.
- 
-  The number of steps by which a button increments or decrements the value 
-  can be specified using setIncSteps(). The number of buttons can be 
+
+  The number of steps by which a button increments or decrements the value
+  can be specified using setIncSteps(). The number of buttons can be
   changed with setNumButtons().
 
@@ -92,22 +92,22 @@
     void setReadOnly( bool );
 
-    void setNumButtons( int n );
+    void setNumButtons( int );
     int numButtons() const;
 
-    void setIncSteps( QwtCounter::Button btn, int nSteps );
-    int incSteps( QwtCounter::Button btn ) const;
+    void setIncSteps( QwtCounter::Button, int numSteps );
+    int incSteps( QwtCounter::Button ) const;
 
     virtual QSize sizeHint() const;
 
     double singleStep() const;
-    void setSingleStep( double s );
+    void setSingleStep( double stepSize );
 
     void setRange( double min, double max );
-    
+
     double minimum() const;
-    void setMinimum( double min );
+    void setMinimum( double );
 
     double maximum() const;
-    void setMaximum( double max );
+    void setMaximum( double );
 
     void setStepButton1( int nSteps );
Index: trunk/BNC/qwt/qwt_curve_fitter.cpp
===================================================================
--- trunk/BNC/qwt/qwt_curve_fitter.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_curve_fitter.cpp	(revision 9383)
@@ -334,6 +334,5 @@
 
 /*!
-  
-  \return Maximum for the number of points passed to a run 
+  \return Maximum for the number of points passed to a run
           of the algorithm - or 0, when unlimited
   \sa setChunkSize()
@@ -350,6 +349,8 @@
 QPolygonF QwtWeedingCurveFitter::fitCurve( const QPolygonF &points ) const
 {
+    if ( points.isEmpty() )
+        return points;
+
     QPolygonF fittedPoints;
-
     if ( d_data->chunkSize == 0 )
     {
Index: trunk/BNC/qwt/qwt_curve_fitter.h
===================================================================
--- trunk/BNC/qwt/qwt_curve_fitter.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_curve_fitter.h	(revision 9383)
@@ -78,5 +78,5 @@
     QwtSpline &spline();
 
-    void setSplineSize( int size );
+    void setSplineSize( int );
     int splineSize() const;
 
Index: trunk/BNC/qwt/qwt_date.cpp
===================================================================
--- trunk/BNC/qwt/qwt_date.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_date.cpp	(revision 9383)
@@ -32,5 +32,5 @@
 #endif
 
-static QString qwtExpandedFormat( const QString & format, 
+static QString qwtExpandedFormat( const QString & format,
     const QDateTime &dateTime, QwtDate::Week0Type week0Type )
 {
@@ -195,5 +195,5 @@
 }
 
-static inline void qwtFloorTime( 
+static inline void qwtFloorTime(
     QwtDate::IntervalType intervalType, QDateTime &dt )
 {
@@ -224,5 +224,5 @@
             dt.setTime( QTime( t.hour(), 0, 0 ) );
             break;
-        }   
+        }
         default:
             break;
@@ -233,5 +233,5 @@
 }
 
-static inline QDateTime qwtToTimeSpec( 
+static inline QDateTime qwtToTimeSpec(
     const QDateTime &dt, Qt::TimeSpec spec )
 {
@@ -255,4 +255,6 @@
 }
 
+#if 0
+
 static inline double qwtToJulianDay( int year, int month, int day )
 {
@@ -280,7 +282,9 @@
     if ( a < 0 )
         a -= b - 1;
-        
+
     return a / b;
-}   
+}
+
+#endif
 
 static inline QDate qwtToDate( int year, int month = 1, int day = 1 )
@@ -319,5 +323,5 @@
   Translate from double to QDateTime
 
-  \param value Number of milliseconds since the epoch, 
+  \param value Number of milliseconds since the epoch,
                1970-01-01T00:00:00 UTC
   \param timeSpec Time specification
@@ -373,5 +377,5 @@
 
     const QTime time = dt.time();
-    const double secs = 3600.0 * time.hour() + 
+    const double secs = 3600.0 * time.hour() +
         60.0 * time.minute() + time.second();
 
@@ -383,5 +387,5 @@
 
   \param dateTime Datetime value
-  \param intervalType Interval type, how to ceil. 
+  \param intervalType Interval type, how to ceil.
                       F.e. when intervalType = QwtDate::Months, the result
                       will be ceiled to the next beginning of a month
@@ -451,5 +455,5 @@
         {
             dt.setTime( QTime( 0, 0 ) );
-            dt.setDate( qwtToDate( dateTime.date().year(), 
+            dt.setDate( qwtToDate( dateTime.date().year(),
                 dateTime.date().month() ) );
 
@@ -484,12 +488,12 @@
 
   \param dateTime Datetime value
-  \param intervalType Interval type, how to ceil. 
+  \param intervalType Interval type, how to ceil.
                       F.e. when intervalType = QwtDate::Months,
-                      the result will be ceiled to the next 
+                      the result will be ceiled to the next
                       beginning of a month
   \return Floored datetime
   \sa floor()
  */
-QDateTime QwtDate::floor( const QDateTime &dateTime, 
+QDateTime QwtDate::floor( const QDateTime &dateTime,
     IntervalType intervalType )
 {
@@ -533,5 +537,5 @@
             dt.setTime( QTime( 0, 0 ) );
 
-            const QDate date = qwtToDate( dt.date().year(), 
+            const QDate date = qwtToDate( dt.date().year(),
                 dt.date().month() );
             dt.setDate( date );
@@ -556,5 +560,5 @@
   Minimum for the supported date range
 
-  The range of valid dates depends on how QDate stores the 
+  The range of valid dates depends on how QDate stores the
   Julian day internally.
 
@@ -577,5 +581,5 @@
   Maximum for the supported date range
 
-  The range of valid dates depends on how QDate stores the 
+  The range of valid dates depends on how QDate stores the
   Julian day internally.
 
@@ -600,5 +604,5 @@
 
   The first day of a week depends on the current locale
-  ( QLocale::firstDayOfWeek() ). 
+  ( QLocale::firstDayOfWeek() ).
 
   \param year Year
@@ -607,5 +611,5 @@
 
   \sa QLocale::firstDayOfWeek(), weekNumber()
- */ 
+ */
 QDate QwtDate::dateOfWeek0( int year, Week0Type type )
 {
@@ -624,5 +628,5 @@
     {
         // according to ISO 8601 the first week is defined
-        // by the first thursday. 
+        // by the first thursday.
 
         int d = Qt::Thursday - firstDayOfWeek;
@@ -641,5 +645,5 @@
 
   - QwtDate::FirstThursday\n
-    Corresponding to ISO 8601 ( see QDate::weekNumber() ). 
+    Corresponding to ISO 8601 ( see QDate::weekNumber() ).
 
   - QwtDate::FirstDay\n
@@ -737,5 +741,5 @@
     week number with a leading zero ( 01 - 53 )
 
-  As week 1 usually starts in the previous year a special rule 
+  As week 1 usually starts in the previous year a special rule
   is applied for formats, where the year is expected to match the
   week number - even if the date belongs to the previous year.
Index: trunk/BNC/qwt/qwt_date.h
===================================================================
--- trunk/BNC/qwt/qwt_date.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_date.h	(revision 9383)
@@ -23,13 +23,13 @@
   A double is interpreted as the number of milliseconds since
   1970-01-01T00:00:00 Universal Coordinated Time - also known
-  as "The Epoch". 
+  as "The Epoch".
 
-  While the range of the Julian day in Qt4 is limited to [0, MAX_INT], 
-  Qt5 stores it as qint64 offering a huge range of valid dates. 
-  As the significance of a double is below this ( assuming a 
-  fraction of 52 bits ) the translation is not 
-  bijective with rounding errors for dates very far from Epoch. 
-  For a resolution of 1 ms those start to happen for dates above the 
-  year 144683. 
+  While the range of the Julian day in Qt4 is limited to [0, MAX_INT],
+  Qt5 stores it as qint64 offering a huge range of valid dates.
+  As the significance of a double is below this ( assuming a
+  fraction of 52 bits ) the translation is not
+  bijective with rounding errors for dates very far from Epoch.
+  For a resolution of 1 ms those start to happen for dates above the
+  year 144683.
 
   An axis for a date/time interval is expected to be aligned
@@ -43,7 +43,7 @@
 {
 public:
-    /*! 
+    /*!
        How to identify the first week of year differs between
-       countries. 
+       countries.
      */
     enum Week0Type
@@ -60,5 +60,5 @@
         /*!
             "The week with January 1.1 in it."
-           
+
             In the U.S. this definition is more common than
             FirstThursday.
@@ -67,5 +67,5 @@
     };
 
-    /*! 
+    /*!
       Classification of an time interval
 
@@ -109,5 +109,5 @@
     static QDate maxDate();
 
-    static QDateTime toDateTime( double value, 
+    static QDateTime toDateTime( double value,
         Qt::TimeSpec = Qt::UTC );
 
@@ -122,5 +122,5 @@
     static int utcOffset( const QDateTime & );
 
-    static QString toString( const QDateTime &, 
+    static QString toString( const QDateTime &,
         const QString & format, Week0Type );
 };
Index: trunk/BNC/qwt/qwt_date_scale_draw.cpp
===================================================================
--- trunk/BNC/qwt/qwt_date_scale_draw.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_date_scale_draw.cpp	(revision 9383)
@@ -37,5 +37,5 @@
   \brief Constructor
 
-  The default setting is to display tick labels for the 
+  The default setting is to display tick labels for the
   given time specification. The first week of a year is defined like
   for QwtDate::FirstThursday.
@@ -110,5 +110,5 @@
   \sa week0Type().
   \note week0Type has no effect beside for intervals classified as
-        QwtDate::Week. 
+        QwtDate::Week.
  */
 void QwtDateScaleDraw::setWeek0Type( QwtDate::Week0Type week0Type )
@@ -118,5 +118,5 @@
 
 /*!
-  \return Setting how to identify the first week of a year. 
+  \return Setting how to identify the first week of a year.
   \sa setWeek0Type()
  */
@@ -134,8 +134,8 @@
   \sa dateFormat(), dateFormatOfDate(), QwtDate::toString()
  */
-void QwtDateScaleDraw::setDateFormat( 
+void QwtDateScaleDraw::setDateFormat(
     QwtDate::IntervalType intervalType, const QString &format )
 {
-    if ( intervalType >= QwtDate::Millisecond && 
+    if ( intervalType >= QwtDate::Millisecond &&
         intervalType <= QwtDate::Year )
     {
@@ -149,8 +149,8 @@
   \sa setDateFormat(), dateFormatOfDate()
  */
-QString QwtDateScaleDraw::dateFormat( 
+QString QwtDateScaleDraw::dateFormat(
     QwtDate::IntervalType intervalType ) const
 {
-    if ( intervalType >= QwtDate::Millisecond && 
+    if ( intervalType >= QwtDate::Millisecond &&
         intervalType <= QwtDate::Year )
     {
@@ -158,5 +158,5 @@
     }
 
-    return QString::null;
+    return QString();
 }
 
@@ -182,5 +182,5 @@
     Q_UNUSED( dateTime )
 
-    if ( intervalType >= QwtDate::Millisecond && 
+    if ( intervalType >= QwtDate::Millisecond &&
         intervalType <= QwtDate::Year )
     {
@@ -205,5 +205,5 @@
 {
     const QDateTime dt = toDateTime( value );
-    const QString fmt = dateFormatOfDate( 
+    const QString fmt = dateFormatOfDate(
         dt, intervalType( scaleDiv() ) );
 
@@ -220,5 +220,5 @@
   \sa dateFormatOfDate()
  */
-QwtDate::IntervalType QwtDateScaleDraw::intervalType( 
+QwtDate::IntervalType QwtDateScaleDraw::intervalType(
     const QwtScaleDiv &scaleDiv ) const
 {
@@ -233,5 +233,5 @@
         for ( int j = QwtDate::Second; j <= intvType; j++ )
         {
-            const QDateTime dt0 = QwtDate::floor( dt, 
+            const QDateTime dt0 = QwtDate::floor( dt,
                 static_cast<QwtDate::IntervalType>( j ) );
 
Index: trunk/BNC/qwt/qwt_date_scale_draw.h
===================================================================
--- trunk/BNC/qwt/qwt_date_scale_draw.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_date_scale_draw.h	(revision 9383)
@@ -73,5 +73,5 @@
 
 protected:
-    virtual QwtDate::IntervalType 
+    virtual QwtDate::IntervalType
         intervalType( const QwtScaleDiv & ) const;
 
Index: trunk/BNC/qwt/qwt_date_scale_engine.cpp
===================================================================
--- trunk/BNC/qwt/qwt_date_scale_engine.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_date_scale_engine.cpp	(revision 9383)
@@ -14,5 +14,5 @@
 #include <limits.h>
 
-static inline double qwtMsecsForType( QwtDate::IntervalType type )
+static inline double qwtMsecsForType( int type )
 {
     static const double msecs[] =
@@ -44,5 +44,5 @@
 
 static double qwtIntervalWidth( const QDateTime &minDate,
-    const QDateTime &maxDate, QwtDate::IntervalType intervalType ) 
+    const QDateTime &maxDate, QwtDate::IntervalType intervalType )
 {
     switch( intervalType )
@@ -80,5 +80,5 @@
         case QwtDate::Month:
         {
-            const double years = 
+            const double years =
                 double( maxDate.date().year() ) - minDate.date().year();
 
@@ -91,5 +91,5 @@
         case QwtDate::Year:
         {
-            double years = 
+            double years =
                 double( maxDate.date().year() ) - minDate.date().year();
 
@@ -104,7 +104,7 @@
 }
 
-static double qwtRoundedIntervalWidth( 
-    const QDateTime &minDate, const QDateTime &maxDate, 
-    QwtDate::IntervalType intervalType ) 
+static double qwtRoundedIntervalWidth(
+    const QDateTime &minDate, const QDateTime &maxDate,
+    QwtDate::IntervalType intervalType )
 {
     const QDateTime minD = QwtDate::floor( minDate, intervalType );
@@ -131,5 +131,5 @@
 }
 
-static int qwtStepSize( int intervalSize, int maxSteps, uint base ) 
+static int qwtStepSize( int intervalSize, int maxSteps, uint base )
 {
     if ( maxSteps <= 0 )
@@ -162,5 +162,5 @@
 }
 
-static int qwtDivideInterval( double intervalSize, int numSteps, 
+static int qwtDivideInterval( double intervalSize, int numSteps,
     const int limits[], size_t numLimits )
 {
@@ -181,5 +181,5 @@
     if ( intervalType != QwtDate::Day )
     {
-        if ( ( intervalSize > numSteps ) && 
+        if ( ( intervalSize > numSteps ) &&
             ( intervalSize <= 2 * numSteps ) )
         {
@@ -196,5 +196,5 @@
         {
             static int limits[] = { 1, 2, 5, 10, 15, 20, 30, 60 };
-    
+
             stepSize = qwtDivideInterval( intervalSize, numSteps,
                 limits, sizeof( limits ) / sizeof( int ) );
@@ -205,5 +205,5 @@
         {
             static int limits[] = { 1, 2, 3, 4, 6, 12, 24 };
-    
+
             stepSize = qwtDivideInterval( intervalSize, numSteps,
                 limits, sizeof( limits ) / sizeof( int ) );
@@ -274,5 +274,5 @@
             if ( stepSize > maxMinSteps )
             {
-                numSteps = qwtStepCount( stepSize, maxMinSteps, 
+                numSteps = qwtStepCount( stepSize, maxMinSteps,
                     limits, sizeof( limits ) / sizeof( int ) );
 
@@ -280,5 +280,5 @@
             else
             {
-                numSteps = qwtStepCount( stepSize * 60, maxMinSteps, 
+                numSteps = qwtStepCount( stepSize * 60, maxMinSteps,
                     limits, sizeof( limits ) / sizeof( int ) );
             }
@@ -359,5 +359,5 @@
                 else
                 {
-                    minStepSize = QwtScaleArithmetic::divideInterval( 
+                    minStepSize = QwtScaleArithmetic::divideInterval(
                         stepSizeInWeeks, maxMinSteps, 10 );
                 }
@@ -401,5 +401,5 @@
                     minStepSize = double( stepSize ) / numSteps;
             }
-                
+
             break;
         }
@@ -445,15 +445,15 @@
 }
 
-static QwtScaleDiv qwtDivideToSeconds( 
+static QwtScaleDiv qwtDivideToSeconds(
     const QDateTime &minDate, const QDateTime &maxDate,
     double stepSize, int maxMinSteps,
-    QwtDate::IntervalType intervalType ) 
+    QwtDate::IntervalType intervalType )
 {
     // calculate the min step size
     double minStepSize = 0;
 
-    if ( maxMinSteps > 1 ) 
-    {
-        minStepSize = qwtDivideMajorStep( stepSize, 
+    if ( maxMinSteps > 1 )
+    {
+        minStepSize = qwtDivideMajorStep( stepSize,
             maxMinSteps, intervalType );
     }
@@ -472,5 +472,5 @@
     const int secondsMajor = static_cast<int>( stepSize * s );
     const double secondsMinor = minStepSize * s;
-    
+
     // UTC excludes daylight savings. So from the difference
     // of a date and its UTC counterpart we can find out
@@ -484,5 +484,5 @@
     QList<double> minorTicks;
 
-    for ( QDateTime dt = minDate; dt <= maxDate; 
+    for ( QDateTime dt = minDate; dt <= maxDate;
         dt = dt.addSecs( secondsMajor ) )
     {
@@ -501,5 +501,5 @@
                 // we add some minor ticks for the DST hour,
                 // otherwise the ticks will be unaligned: 0, 2, 3, 5 ...
-                minorTicks += qwtDstTicks( 
+                minorTicks += qwtDstTicks(
                     dt, secondsMajor, qRound( secondsMinor ) );
             }
@@ -517,5 +517,5 @@
             for ( int i = 1; i < numMinorSteps; i++ )
             {
-                const QDateTime mt = dt.addMSecs( 
+                const QDateTime mt = dt.addMSecs(
                     qRound64( i * secondsMinor * 1000 ) );
 
@@ -529,5 +529,5 @@
                 if ( minorTicks.isEmpty() || minorTicks.last() != minorValue )
                 {
-                    const bool isMedium = ( numMinorSteps % 2 == 0 ) 
+                    const bool isMedium = ( numMinorSteps % 2 == 0 )
                         && ( i != 1 ) && ( i == numMinorSteps / 2 );
 
@@ -553,14 +553,14 @@
 }
 
-static QwtScaleDiv qwtDivideToMonths( 
+static QwtScaleDiv qwtDivideToMonths(
     QDateTime &minDate, const QDateTime &maxDate,
-    double stepSize, int maxMinSteps ) 
-{
-    // months are intervals with non 
-    // equidistant ( in ms ) steps: we have to build the 
+    double stepSize, int maxMinSteps )
+{
+    // months are intervals with non
+    // equidistant ( in ms ) steps: we have to build the
     // scale division manually
 
     int minStepDays = 0;
-    int minStepSize = 0.0; 
+    int minStepSize = 0.0;
 
     if ( maxMinSteps > 1 )
@@ -579,5 +579,5 @@
         else
         {
-            minStepSize = qwtDivideMajorStep( 
+            minStepSize = qwtDivideMajorStep(
                 stepSize, maxMinSteps, QwtDate::Month );
         }
@@ -588,5 +588,5 @@
     QList<double> minorTicks;
 
-    for ( QDateTime dt = minDate; 
+    for ( QDateTime dt = minDate;
         dt <= maxDate; dt = dt.addMonths( stepSize ) )
     {
@@ -598,5 +598,5 @@
         if ( minStepDays > 0 )
         {
-            for ( int days = minStepDays; 
+            for ( int days = minStepDays;
                 days < 30; days += minStepDays )
             {
@@ -637,7 +637,7 @@
 }
 
-static QwtScaleDiv qwtDivideToYears( 
+static QwtScaleDiv qwtDivideToYears(
     const QDateTime &minDate, const QDateTime &maxDate,
-    double stepSize, int maxMinSteps ) 
+    double stepSize, int maxMinSteps )
 {
     QList<double> majorTicks;
@@ -649,5 +649,5 @@
     if ( maxMinSteps > 1 )
     {
-        minStepSize = qwtDivideMajorStep( 
+        minStepSize = qwtDivideMajorStep(
             stepSize, maxMinSteps, QwtDate::Year );
     }
@@ -702,5 +702,5 @@
             break;
         }
-    }   
+    }
 
     QwtScaleDiv scaleDiv;
@@ -730,5 +730,5 @@
     QwtDate::Week0Type week0Type;
     int maxWeeks;
-};      
+};
 
 
@@ -736,5 +736,5 @@
   \brief Constructor
 
-  The engine is initialized to build scales for the 
+  The engine is initialized to build scales for the
   given time specification. It classifies intervals > 4 weeks
   as >= Qt::Month. The first week of a year is defined like
@@ -811,5 +811,5 @@
   \sa week0Type(), setMaxWeeks()
   \note week0Type has no effect beside for intervals classified as
-        QwtDate::Week. 
+        QwtDate::Week.
  */
 void QwtDateScaleEngine::setWeek0Type( QwtDate::Week0Type week0Type )
@@ -819,5 +819,5 @@
 
 /*!
-  \return Setting how to identify the first week of a year. 
+  \return Setting how to identify the first week of a year.
   \sa setWeek0Type(), maxWeeks()
  */
@@ -835,7 +835,7 @@
   \param weeks Upper limit for the number of weeks
 
-  \note In business charts a year is often devided
+  \note In business charts a year is often divided
         into weeks [1-52]
-  \sa maxWeeks(), setWeek0Type() 
+  \sa maxWeeks(), setWeek0Type()
  */
 void QwtDateScaleEngine::setMaxWeeks( int weeks )
@@ -863,6 +863,6 @@
   \return Interval classification
  */
-QwtDate::IntervalType QwtDateScaleEngine::intervalType( 
-    const QDateTime &minDate, const QDateTime &maxDate, 
+QwtDate::IntervalType QwtDateScaleEngine::intervalType(
+    const QDateTime &minDate, const QDateTime &maxDate,
     int maxSteps ) const
 {
@@ -910,9 +910,9 @@
   Align and divide an interval
 
-  The algorithm aligns and divides the interval into steps. 
+  The algorithm aligns and divides the interval into steps.
 
   Datetime interval divisions are usually not equidistant and the
   calculated stepSize can only be used as an approximation
-  for the steps calculated by divideScale(). 
+  for the steps calculated by divideScale().
 
   \param maxNumSteps Max. number of steps
@@ -951,5 +951,5 @@
             maxNumSteps = 1;
 
-        const QwtDate::IntervalType intvType = 
+        const QwtDate::IntervalType intvType =
             intervalType( from, to, maxNumSteps );
 
@@ -1015,5 +1015,5 @@
     }
 
-    const QwtDate::IntervalType intvType = 
+    const QwtDate::IntervalType intvType =
         intervalType( from, to, maxMajorSteps );
 
@@ -1031,5 +1031,5 @@
         const QDateTime maxDate = QwtDate::ceil( to, intvType );
 
-        scaleDiv = buildScaleDiv( minDate, maxDate, 
+        scaleDiv = buildScaleDiv( minDate, maxDate,
             maxMajorSteps, maxMinorSteps, intvType );
 
@@ -1046,5 +1046,5 @@
 }
 
-QwtScaleDiv QwtDateScaleEngine::buildScaleDiv( 
+QwtScaleDiv QwtDateScaleEngine::buildScaleDiv(
     const QDateTime &minDate, const QDateTime &maxDate,
     int maxMajorSteps, int maxMinorSteps,
@@ -1052,6 +1052,6 @@
 {
     // calculate the step size
-    const double stepSize = qwtDivideScale( 
-        qwtIntervalWidth( minDate, maxDate, intervalType ), 
+    const double stepSize = qwtDivideScale(
+        qwtIntervalWidth( minDate, maxDate, intervalType ),
         maxMajorSteps, intervalType );
 
@@ -1060,5 +1060,5 @@
     if ( !dt0.isValid() )
     {
-        // the floored date is out of the range of a 
+        // the floored date is out of the range of a
         // QDateTime - we ceil instead.
         dt0 = alignDate( minDate, stepSize, intervalType, true );
@@ -1069,5 +1069,5 @@
     if ( intervalType <= QwtDate::Week )
     {
-        scaleDiv = qwtDivideToSeconds( dt0, maxDate, 
+        scaleDiv = qwtDivideToSeconds( dt0, maxDate,
             stepSize, maxMinorSteps, intervalType );
     }
@@ -1094,5 +1094,5 @@
 
   For Qt::Day alignments there is no "natural day 0" -
-  instead the first day of the year is used to avoid jumping 
+  instead the first day of the year is used to avoid jumping
   major ticks positions when panning a scale. For other alignments
   ( f.e according to the first day of the month ) alignDate()
@@ -1106,6 +1106,6 @@
   \return Aligned date/time value
  */
-QDateTime QwtDateScaleEngine::alignDate( 
-    const QDateTime &dateTime, double stepSize, 
+QDateTime QwtDateScaleEngine::alignDate(
+    const QDateTime &dateTime, double stepSize,
     QwtDate::IntervalType intervalType, bool up ) const
 {
@@ -1123,5 +1123,5 @@
         case QwtDate::Millisecond:
         {
-            const int ms = qwtAlignValue( 
+            const int ms = qwtAlignValue(
                 dt.time().msec(), stepSize, up ) ;
 
@@ -1293,5 +1293,5 @@
     if ( !dt.isValid() )
     {
-        const QDate date = ( value <= 0.0 ) 
+        const QDate date = ( value <= 0.0 )
             ? QwtDate::minDate() : QwtDate::maxDate();
 
Index: trunk/BNC/qwt/qwt_date_scale_engine.h
===================================================================
--- trunk/BNC/qwt/qwt_date_scale_engine.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_date_scale_engine.h	(revision 9383)
@@ -28,10 +28,10 @@
   QwtDateScaleEngine supports representations depending
   on Qt::TimeSpec specifications. The valid range for scales
-  is limited by the range of QDateTime, that differs 
+  is limited by the range of QDateTime, that differs
   between Qt4 and Qt5.
-  
+
   Datetime values are expected as the number of milliseconds since
   1970-01-01T00:00:00 Universal Coordinated Time - also known
-  as "The Epoch", that can be converted to QDateTime using 
+  as "The Epoch", that can be converted to QDateTime using
   QwtDate::toDateTime().
 
@@ -53,5 +53,5 @@
     void setWeek0Type( QwtDate::Week0Type );
     QwtDate::Week0Type week0Type() const;
-    
+
     void setMaxWeeks( int );
     int maxWeeks() const;
@@ -60,10 +60,10 @@
         double &x1, double &x2, double &stepSize ) const;
 
-    virtual QwtScaleDiv divideScale( 
+    virtual QwtScaleDiv divideScale(
         double x1, double x2,
         int maxMajorSteps, int maxMinorSteps,
         double stepSize = 0.0 ) const;
 
-    virtual QwtDate::IntervalType intervalType( 
+    virtual QwtDate::IntervalType intervalType(
         const QDateTime &, const QDateTime &, int maxSteps ) const;
 
@@ -76,5 +76,5 @@
 private:
     QwtScaleDiv buildScaleDiv( const QDateTime &, const QDateTime &,
-        int maxMajorSteps, int maxMinorSteps, 
+        int maxMajorSteps, int maxMinorSteps,
         QwtDate::IntervalType ) const;
 
Index: trunk/BNC/qwt/qwt_dial.cpp
===================================================================
--- trunk/BNC/qwt/qwt_dial.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_dial.cpp	(revision 9383)
@@ -238,5 +238,5 @@
     const QRect cr = contentsRect();
 
-    const double dim = qMin( cr.width(), cr.height() );
+    const int dim = qMin( cr.width(), cr.height() );
 
     QRect inner( 0, 0, dim, dim );
@@ -338,5 +338,5 @@
         p.setRenderHint( QPainter::Antialiasing, true );
         p.translate( -r.topLeft() );
-            
+
         if ( d_data->mode != QwtDial::RotateScale )
             drawContents( &p );
@@ -475,5 +475,5 @@
   \param radius Radius of the scale
 */
-void QwtDial::drawScale( QPainter *painter, 
+void QwtDial::drawScale( QPainter *painter,
     const QPointF &center, double radius ) const
 {
@@ -568,7 +568,7 @@
 
   The motivation for setting a scale draw is often
-  to overload QwtRoundScaleDraw::label() to return 
+  to overload QwtRoundScaleDraw::label() to return
   individual tick labels.
-  
+
   \param scaleDraw Scale draw
   \warning The previous scale draw is deleted
@@ -601,5 +601,5 @@
         maxScaleArc = minScaleArc + 360.0;
 
-    if ( ( minScaleArc != d_data->minScaleArc ) || 
+    if ( ( minScaleArc != d_data->minScaleArc ) ||
         ( maxScaleArc != d_data->maxScaleArc ) )
     {
@@ -612,5 +612,5 @@
 }
 
-/*! 
+/*!
   Set the lower limit for the scale arc
 
@@ -623,5 +623,5 @@
 }
 
-/*! 
+/*!
   \return Lower limit of the scale arc
   \sa setScaleArc()
@@ -632,5 +632,5 @@
 }
 
-/*! 
+/*!
   Set the upper limit for the scale arc
 
@@ -643,5 +643,5 @@
 }
 
-/*! 
+/*!
   \return Upper limit of the scale arc
   \sa setScaleArc()
@@ -691,5 +691,5 @@
     const int d = 6 * sh + 2 * lineWidth();
 
-    QSize hint( d, d ); 
+    QSize hint( d, d );
     if ( !isReadOnly() )
         hint = hint.expandedTo( QApplication::globalStrut() );
@@ -718,5 +718,5 @@
   \param pos Mouse position
 
-  \retval True, when the inner circle contains pos 
+  \retval True, when the inner circle contains pos
   \sa scrolledTo()
 */
@@ -730,5 +730,5 @@
             angle = 360.0 - angle;
 
-        double valueAngle = 
+        double valueAngle =
             qwtNormalizeDegrees( 90.0 - scaleMap().transform( value() ) );
 
@@ -775,5 +775,5 @@
             if ( qAbs( arc ) > 180.0 )
             {
-                boundedAngle = ( arc > 0 ) 
+                boundedAngle = ( arc > 0 )
                     ? scaleMap().p1() : scaleMap().p2();
             }
@@ -821,5 +821,5 @@
             break;
     }
-    
+
     QwtAbstractSlider::changeEvent( event );
 }
@@ -847,5 +847,5 @@
 
 /*!
-  Invalidate the internal caches and call 
+  Invalidate the internal caches and call
   QwtAbstractSlider::scaleChange()
  */
Index: trunk/BNC/qwt/qwt_dial.h
===================================================================
--- trunk/BNC/qwt/qwt_dial.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_dial.h	(revision 9383)
@@ -104,10 +104,10 @@
     Mode mode() const;
 
-    void setScaleArc( double min, double max );
+    void setScaleArc( double minArc, double maxArc );
 
-    void setMinScaleArc( double min );
+    void setMinScaleArc( double );
     double minScaleArc() const;
 
-    void setMaxScaleArc( double min );
+    void setMaxScaleArc( double );
     double maxScaleArc() const;
 
@@ -137,5 +137,5 @@
     virtual void changeEvent( QEvent * );
 
-    virtual void drawFrame( QPainter *p );
+    virtual void drawFrame( QPainter * );
     virtual void drawContents( QPainter * ) const;
     virtual void drawFocusIndicator( QPainter * ) const;
@@ -143,8 +143,8 @@
     void invalidateCache();
 
-    virtual void drawScale( QPainter *, 
+    virtual void drawScale( QPainter *,
         const QPointF &center, double radius ) const;
 
-    virtual void drawScaleContents( QPainter *painter, 
+    virtual void drawScaleContents( QPainter *painter,
         const QPointF &center, double radius ) const;
 
Index: trunk/BNC/qwt/qwt_dial_needle.cpp
===================================================================
--- trunk/BNC/qwt/qwt_dial_needle.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_dial_needle.cpp	(revision 9383)
@@ -14,4 +14,5 @@
 #include <qapplication.h>
 #include <qpainter.h>
+#include <qpainterpath.h>
 
 #if QT_VERSION < 0x040601
@@ -67,5 +68,5 @@
 }
 
-static void qwtDrawShadedPointer( QPainter *painter, 
+static void qwtDrawShadedPointer( QPainter *painter,
     const QColor &lightColor, const QColor &darkColor,
     double length, double width )
@@ -171,8 +172,8 @@
 
     QColor color[4];
-    color[0] = darkColor.light( 100 + colorOffset );
-    color[1] = darkColor.dark( 100 + colorOffset );
-    color[2] = lightColor.light( 100 + colorOffset );
-    color[3] = lightColor.dark( 100 + colorOffset );
+    color[0] = darkColor.lighter( 100 + colorOffset );
+    color[1] = darkColor.darker( 100 + colorOffset );
+    color[2] = lightColor.lighter( 100 + colorOffset );
+    color[3] = lightColor.darker( 100 + colorOffset );
 
     painter->setPen( Qt::NoPen );
@@ -223,6 +224,6 @@
   \param colorGroup Color group, used for painting
 */
-void QwtDialNeedle::draw( QPainter *painter, 
-    const QPointF &center, double length, double direction, 
+void QwtDialNeedle::draw( QPainter *painter,
+    const QPointF &center, double length, double direction,
     QPalette::ColorGroup colorGroup ) const
 {
@@ -316,5 +317,5 @@
  \param colorGroup Color group, used for painting
 */
-void QwtDialSimpleNeedle::drawNeedle( QPainter *painter, 
+void QwtDialSimpleNeedle::drawNeedle( QPainter *painter,
     double length, QPalette::ColorGroup colorGroup ) const
 {
@@ -327,5 +328,5 @@
             width = qMax(length * 0.06, 6.0);
 
-        qwtDrawArrowNeedle( painter, 
+        qwtDrawArrowNeedle( painter,
             palette(), colorGroup, length, width );
 
@@ -336,8 +337,8 @@
         if ( width <= 0.0 )
             width = 5.0;
-        
+
         QPen pen ( palette().brush( colorGroup, QPalette::Mid ), width );
         pen.setCapStyle( Qt::FlatCap );
-    
+
         painter->setPen( pen );
         painter->drawLine( QPointF( 0.0, 0.0 ), QPointF( length, 0.0 ) );
@@ -373,5 +374,5 @@
     \param colorGroup Color group, used for painting
 */
-void QwtCompassMagnetNeedle::drawNeedle( QPainter *painter, 
+void QwtCompassMagnetNeedle::drawNeedle( QPainter *painter,
     double length, QPalette::ColorGroup colorGroup ) const
 {
@@ -386,15 +387,15 @@
 
         qwtDrawShadedPointer( painter,
-            dark.light( 100 + colorOffset ),
-            dark.dark( 100 + colorOffset ),
+            dark.lighter( 100 + colorOffset ),
+            dark.darker( 100 + colorOffset ),
             length, width );
-        
+
         painter->rotate( 180.0 );
-    
+
         qwtDrawShadedPointer( painter,
-            light.light( 100 + colorOffset ),
-            light.dark( 100 + colorOffset ),
+            light.lighter( 100 + colorOffset ),
+            light.darker( 100 + colorOffset ),
             length, width );
-        
+
         const QBrush baseBrush = palette().brush( colorGroup, QPalette::Base );
         drawKnob( painter, width, baseBrush, true );
@@ -431,5 +432,5 @@
  \param colorGroup Color group, used for painting
 */
-void QwtCompassWindArrow::drawNeedle( QPainter *painter, 
+void QwtCompassWindArrow::drawNeedle( QPainter *painter,
     double length, QPalette::ColorGroup colorGroup ) const
 {
Index: trunk/BNC/qwt/qwt_dial_needle.h
===================================================================
--- trunk/BNC/qwt/qwt_dial_needle.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_dial_needle.h	(revision 9383)
@@ -36,5 +36,5 @@
 
     virtual void draw( QPainter *painter, const QPointF &center,
-        double length, double direction, 
+        double length, double direction,
         QPalette::ColorGroup = QPalette::Active ) const;
 
@@ -44,7 +44,7 @@
 
       The origin of the needle is at position (0.0, 0.0 )
-      pointing in direction 0.0 ( = east ). 
+      pointing in direction 0.0 ( = east ).
 
-      The painter is already initialized with translation and 
+      The painter is already initialized with translation and
       rotation.
 
@@ -55,8 +55,8 @@
       \sa setPalette(), palette()
     */
-    virtual void drawNeedle( QPainter *painter, 
+    virtual void drawNeedle( QPainter *painter,
         double length, QPalette::ColorGroup colorGroup ) const = 0;
 
-    virtual void drawKnob( QPainter *, double width, 
+    virtual void drawKnob( QPainter *, double width,
         const QBrush &, bool sunken ) const;
 
@@ -133,5 +133,5 @@
         TriangleStyle,
 
-        //! A thin needle 
+        //! A thin needle
         ThinStyle
     };
@@ -141,5 +141,5 @@
 
 protected:
-    virtual void drawNeedle( QPainter *, 
+    virtual void drawNeedle( QPainter *,
         double length, QPalette::ColorGroup ) const;
 
@@ -178,5 +178,5 @@
 
 protected:
-    virtual void drawNeedle( QPainter *, 
+    virtual void drawNeedle( QPainter *,
         double length, QPalette::ColorGroup ) const;
 
@@ -185,3 +185,3 @@
 };
 
-#endif 
+#endif
Index: trunk/BNC/qwt/qwt_dyngrid_layout.cpp
===================================================================
--- trunk/BNC/qwt/qwt_dyngrid_layout.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_dyngrid_layout.cpp	(revision 9383)
@@ -126,5 +126,5 @@
 }
 
-/*! 
+/*!
   \brief Add an item to the next free position.
   \param item Layout item
@@ -248,7 +248,7 @@
 
 /*!
-  \brief Calculate the number of columns for a given width. 
-
-  The calculation tries to use as many columns as possible 
+  \brief Calculate the number of columns for a given width.
+
+  The calculation tries to use as many columns as possible
   ( limited by maxColumns() )
 
@@ -264,5 +264,5 @@
 
     uint maxColumns = itemCount();
-    if ( d_data->maxColumns > 0 ) 
+    if ( d_data->maxColumns > 0 )
         maxColumns = qMin( d_data->maxColumns, maxColumns );
 
Index: trunk/BNC/qwt/qwt_dyngrid_layout.h
===================================================================
--- trunk/BNC/qwt/qwt_dyngrid_layout.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_dyngrid_layout.h	(revision 9383)
@@ -29,6 +29,6 @@
     Q_OBJECT
 public:
-    explicit QwtDynGridLayout( QWidget *, int margin = 0, int space = -1 );
-    explicit QwtDynGridLayout( int space = -1 );
+    explicit QwtDynGridLayout( QWidget *, int margin = 0, int spacing = -1 );
+    explicit QwtDynGridLayout( int spacing = -1 );
 
     virtual ~QwtDynGridLayout();
@@ -36,5 +36,5 @@
     virtual void invalidate();
 
-    void setMaxColumns( uint maxCols );
+    void setMaxColumns( uint maxColumns );
     uint maxColumns() const;
 
@@ -50,5 +50,5 @@
     void setExpandingDirections( Qt::Orientations );
     virtual Qt::Orientations expandingDirections() const;
-    QList<QRect> layoutItems( const QRect &, uint numCols ) const;
+    QList<QRect> layoutItems( const QRect &, uint numColumns ) const;
 
     virtual int maxItemWidth() const;
@@ -68,12 +68,12 @@
 protected:
 
-    void layoutGrid( uint numCols,
+    void layoutGrid( uint numColumns,
         QVector<int>& rowHeight, QVector<int>& colWidth ) const;
-    void stretchGrid( const QRect &rect, uint numCols,
+    void stretchGrid( const QRect &rect, uint numColumns,
         QVector<int>& rowHeight, QVector<int>& colWidth ) const;
 
 private:
     void init();
-    int maxRowWidth( int numCols ) const;
+    int maxRowWidth( int numColumns ) const;
 
     class PrivateData;
Index: trunk/BNC/qwt/qwt_event_pattern.cpp
===================================================================
--- trunk/BNC/qwt/qwt_event_pattern.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_event_pattern.cpp	(revision 9383)
@@ -106,5 +106,5 @@
   \sa QMouseEvent
 */
-void QwtEventPattern::setMousePattern( MousePatternCode pattern, 
+void QwtEventPattern::setMousePattern( MousePatternCode pattern,
     Qt::MouseButton button, Qt::KeyboardModifiers modifiers )
 {
@@ -125,5 +125,5 @@
   \sa QKeyEvent
 */
-void QwtEventPattern::setKeyPattern( KeyPatternCode pattern, 
+void QwtEventPattern::setKeyPattern( KeyPatternCode pattern,
     int key, Qt::KeyboardModifiers modifiers )
 {
@@ -186,5 +186,5 @@
   \sa keyMatch()
 */
-bool QwtEventPattern::mouseMatch( MousePatternCode code, 
+bool QwtEventPattern::mouseMatch( MousePatternCode code,
     const QMouseEvent *event ) const
 {
@@ -232,5 +232,5 @@
   \sa mouseMatch()
 */
-bool QwtEventPattern::keyMatch( KeyPatternCode code, 
+bool QwtEventPattern::keyMatch( KeyPatternCode code,
     const QKeyEvent *event ) const
 {
Index: trunk/BNC/qwt/qwt_event_pattern.h
===================================================================
--- trunk/BNC/qwt/qwt_event_pattern.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_event_pattern.h	(revision 9383)
@@ -44,10 +44,10 @@
     enum MousePatternCode
     {
-        /*! 
-          The default setting for 1, 2 and 3 button mice is:
-
-          - Qt::LeftButton 
-          - Qt::LeftButton 
-          - Qt::LeftButton 
+        /*!
+          The default setting for 1, 2 and 3 button mice is:
+
+          - Qt::LeftButton
+          - Qt::LeftButton
+          - Qt::LeftButton
          */
         MouseSelect1,
@@ -150,5 +150,5 @@
     public:
         //! Constructor
-        MousePattern( Qt::MouseButton btn = Qt::NoButton, 
+        MousePattern( Qt::MouseButton btn = Qt::NoButton,
                 Qt::KeyboardModifiers modifierCodes = Qt::NoModifier ):
             button( btn ),
@@ -157,5 +157,5 @@
         }
 
-        //! Button 
+        //! Button
         Qt::MouseButton button;
 
@@ -169,5 +169,5 @@
     public:
         //! Constructor
-        KeyPattern( int keyCode = Qt::Key_unknown, 
+        KeyPattern( int keyCode = Qt::Key_unknown,
                 Qt::KeyboardModifiers modifierCodes = Qt::NoModifier ):
             key( keyCode ),
@@ -189,9 +189,9 @@
     void initKeyPattern();
 
-    void setMousePattern( MousePatternCode, Qt::MouseButton button, 
+    void setMousePattern( MousePatternCode, Qt::MouseButton button,
         Qt::KeyboardModifiers = Qt::NoModifier );
 
-    void setKeyPattern( KeyPatternCode, int keyCode, 
-        Qt::KeyboardModifiers modifierCodes = Qt::NoModifier );
+    void setKeyPattern( KeyPatternCode, int key,
+        Qt::KeyboardModifiers modifiers = Qt::NoModifier );
 
     void setMousePattern( const QVector<MousePattern> & );
Index: trunk/BNC/qwt/qwt_global.h
===================================================================
--- trunk/BNC/qwt/qwt_global.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_global.h	(revision 9383)
@@ -15,6 +15,6 @@
 // QWT_VERSION is (major << 16) + (minor << 8) + patch.
 
-#define QWT_VERSION       0x060104
-#define QWT_VERSION_STR   "6.1.4"
+#define QWT_VERSION       0x060106
+#define QWT_VERSION_STR   "6.1.6"
 
 #if defined(_MSC_VER) /* MSVC Compiler */
@@ -27,8 +27,8 @@
 #ifdef QWT_DLL
 
-#if defined(QWT_MAKEDLL)     // create a Qwt DLL library 
+#if defined(QWT_MAKEDLL)     // create a Qwt DLL library
 #define QWT_EXPORT Q_DECL_EXPORT
 #else                        // use a Qwt DLL library
-#define QWT_EXPORT Q_DECL_IMPORT 
+#define QWT_EXPORT Q_DECL_IMPORT
 #endif
 
@@ -39,3 +39,3 @@
 #endif
 
-#endif 
+#endif
Index: trunk/BNC/qwt/qwt_graphic.cpp
===================================================================
--- trunk/BNC/qwt/qwt_graphic.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_graphic.cpp	(revision 9383)
@@ -38,5 +38,5 @@
 }
 
-static QRectF qwtStrokedPathRect( 
+static QRectF qwtStrokedPathRect(
     const QPainter *painter, const QPainterPath &path )
 {
@@ -64,6 +64,6 @@
 }
 
-static inline void qwtExecCommand( 
-    QPainter *painter, const QwtPainterCommand &cmd, 
+static inline void qwtExecCommand(
+    QPainter *painter, const QwtPainterCommand &cmd,
     QwtGraphic::RenderHints renderHints,
     const QTransform &transform,
@@ -122,5 +122,5 @@
         {
             const QwtPainterCommand::ImageData *data = cmd.imageData();
-            painter->drawImage( data->rect, data->image, 
+            painter->drawImage( data->rect, data->image,
                 data->subRect, data->flags );
             break;
@@ -130,17 +130,17 @@
             const QwtPainterCommand::StateData *data = cmd.stateData();
 
-            if ( data->flags & QPaintEngine::DirtyPen ) 
+            if ( data->flags & QPaintEngine::DirtyPen )
                 painter->setPen( data->pen );
 
-            if ( data->flags & QPaintEngine::DirtyBrush ) 
+            if ( data->flags & QPaintEngine::DirtyBrush )
                 painter->setBrush( data->brush );
 
-            if ( data->flags & QPaintEngine::DirtyBrushOrigin ) 
+            if ( data->flags & QPaintEngine::DirtyBrushOrigin )
                 painter->setBrushOrigin( data->brushOrigin );
 
-            if ( data->flags & QPaintEngine::DirtyFont ) 
+            if ( data->flags & QPaintEngine::DirtyFont )
                 painter->setFont( data->font );
 
-            if ( data->flags & QPaintEngine::DirtyBackground ) 
+            if ( data->flags & QPaintEngine::DirtyBackground )
             {
                 painter->setBackgroundMode( data->backgroundMode );
@@ -148,24 +148,24 @@
             }
 
-            if ( data->flags & QPaintEngine::DirtyTransform ) 
+            if ( data->flags & QPaintEngine::DirtyTransform )
             {
                 painter->setTransform( data->transform * transform );
             }
 
-            if ( data->flags & QPaintEngine::DirtyClipEnabled ) 
+            if ( data->flags & QPaintEngine::DirtyClipEnabled )
                 painter->setClipping( data->isClipEnabled );
 
-            if ( data->flags & QPaintEngine::DirtyClipRegion) 
+            if ( data->flags & QPaintEngine::DirtyClipRegion)
             {
-                painter->setClipRegion( data->clipRegion, 
+                painter->setClipRegion( data->clipRegion,
                     data->clipOperation );
             }
 
-            if ( data->flags & QPaintEngine::DirtyClipPath ) 
+            if ( data->flags & QPaintEngine::DirtyClipPath )
             {
                 painter->setClipPath( data->clipPath, data->clipOperation );
             }
 
-            if ( data->flags & QPaintEngine::DirtyHints) 
+            if ( data->flags & QPaintEngine::DirtyHints)
             {
                 const QPainter::RenderHints hints = data->renderHints;
@@ -187,8 +187,8 @@
             }
 
-            if ( data->flags & QPaintEngine::DirtyCompositionMode) 
+            if ( data->flags & QPaintEngine::DirtyCompositionMode)
                 painter->setCompositionMode( data->compositionMode );
 
-            if ( data->flags & QPaintEngine::DirtyOpacity) 
+            if ( data->flags & QPaintEngine::DirtyOpacity)
                 painter->setOpacity( data->opacity );
 
@@ -210,5 +210,5 @@
     }
 
-    PathInfo( const QRectF &pointRect, 
+    PathInfo( const QRectF &pointRect,
             const QRectF &boundingRect, bool scalablePen ):
         d_pointRect( pointRect ),
@@ -247,5 +247,5 @@
     }
 
-    inline double scaleFactorX( const QRectF& pathRect, 
+    inline double scaleFactorX( const QRectF& pathRect,
         const QRectF &targetRect, bool scalePens ) const
     {
@@ -258,5 +258,5 @@
         const double r = qAbs( pathRect.right() - p0.x() );
 
-        const double w = 2.0 * qMin( l, r ) 
+        const double w = 2.0 * qMin( l, r )
             * targetRect.width() / pathRect.width();
 
@@ -268,5 +268,5 @@
         else
         {
-            const double pw = qMax( 
+            const double pw = qMax(
                 qAbs( d_boundingRect.left() - d_pointRect.left() ),
                 qAbs( d_boundingRect.right() - d_pointRect.right() ) );
@@ -278,5 +278,5 @@
     }
 
-    inline double scaleFactorY( const QRectF& pathRect, 
+    inline double scaleFactorY( const QRectF& pathRect,
         const QRectF &targetRect, bool scalePens ) const
     {
@@ -289,5 +289,5 @@
         const double b = qAbs( pathRect.bottom() - p0.y() );
 
-        const double h = 2.0 * qMin( t, b ) 
+        const double h = 2.0 * qMin( t, b )
             * targetRect.height() / pathRect.height();
 
@@ -299,5 +299,5 @@
         else
         {
-            const double pw = 
+            const double pw =
                 qMax( qAbs( d_boundingRect.top() - d_pointRect.top() ),
                 qAbs( d_boundingRect.bottom() - d_pointRect.bottom() ) );
@@ -352,5 +352,5 @@
   \brief Copy constructor
 
-  \param other Source 
+  \param other Source
   \sa operator=()
  */
@@ -371,5 +371,5 @@
   \brief Assignment operator
 
-  \param other Source 
+  \param other Source
   \return A reference of this object
  */
@@ -383,8 +383,8 @@
 
 /*!
-  \brief Clear all stored commands 
+  \brief Clear all stored commands
   \sa isNull()
  */
-void QwtGraphic::reset() 
+void QwtGraphic::reset()
 {
     d_data->commands.clear();
@@ -460,5 +460,5 @@
 
 /*!
-  The control point rectangle is the bounding rectangle 
+  The control point rectangle is the bounding rectangle
   of all control points of the paths and the target
   rectangles of the images/pixmaps.
@@ -478,8 +478,8 @@
   \brief Calculate the target rectangle for scaling the graphic
 
-  \param sx Horizontal scaling factor 
-  \param sy Vertical scaling factor 
-
-  \note In case of paths that are painted with a cosmetic pen 
+  \param sx Horizontal scaling factor
+  \param sy Vertical scaling factor
+
+  \note In case of paths that are painted with a cosmetic pen
         ( see QPen::isCosmetic() ) the target rectangle is different to
         multiplying the bounding rectangle.
@@ -500,5 +500,5 @@
     for ( int i = 0; i < d_data->pathInfos.size(); i++ )
     {
-        rect |= d_data->pathInfos[i].scaledBoundingRect( sx, sy, 
+        rect |= d_data->pathInfos[i].scaledBoundingRect( sx, sy,
             !d_data->renderHints.testFlag( RenderPensUnscaled ) );
     }
@@ -519,9 +519,9 @@
   The default size is used in all methods rendering the graphic,
   where no size is explicitly specified. Assigning an empty size
-  means, that the default size will be calculated from the bounding 
+  means, that the default size will be calculated from the bounding
   rectangle.
 
   The default setting is an empty size.
-    
+
   \param size Default size
 
@@ -544,5 +544,5 @@
 
   The default size is used in all methods rendering the graphic,
-  where no size is explicitly specified. 
+  where no size is explicitly specified.
 
   \return Default size
@@ -575,5 +575,5 @@
     for ( int i = 0; i < numCommands; i++ )
     {
-        qwtExecCommand( painter, commands[i], 
+        qwtExecCommand( painter, commands[i],
             d_data->renderHints, transform, d_data->initialTransform );
     }
@@ -592,5 +592,5 @@
   \param aspectRatioMode Mode how to scale - See Qt::AspectRatioMode
  */
-void QwtGraphic::render( QPainter *painter, const QSizeF &size, 
+void QwtGraphic::render( QPainter *painter, const QSizeF &size,
     Qt::AspectRatioMode aspectRatioMode ) const
 {
@@ -608,5 +608,5 @@
   \param aspectRatioMode Mode how to scale - See Qt::AspectRatioMode
  */
-void QwtGraphic::render( QPainter *painter, const QRectF &rect, 
+void QwtGraphic::render( QPainter *painter, const QRectF &rect,
     Qt::AspectRatioMode aspectRatioMode ) const
 {
@@ -614,5 +614,5 @@
         return;
 
-    double sx = 1.0; 
+    double sx = 1.0;
     double sy = 1.0;
 
@@ -623,5 +623,5 @@
         sy = rect.height() / d_data->pointRect.height();
 
-    const bool scalePens = 
+    const bool scalePens =
         !d_data->renderHints.testFlag( RenderPensUnscaled );
 
@@ -630,5 +630,5 @@
         const PathInfo info = d_data->pathInfos[i];
 
-        const double ssx = info.scaleFactorX( 
+        const double ssx = info.scaleFactorX(
             d_data->pointRect, rect, scalePens );
 
@@ -636,5 +636,5 @@
             sx = qMin( sx, ssx );
 
-        const double ssy = info.scaleFactorY( 
+        const double ssy = info.scaleFactorY(
             d_data->pointRect, rect, scalePens );
 
@@ -666,5 +666,5 @@
     {
         // we don't want to scale pens according to sx/sy,
-        // but we want to apply the scaling from the 
+        // but we want to apply the scaling from the
         // painter transformation later
 
@@ -690,8 +690,8 @@
   \param painter Qt painter
   \param pos Reference point, where to render
-  \param alignment Flags how to align the target rectangle 
+  \param alignment Flags how to align the target rectangle
                    to pos.
  */
-void QwtGraphic::render( QPainter *painter, 
+void QwtGraphic::render( QPainter *painter,
     const QPointF &pos, Qt::Alignment alignment ) const
 {
@@ -729,8 +729,8 @@
 /*!
   \brief Convert the graphic to a QPixmap
-    
+
   All pixels of the pixmap get initialized by Qt::transparent
   before the graphic is scaled and rendered on it.
-    
+
   The size of the pixmap is the default size ( ceiled to integers )
   of the graphic.
@@ -738,5 +738,5 @@
   \return The graphic as pixmap in default size
   \sa defaultSize(), toImage(), render()
- */ 
+ */
 QPixmap QwtGraphic::toPixmap() const
 {
@@ -819,5 +819,5 @@
 /*!
   \brief Convert the graphic to a QImage
-    
+
   All pixels of the image get initialized by 0 ( transparent )
   before the graphic is scaled and rendered on it.
@@ -827,5 +827,5 @@
   The size of the image is the default size ( ceiled to integers )
   of the graphic.
-    
+
   \return The graphic as image in default size
   \sa defaultSize(), toPixmap(), render()
@@ -874,5 +874,5 @@
         QRectF boundingRect = pointRect;
 
-        if ( painter->pen().style() != Qt::NoPen 
+        if ( painter->pen().style() != Qt::NoPen
             && painter->pen().brush().style() != Qt::NoBrush )
         {
@@ -883,5 +883,5 @@
         updateBoundingRect( boundingRect );
 
-        d_data->pathInfos += PathInfo( pointRect, 
+        d_data->pathInfos += PathInfo( pointRect,
             boundingRect, qwtHasScalablePen( painter ) );
     }
@@ -897,5 +897,5 @@
   \sa QPaintEngine::drawPixmap()
 */
-void QwtGraphic::drawPixmap( const QRectF &rect, 
+void QwtGraphic::drawPixmap( const QRectF &rect,
     const QPixmap &pixmap, const QRectF &subRect )
 {
@@ -997,6 +997,6 @@
         return;
 
-    // to calculate a proper bounding rectangle we don't simply copy 
-    // the commands. 
+    // to calculate a proper bounding rectangle we don't simply copy
+    // the commands.
 
     const QwtPainterCommand *cmds = commands.constData();
Index: trunk/BNC/qwt/qwt_graphic.h
===================================================================
--- trunk/BNC/qwt/qwt_graphic.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_graphic.h	(revision 9383)
@@ -37,19 +37,19 @@
     - QSvgRenderer/QSvgGenerator\n
       Unfortunately QSvgRenderer hides to much information about
-      its nodes in internal APIs, that are necessary for proper 
-      layout calculations. Also it is derived from QObject and 
+      its nodes in internal APIs, that are necessary for proper
+      layout calculations. Also it is derived from QObject and
       can't be copied like QImage/QPixmap.
 
     QwtGraphic maps all scalable drawing primitives to a QPainterPath
-    and stores them together with the painter state changes 
-    ( pen, brush, transformation ... ) in a list of QwtPaintCommands. 
-    For being a complete QPaintDevice it also stores pixmaps or images, 
-    what is somehow against the idea of the class, because these objects 
+    and stores them together with the painter state changes
+    ( pen, brush, transformation ... ) in a list of QwtPaintCommands.
+    For being a complete QPaintDevice it also stores pixmaps or images,
+    what is somehow against the idea of the class, because these objects
     can't be scaled without a loss in quality.
 
     The main issue about scaling a QwtGraphic object are the pens used for
-    drawing the outlines of the painter paths. While non cosmetic pens 
-    ( QPen::isCosmetic() ) are scaled with the same ratio as the path, 
-    cosmetic pens have a fixed width. A graphic might have paths with 
+    drawing the outlines of the painter paths. While non cosmetic pens
+    ( QPen::isCosmetic() ) are scaled with the same ratio as the path,
+    cosmetic pens have a fixed width. A graphic might have paths with
     different pens - cosmetic and non-cosmetic.
 
@@ -58,5 +58,5 @@
     - control point rectangle\n
       The control point rectangle is the bounding rectangle of all
-      control point rectangles of the painter paths, or the target 
+      control point rectangles of the painter paths, or the target
       rectangle of the pixmaps/images.
 
@@ -65,7 +65,7 @@
       what is needed for rendering the outline with an unscaled pen.
 
-    Because the offset for drawing the outline depends on the shape 
-    of the painter path ( the peak of a triangle is different than the flat side ) 
-    scaling with a fixed aspect ratio always needs to be calculated from the 
+    Because the offset for drawing the outline depends on the shape
+    of the painter path ( the peak of a triangle is different than the flat side )
+    scaling with a fixed aspect ratio always needs to be calculated from the
     control point rectangle.
 
@@ -75,5 +75,5 @@
 {
 public:
-    /*! 
+    /*!
         Hint how to render a graphic
         \sa setRenderHint(), testRenderHint()
@@ -82,5 +82,5 @@
     {
         /*!
-           When rendering a QwtGraphic a specific scaling between 
+           When rendering a QwtGraphic a specific scaling between
            the controlPointRect() and the coordinates of the target rectangle
            is set up internally in render().
@@ -96,5 +96,5 @@
     };
 
-    /*! 
+    /*!
         \brief Render hints
 
@@ -117,8 +117,8 @@
     void render( QPainter * ) const;
 
-    void render( QPainter *, const QSizeF &, 
+    void render( QPainter *, const QSizeF &,
             Qt::AspectRatioMode = Qt::IgnoreAspectRatio  ) const;
 
-    void render( QPainter *, const QRectF &, 
+    void render( QPainter *, const QRectF &,
             Qt::AspectRatioMode = Qt::IgnoreAspectRatio  ) const;
 
@@ -126,10 +126,10 @@
         Qt::Alignment = Qt::AlignTop | Qt::AlignLeft ) const;
 
-    QPixmap toPixmap() const; 
-    QPixmap toPixmap( const QSize &, 
+    QPixmap toPixmap() const;
+    QPixmap toPixmap( const QSize &,
         Qt::AspectRatioMode = Qt::IgnoreAspectRatio  ) const;
 
-    QImage toImage() const; 
-    QImage toImage( const QSize &, 
+    QImage toImage() const;
+    QImage toImage( const QSize &,
         Qt::AspectRatioMode = Qt::IgnoreAspectRatio  ) const;
 
@@ -144,5 +144,5 @@
     void setDefaultSize( const QSizeF & );
     QSizeF defaultSize() const;
-    
+
     void setRenderHint( RenderHint, bool on = true );
     bool testRenderHint( RenderHint ) const;
Index: trunk/BNC/qwt/qwt_interval.cpp
===================================================================
--- trunk/BNC/qwt/qwt_interval.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_interval.cpp	(revision 9383)
@@ -131,7 +131,7 @@
 }
 
-/*! 
+/*!
   \brief Intersect 2 intervals
-  
+
   \param other Interval to be intersect with
   \return Intersection
@@ -198,5 +198,5 @@
 }
 
-/*! 
+/*!
   \brief Unite this interval with the given interval.
 
@@ -210,5 +210,5 @@
 }
 
-/*! 
+/*!
   \brief Intersect this interval with the given interval.
 
Index: trunk/BNC/qwt/qwt_interval.h
===================================================================
--- trunk/BNC/qwt/qwt_interval.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_interval.h	(revision 9383)
@@ -28,5 +28,5 @@
 public:
     /*!
-      Flag indicating if a border is included or excluded 
+      Flag indicating if a border is included or excluded
       \sa setBorderFlags(), borderFlags()
     */
@@ -58,5 +58,5 @@
     QwtInterval normalized() const;
     QwtInterval inverted() const;
-    QwtInterval limited( double minValue, double maxValue ) const;
+    QwtInterval limited( double lowerBound, double upperBound ) const;
 
     bool operator==( const QwtInterval & ) const;
@@ -232,5 +232,5 @@
 /*!
    \brief Intersection of two intervals
- 
+
    \param other Interval to intersect with
    \return Intersection of this and other
@@ -258,5 +258,5 @@
 }
 
-/*! 
+/*!
    \brief Compare two intervals
 
@@ -270,5 +270,5 @@
            ( d_borderFlags == other.d_borderFlags );
 }
-/*! 
+/*!
    \brief Compare two intervals
 
Index: trunk/BNC/qwt/qwt_interval_symbol.cpp
===================================================================
--- trunk/BNC/qwt/qwt_interval_symbol.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_interval_symbol.cpp	(revision 9383)
@@ -69,5 +69,5 @@
 
 //! \brief Assignment operator
-QwtIntervalSymbol &QwtIntervalSymbol::operator=( 
+QwtIntervalSymbol &QwtIntervalSymbol::operator=(
     const QwtIntervalSymbol &other )
 {
@@ -77,5 +77,5 @@
 
 //! \brief Compare two symbols
-bool QwtIntervalSymbol::operator==( 
+bool QwtIntervalSymbol::operator==(
     const QwtIntervalSymbol &other ) const
 {
@@ -84,5 +84,5 @@
 
 //! \brief Compare two symbols
-bool QwtIntervalSymbol::operator!=( 
+bool QwtIntervalSymbol::operator!=(
     const QwtIntervalSymbol &other ) const
 {
@@ -153,7 +153,7 @@
 }
 
-/*! 
+/*!
   Build and assign a pen
-    
+
   In Qt5 the default pen width is 1.0 ( 0.0 in Qt4 ) what makes it
   non cosmetic ( see QPen::isCosmetic() ). This method has been introduced
@@ -163,10 +163,10 @@
   \param width Pen width
   \param style Pen style
-    
+
   \sa pen(), brush()
- */ 
-void QwtIntervalSymbol::setPen( const QColor &color, 
+ */
+void QwtIntervalSymbol::setPen( const QColor &color,
     qreal width, Qt::PenStyle style )
-{   
+{
     setPen( QPen( color, width, style ) );
 }
@@ -222,5 +222,5 @@
             if ( d_data->width > pw )
             {
-                if ( ( orientation == Qt::Horizontal ) 
+                if ( ( orientation == Qt::Horizontal )
                     && ( p1.y() == p2.y() ) )
                 {
@@ -233,5 +233,5 @@
                         p2.x(), y, p2.x(), y + sw );
                 }
-                else if ( ( orientation == Qt::Vertical ) 
+                else if ( ( orientation == Qt::Vertical )
                     && ( p1.x() == p2.x() ) )
                 {
@@ -274,5 +274,5 @@
             else
             {
-                if ( ( orientation == Qt::Horizontal ) 
+                if ( ( orientation == Qt::Horizontal )
                     && ( p1.y() == p2.y() ) )
                 {
Index: trunk/BNC/qwt/qwt_interval_symbol.h
===================================================================
--- trunk/BNC/qwt/qwt_interval_symbol.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_interval_symbol.h	(revision 9383)
@@ -66,5 +66,5 @@
     int width() const;
 
-    void setBrush( const QBrush& b );
+    void setBrush( const QBrush & );
     const QBrush& brush() const;
 
@@ -80,5 +80,4 @@
 
 private:
-
     class PrivateData;
     PrivateData* d_data;
Index: trunk/BNC/qwt/qwt_knob.cpp
===================================================================
--- trunk/BNC/qwt/qwt_knob.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_knob.cpp	(revision 9383)
@@ -120,5 +120,5 @@
     setValue( 0.0 );
 
-    setSizePolicy( QSizePolicy::MinimumExpanding, 
+    setSizePolicy( QSizePolicy::MinimumExpanding,
         QSizePolicy::MinimumExpanding );
 }
@@ -131,5 +131,5 @@
 
 /*!
-  \brief Set the knob type 
+  \brief Set the knob type
 
   \param knobStyle Knob type
@@ -186,5 +186,5 @@
   have to be set using setNumTurns().
 
-  The default angle is 270 degrees. 
+  The default angle is 270 degrees.
 
   \sa totalAngle(), setNumTurns()
@@ -206,5 +206,5 @@
 }
 
-/*! 
+/*!
   \return the total angle
   \sa setTotalAngle(), setNumTurns(), numTurns()
@@ -223,5 +223,5 @@
   \sa numTurns(), totalAngle(), setTotalAngle()
 */
-  
+
 void QwtKnob::setNumTurns( int numTurns )
 {
@@ -245,5 +245,5 @@
 
 /*!
-  \return Number of turns. 
+  \return Number of turns.
 
   When the total angle is below 360° numTurns() is ceiled to 1.
@@ -336,5 +336,5 @@
         r.moveBottom( cr.bottom() - d );
     }
-    else 
+    else
     {
         r.moveCenter( QPoint( r.center().x(), cr.center().y() ) );
@@ -401,5 +401,5 @@
         if ( !wrapping() )
         {
-            const double boundedAngle = 
+            const double boundedAngle =
                 qBound( scaleMap().p1(), angle, scaleMap().p2() );
 
@@ -432,5 +432,5 @@
 }
 
-/*! 
+/*!
   Handle QEvent::StyleChange and QEvent::FontChange;
   \param event Change event
@@ -479,5 +479,5 @@
     drawKnob( &painter, knobRect );
 
-    drawMarker( &painter, knobRect, 
+    drawMarker( &painter, knobRect,
         qwtNormalizeDegrees( scaleMap().transform( value() ) ) );
 
@@ -514,5 +514,5 @@
         gradient.setColorAt( 1.0, c2 );
 
-        pen = QPen( gradient, d_data->borderWidth ); 
+        pen = QPen( gradient, d_data->borderWidth );
     }
 
@@ -525,5 +525,5 @@
             QRadialGradient gradient( knobRect.center(),
                 knobRect.width(), knobRect.topLeft() + QPointF( off, off ) );
-            
+
             gradient.setColorAt( 0.0, palette().color( QPalette::Midlight ) );
             gradient.setColorAt( 1.0, palette().color( QPalette::Button ) );
@@ -553,5 +553,5 @@
         case QwtKnob::Sunken:
         {
-            QLinearGradient gradient( 
+            QLinearGradient gradient(
                 knobRect.topLeft(), knobRect.bottomRight() );
             gradient.setColorAt( 0.0, palette().color( QPalette::Mid ) );
@@ -578,8 +578,8 @@
   \param painter Painter
   \param rect Bounding rectangle of the knob without scale
-  \param angle Angle of the marker in degrees 
+  \param angle Angle of the marker in degrees
                ( clockwise, 0 at the 12 o'clock position )
 */
-void QwtKnob::drawMarker( QPainter *painter, 
+void QwtKnob::drawMarker( QPainter *painter,
     const QRectF &rect, double angle ) const
 {
@@ -608,5 +608,5 @@
         case Nub:
         {
-            const double dotWidth = 
+            const double dotWidth =
                 qMin( double( markerSize ), radius);
 
@@ -614,5 +614,5 @@
             if ( dotCenterDist > 0.0 )
             {
-                const QPointF center( xm - sinA * dotCenterDist, 
+                const QPointF center( xm - sinA * dotCenterDist,
                     ym - cosA * dotCenterDist );
 
@@ -626,5 +626,5 @@
                     qSwap( c1, c2 );
 
-                QLinearGradient gradient( 
+                QLinearGradient gradient(
                     ellipse.topLeft(), ellipse.bottomRight() );
                 gradient.setColorAt( 0.0, c1 );
@@ -640,5 +640,5 @@
         case Dot:
         {
-            const double dotWidth = 
+            const double dotWidth =
                 qMin( double( markerSize ), radius);
 
@@ -646,5 +646,5 @@
             if ( dotCenterDist > 0.0 )
             {
-                const QPointF center( xm - sinA * dotCenterDist, 
+                const QPointF center( xm - sinA * dotCenterDist,
                     ym - cosA * dotCenterDist );
 
@@ -681,5 +681,5 @@
             painter->translate( rect.center() );
             painter->rotate( angle - 90.0 );
-            
+
             QPolygonF polygon;
             polygon += QPointF( re, 0.0 );
@@ -705,5 +705,5 @@
 */
 void QwtKnob::drawFocusIndicator( QPainter *painter ) const
-{       
+{
     const QRect cr = contentsRect();
 
@@ -723,5 +723,5 @@
 
     QwtPainter::drawFocusRect( painter, this, focusRect );
-}  
+}
 
 /*!
@@ -729,5 +729,5 @@
 
   Similar to a QLabel::alignment() the flags decide how
-  to align the knob inside of contentsRect(). 
+  to align the knob inside of contentsRect().
 
   The default setting is Qt::AlignCenter
@@ -758,5 +758,5 @@
   \brief Change the knob's width.
 
-  Setting a fixed value for the diameter of the knob 
+  Setting a fixed value for the diameter of the knob
   is helpful for aligning several knobs in a row.
 
@@ -764,5 +764,5 @@
 
   \sa knobWidth(), setAlignment()
-  \note Modifies the sizePolicy() 
+  \note Modifies the sizePolicy()
 */
 void QwtKnob::setKnobWidth( int width )
@@ -828,5 +828,5 @@
 }
 
-/*! 
+/*!
   \return Marker size
   \sa setMarkerSize()
Index: trunk/BNC/qwt/qwt_knob.h
===================================================================
--- trunk/BNC/qwt/qwt_knob.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_knob.h	(revision 9383)
@@ -26,7 +26,7 @@
   The layout of the knob depends on the knobWidth().
 
-  - width > 0 
+  - width > 0
     The diameter of the knob is fixed and the knob is aligned
-    according to the alignment() flags inside of the contentsRect(). 
+    according to the alignment() flags inside of the contentsRect().
 
   - width <= 0
@@ -36,5 +36,5 @@
   Setting a fixed knobWidth() is helpful to align several knobs with different
   scale labels.
-  
+
   \image html knob.png
 */
@@ -56,5 +56,5 @@
 
 public:
-    /*! 
+    /*!
        \brief Style of the knob surface
 
@@ -72,5 +72,5 @@
         Raised,
 
-        /*! 
+        /*!
           Build a gradient from QPalette::Midlight, QPalette::Button
           and QPalette::Midlight
@@ -78,5 +78,5 @@
         Sunken,
 
-        /*! 
+        /*!
           Build a radial gradient from QPalette::Button
           like it is used for QDial in various Qt styles.
@@ -87,5 +87,5 @@
     /*!
         \brief Marker type
- 
+
         The marker indicates the current value on the knob
         The default setting is a Notch marker.
@@ -93,29 +93,29 @@
         \sa setMarkerStyle(), setMarkerSize()
     */
-    enum MarkerStyle 
-    { 
+    enum MarkerStyle
+    {
         //! Don't paint any marker
         NoMarker = -1,
 
         //! Paint a single tick in QPalette::ButtonText color
-        Tick, 
+        Tick,
 
         //! Paint a triangle in QPalette::ButtonText color
-        Triangle, 
+        Triangle,
 
         //! Paint a circle in QPalette::ButtonText color
-        Dot, 
+        Dot,
 
-        /*! 
+        /*!
           Draw a raised ellipse with a gradient build from
           QPalette::Light and QPalette::Mid
-         */ 
-        Nub, 
+         */
+        Nub,
 
-        /*! 
+        /*!
           Draw a sunken ellipse with a gradient build from
           QPalette::Light and QPalette::Mid
-         */ 
-        Notch 
+         */
+        Notch
     };
 
@@ -138,5 +138,5 @@
     KnobStyle knobStyle() const;
 
-    void setBorderWidth( int bw );
+    void setBorderWidth( int );
     int borderWidth() const;
 
@@ -165,6 +165,6 @@
     virtual void drawFocusIndicator( QPainter * ) const;
 
-    virtual void drawMarker( QPainter *, 
-        const QRectF &, double arc ) const;
+    virtual void drawMarker( QPainter *,
+        const QRectF &, double angle ) const;
 
     virtual double scrolledTo( const QPoint & ) const;
Index: trunk/BNC/qwt/qwt_legend.cpp
===================================================================
--- trunk/BNC/qwt/qwt_legend.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_legend.cpp	(revision 9383)
@@ -50,5 +50,5 @@
 };
 
-void QwtLegendMap::insert( const QVariant &itemInfo, 
+void QwtLegendMap::insert( const QVariant &itemInfo,
     const QList<QWidget *> &widgets )
 {
@@ -142,5 +142,5 @@
 {
 public:
-    LegendView( QWidget *parent ):
+    explicit LegendView( QWidget *parent ):
         QScrollArea( parent )
     {
@@ -296,4 +296,6 @@
     if ( tl )
         tl->setMaxColumns( numColums );
+
+    updateGeometry();
 }
 
@@ -342,5 +344,5 @@
 
 /*!
-  The contents widget is the only child of the viewport of 
+  The contents widget is the only child of the viewport of
   the internal QScrollArea and the parent widget of all legend items.
 
@@ -371,5 +373,5 @@
 
 /*!
-  The contents widget is the only child of the viewport of 
+  The contents widget is the only child of the viewport of
   the internal QScrollArea and the parent widget of all legend items.
 
@@ -386,16 +388,16 @@
 
   \param itemInfo Info for an item
-  \param data List of legend entry attributes for the item
+  \param legendData List of legend entry attributes for the item
  */
-void QwtLegend::updateLegend( const QVariant &itemInfo, 
-    const QList<QwtLegendData> &data )
+void QwtLegend::updateLegend( const QVariant &itemInfo,
+    const QList<QwtLegendData> &legendData )
 {
     QList<QWidget *> widgetList = legendWidgets( itemInfo );
 
-    if ( widgetList.size() != data.size() )
+    if ( widgetList.size() != legendData.size() )
     {
         QLayout *contentsLayout = d_data->view->contentsWidget->layout();
 
-        while ( widgetList.size() > data.size() )
+        while ( widgetList.size() > legendData.size() )
         {
             QWidget *w = widgetList.takeLast();
@@ -410,7 +412,11 @@
         }
 
-        for ( int i = widgetList.size(); i < data.size(); i++ )
-        {
-            QWidget *widget = createWidget( data[i] );
+#if QT_VERSION >= 0x040700
+        widgetList.reserve( legendData.size() );
+#endif
+
+        for ( int i = widgetList.size(); i < legendData.size(); i++ )
+        {
+            QWidget *widget = createWidget( legendData[i] );
 
             if ( contentsLayout )
@@ -441,7 +447,7 @@
         updateTabOrder();
     }
-    
-    for ( int i = 0; i < data.size(); i++ )
-        updateWidget( widgetList[i], data[i] );
+
+    for ( int i = 0; i < legendData.size(); i++ )
+        updateWidget( widgetList[i], legendData[i] );
 }
 
@@ -451,19 +457,19 @@
   The default implementation returns a QwtLegendLabel.
 
-  \param data Attributes of the legend entry
+  \param legendData Attributes of the legend entry
   \return Widget representing data on the legend
-  
+
   \note updateWidget() will called soon after createWidget()
         with the same attributes.
  */
-QWidget *QwtLegend::createWidget( const QwtLegendData &data ) const
-{
-    Q_UNUSED( data );
+QWidget *QwtLegend::createWidget( const QwtLegendData &legendData ) const
+{
+    Q_UNUSED( legendData );
 
     QwtLegendLabel *label = new QwtLegendLabel();
     label->setItemMode( defaultItemMode() );
 
-    connect( label, SIGNAL( clicked() ), SLOT( itemClicked() ) );
-    connect( label, SIGNAL( checked( bool ) ), SLOT( itemChecked( bool ) ) );
+    connect( label, SIGNAL(clicked()), SLOT(itemClicked()) );
+    connect( label, SIGNAL(checked(bool)), SLOT(itemChecked(bool)) );
 
     return label;
@@ -471,19 +477,19 @@
 
 /*!
-  \brief Update the widget 
+  \brief Update the widget
 
   \param widget Usually a QwtLegendLabel
-  \param data Attributes to be displayed
+  \param legendData Attributes to be displayed
 
   \sa createWidget()
   \note When widget is no QwtLegendLabel updateWidget() does nothing.
  */
-void QwtLegend::updateWidget( QWidget *widget, const QwtLegendData &data )
+void QwtLegend::updateWidget( QWidget *widget, const QwtLegendData &legendData )
 {
     QwtLegendLabel *label = qobject_cast<QwtLegendLabel *>( widget );
     if ( label )
     {
-        label->setData( data );
-        if ( !data.value( QwtLegendData::ModeRole ).isValid() )
+        label->setData( legendData );
+        if ( !legendData.value( QwtLegendData::ModeRole ).isValid() )
         {
             // use the default mode, when there is no specific
@@ -541,5 +547,5 @@
 
 /*!
-  Handle QEvent::ChildRemoved andQEvent::LayoutRequest events 
+  Handle QEvent::ChildRemoved andQEvent::LayoutRequest events
   for the contentsWidget().
 
@@ -557,9 +563,15 @@
             case QEvent::ChildRemoved:
             {
-                const QChildEvent *ce = 
+                const QChildEvent *ce =
                     static_cast<const QChildEvent *>(event);
+
                 if ( ce->child()->isWidgetType() )
                 {
-                    QWidget *w = static_cast< QWidget * >( ce->child() );
+                    /*
+                        We are called from the ~QObject and ce->child() is
+                        no widget anymore. But all we need is the address
+                        to remove it from the map.
+                     */
+                    QWidget *w = reinterpret_cast< QWidget * >( ce->child() );
                     d_data->itemMap.removeWidget( w );
                 }
@@ -585,5 +597,5 @@
                     QApplication::postEvent( parentWidget(),
                         new QEvent( QEvent::LayoutRequest ) );
-                }                
+                }
                 break;
             }
@@ -645,9 +657,9 @@
   \param painter Painter
   \param rect Bounding rectangle
-  \param fillBackground When true, fill rect with the widget background 
+  \param fillBackground When true, fill rect with the widget background
 
   \sa renderLegend() is used by QwtPlotRenderer - not by QwtLegend itself
 */
-void QwtLegend::renderLegend( QPainter *painter, 
+void QwtLegend::renderLegend( QPainter *painter,
     const QRectF &rect, bool fillBackground ) const
 {
@@ -664,5 +676,5 @@
     }
 
-    const QwtDynGridLayout *legendLayout = 
+    const QwtDynGridLayout *legendLayout =
         qobject_cast<QwtDynGridLayout *>( contentsWidget()->layout() );
     if ( legendLayout == NULL )
@@ -672,5 +684,5 @@
     getContentsMargins( &left, &top, &right, &bottom );
 
-    QRect layoutRect; 
+    QRect layoutRect;
     layoutRect.setLeft( qCeil( rect.left() ) + left );
     layoutRect.setTop( qCeil( rect.top() ) + top );
@@ -679,5 +691,5 @@
 
     uint numCols = legendLayout->columnsForWidth( layoutRect.width() );
-    QList<QRect> itemRects =
+    const QList<QRect> itemRects =
         legendLayout->layoutItems( layoutRect, numCols );
 
@@ -707,10 +719,10 @@
   \param widget Widget representing a legend entry
   \param rect Bounding rectangle
-  \param fillBackground When true, fill rect with the widget background 
+  \param fillBackground When true, fill rect with the widget background
 
   \note When widget is not derived from QwtLegendLabel renderItem
         does nothing beside the background
 */
-void QwtLegend::renderItem( QPainter *painter, 
+void QwtLegend::renderItem( QPainter *painter,
     const QWidget *widget, const QRectF &rect, bool fillBackground ) const
 {
@@ -733,5 +745,5 @@
 
         const QRectF iconRect( rect.x() + label->margin(),
-            rect.center().y() - 0.5 * sz.height(), 
+            rect.center().y() - 0.5 * sz.height(),
             sz.width(), sz.height() );
 
@@ -743,6 +755,10 @@
         titleRect.setX( iconRect.right() + 2 * label->spacing() );
 
-        painter->setFont( label->font() );
+        QFont labelFont = label->font();
+        labelFont.resolve( QFont::AllPropertiesResolved );
+
+        painter->setFont( labelFont );
         painter->setPen( label->palette().color( QPalette::Text ) );
+
         const_cast< QwtLegendLabel *>( label )->drawText( painter, titleRect );
     }
@@ -795,5 +811,5 @@
     Return the extent, that is needed for the scrollbars
 
-    \param orientation Orientation ( 
+    \param orientation Orientation
     \return The width of the vertical scrollbar for Qt::Horizontal and v.v.
  */
Index: trunk/BNC/qwt/qwt_legend.h
===================================================================
--- trunk/BNC/qwt/qwt_legend.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_legend.h	(revision 9383)
@@ -52,13 +52,13 @@
 
     virtual QSize sizeHint() const;
-    virtual int heightForWidth( int w ) const;
+    virtual int heightForWidth( int width ) const;
 
     QScrollBar *horizontalScrollBar() const;
     QScrollBar *verticalScrollBar() const;
 
-    virtual void renderLegend( QPainter *, 
+    virtual void renderLegend( QPainter *,
         const QRectF &, bool fillBackground ) const;
 
-    virtual void renderItem( QPainter *, 
+    virtual void renderItem( QPainter *,
         const QWidget *, const QRectF &, bool fillBackground ) const;
 
@@ -106,5 +106,5 @@
 protected:
     virtual QWidget *createWidget( const QwtLegendData & ) const;
-    virtual void updateWidget( QWidget *widget, const QwtLegendData &data );
+    virtual void updateWidget( QWidget *widget, const QwtLegendData & );
 
 private:
@@ -115,3 +115,3 @@
 };
 
-#endif 
+#endif
Index: trunk/BNC/qwt/qwt_legend_data.cpp
===================================================================
--- trunk/BNC/qwt/qwt_legend_data.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_legend_data.cpp	(revision 9383)
@@ -124,5 +124,5 @@
         return static_cast<QwtLegendData::Mode>( mode );
     }
-    
+
     return QwtLegendData::ReadOnly;
 }
Index: trunk/BNC/qwt/qwt_legend_data.h
===================================================================
--- trunk/BNC/qwt/qwt_legend_data.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_legend_data.h	(revision 9383)
@@ -22,9 +22,9 @@
 
   QwtLegendData is an abstract container ( like QAbstractModel )
-  to exchange attributes, that are only known between to 
-  the plot item and the legend. 
-  
+  to exchange attributes, that are only known between to
+  the plot item and the legend.
+
   By overloading QwtPlotItem::legendData() any other set of attributes
-  could be used, that can be handled by a modified ( or completely 
+  could be used, that can be handled by a modified ( or completely
   different ) implementation of a legend.
 
@@ -53,11 +53,11 @@
     {
         // The value is a Mode
-        ModeRole, 
+        ModeRole,
 
         // The value is a title
-        TitleRole, 
+        TitleRole,
 
         // The value is an icon
-        IconRole, 
+        IconRole,
 
         // Values < UserRole are reserved for internal use
Index: trunk/BNC/qwt/qwt_legend_label.cpp
===================================================================
--- trunk/BNC/qwt/qwt_legend_label.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_legend_label.cpp	(revision 9383)
@@ -140,5 +140,5 @@
         d_data->isDown = false;
 
-        setFocusPolicy( ( mode != QwtLegendData::ReadOnly ) 
+        setFocusPolicy( ( mode != QwtLegendData::ReadOnly )
             ? Qt::TabFocus : Qt::NoFocus );
         setMargin( ButtonFrame + Margin );
Index: trunk/BNC/qwt/qwt_legend_label.h
===================================================================
--- trunk/BNC/qwt/qwt_legend_label.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_legend_label.h	(revision 9383)
@@ -78,3 +78,3 @@
 };
 
-#endif 
+#endif
Index: trunk/BNC/qwt/qwt_magnifier.cpp
===================================================================
--- trunk/BNC/qwt/qwt_magnifier.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_magnifier.cpp	(revision 9383)
@@ -191,5 +191,5 @@
    \sa getMouseButton()
 */
-void QwtMagnifier::setMouseButton( 
+void QwtMagnifier::setMouseButton(
     Qt::MouseButton button, Qt::KeyboardModifiers modifiers )
 {
@@ -239,5 +239,5 @@
    \sa getZoomInKey(), setZoomOutKey()
 */
-void QwtMagnifier::setZoomInKey( int key, 
+void QwtMagnifier::setZoomInKey( int key,
     Qt::KeyboardModifiers modifiers )
 {
@@ -246,5 +246,5 @@
 }
 
-/*! 
+/*!
    \brief Retrieve the settings of the zoom in key
 
@@ -254,5 +254,5 @@
    \sa setZoomInKey()
 */
-void QwtMagnifier::getZoomInKey( int &key, 
+void QwtMagnifier::getZoomInKey( int &key,
     Qt::KeyboardModifiers &modifiers ) const
 {
@@ -269,5 +269,5 @@
    \sa getZoomOutKey(), setZoomOutKey()
 */
-void QwtMagnifier::setZoomOutKey( int key, 
+void QwtMagnifier::setZoomOutKey( int key,
     Qt::KeyboardModifiers modifiers )
 {
@@ -276,5 +276,5 @@
 }
 
-/*! 
+/*!
    \brief Retrieve the settings of the zoom out key
 
@@ -284,5 +284,5 @@
    \sa setZoomOutKey()
 */
-void QwtMagnifier::getZoomOutKey( int &key, 
+void QwtMagnifier::getZoomOutKey( int &key,
     Qt::KeyboardModifiers &modifiers ) const
 {
@@ -438,5 +438,5 @@
             of 120 (== 15 * 8).
          */
-        double f = qPow( d_data->wheelFactor, 
+        double f = qPow( d_data->wheelFactor,
             qAbs( wheelEvent->delta() / 120.0 ) );
 
Index: trunk/BNC/qwt/qwt_math.h
===================================================================
--- trunk/BNC/qwt/qwt_math.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_math.h	(revision 9383)
@@ -28,5 +28,5 @@
 
 #ifndef M_PI_2
-// For Qt <= 4.8.4 M_PI_2 is not known by MinGW-w64 
+// For Qt <= 4.8.4 M_PI_2 is not known by MinGW-w64
 // when compiling with -std=c++11
 #define M_PI_2 (1.57079632679489661923)
Index: trunk/BNC/qwt/qwt_matrix_raster_data.cpp
===================================================================
--- trunk/BNC/qwt/qwt_matrix_raster_data.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_matrix_raster_data.cpp	(revision 9383)
@@ -82,8 +82,8 @@
    \param axis X, Y or Z axis
    \param interval Interval
-   
+
    \sa QwtRasterData::interval(), setValueMatrix()
 */
-void QwtMatrixRasterData::setInterval( 
+void QwtMatrixRasterData::setInterval(
     Qt::Axis axis, const QwtInterval &interval )
 {
@@ -97,5 +97,5 @@
    The positions of the values are calculated by dividing
    the bounding rectangle of the X/Y intervals into equidistant
-   rectangles ( pixels ). Each value corresponds to the center of 
+   rectangles ( pixels ). Each value corresponds to the center of
    a pixel.
 
@@ -105,5 +105,5 @@
    \sa valueMatrix(), numColumns(), numRows(), setInterval()()
 */
-void QwtMatrixRasterData::setValueMatrix( 
+void QwtMatrixRasterData::setValueMatrix(
     const QVector<double> &values, int numColumns )
 {
@@ -162,15 +162,15 @@
    \brief Calculate the pixel hint
 
-   pixelHint() returns the geometry of a pixel, that can be used 
+   pixelHint() returns the geometry of a pixel, that can be used
    to calculate the resolution and alignment of the plot item, that is
-   representing the data. 
+   representing the data.
 
    - NearestNeighbour\n
-     pixelHint() returns the surrounding pixel of the top left value 
+     pixelHint() returns the surrounding pixel of the top left value
      in the matrix.
 
    - BilinearInterpolation\n
      Returns an empty rectangle recommending
-     to render in target device ( f.e. screen ) resolution. 
+     to render in target device ( f.e. screen ) resolution.
 
    \param area Requested area, ignored
@@ -240,9 +240,9 @@
             const double v22 = d_data->value( row2, col2 );
 
-            const double x2 = xInterval.minValue() + 
+            const double x2 = xInterval.minValue() +
                 ( col2 + 0.5 ) * d_data->dx;
-            const double y2 = yInterval.minValue() + 
+            const double y2 = yInterval.minValue() +
                 ( row2 + 0.5 ) * d_data->dy;
-                
+
             const double rx = ( x2 - x ) / d_data->dx;
             const double ry = ( y2 - y ) / d_data->dy;
Index: trunk/BNC/qwt/qwt_matrix_raster_data.h
===================================================================
--- trunk/BNC/qwt/qwt_matrix_raster_data.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_matrix_raster_data.h	(revision 9383)
@@ -19,5 +19,5 @@
 
   QwtMatrixRasterData implements an interface for a matrix of
-  equidistant values, that can be used by a QwtPlotRasterItem. 
+  equidistant values, that can be used by a QwtPlotRasterItem.
   It implements a couple of resampling algorithms, to provide
   values for positions, that or not on the value matrix.
@@ -39,5 +39,5 @@
 
         /*!
-          Interpolate the value from the distances and values of the 
+          Interpolate the value from the distances and values of the
           4 surrounding values in the matrix,
          */
Index: trunk/BNC/qwt/qwt_null_paintdevice.cpp
===================================================================
--- trunk/BNC/qwt/qwt_null_paintdevice.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_null_paintdevice.cpp	(revision 9383)
@@ -10,4 +10,5 @@
 #include "qwt_null_paintdevice.h"
 #include <qpaintengine.h>
+#include <qpainterpath.h>
 #include <qpixmap.h>
 
@@ -51,13 +52,13 @@
     virtual void drawPolygon(const QPoint *, int , PolygonDrawMode );
 
-    virtual void drawPixmap(const QRectF &, 
+    virtual void drawPixmap(const QRectF &,
         const QPixmap &, const QRectF &);
 
     virtual void drawTextItem(const QPointF &, const QTextItem &);
 
-    virtual void drawTiledPixmap(const QRectF &, 
+    virtual void drawTiledPixmap(const QRectF &,
         const QPixmap &, const QPointF &s);
 
-    virtual void drawImage(const QRectF &, 
+    virtual void drawImage(const QRectF &,
         const QImage &, const QRectF &, Qt::ImageConversionFlags );
 
@@ -65,5 +66,5 @@
     QwtNullPaintDevice *nullDevice();
 };
-    
+
 QwtNullPaintDevice::PaintEngine::PaintEngine():
     QPaintEngine( QPaintEngine::AllFeatures )
@@ -283,5 +284,5 @@
 }
 
-void QwtNullPaintDevice::PaintEngine::drawPixmap( 
+void QwtNullPaintDevice::PaintEngine::drawPixmap(
     const QRectF &rect, const QPixmap &pm, const QRectF &subRect )
 {
@@ -310,5 +311,5 @@
 
 void QwtNullPaintDevice::PaintEngine::drawTiledPixmap(
-    const QRectF &rect, const QPixmap &pixmap, 
+    const QRectF &rect, const QPixmap &pixmap,
     const QPointF &subRect)
 {
@@ -321,5 +322,5 @@
         QPaintEngine::drawTiledPixmap( rect, pixmap, subRect );
         return;
-    }   
+    }
 
     device->drawTiledPixmap( rect, pixmap, subRect );
@@ -327,5 +328,5 @@
 
 void QwtNullPaintDevice::PaintEngine::drawImage(
-    const QRectF &rect, const QImage &image, 
+    const QRectF &rect, const QImage &image,
     const QRectF &subRect, Qt::ImageConversionFlags flags)
 {
@@ -338,11 +339,11 @@
 
 void QwtNullPaintDevice::PaintEngine::updateState(
-    const QPaintEngineState &state)
-{
-    QwtNullPaintDevice *device = nullDevice();
-    if ( device == NULL )
-        return;
-
-    device->updateState( state );
+    const QPaintEngineState &engineState)
+{
+    QwtNullPaintDevice *device = nullDevice();
+    if ( device == NULL )
+        return;
+
+    device->updateState( engineState );
 }
 
@@ -380,5 +381,5 @@
 }
 
-/*! 
+/*!
     \return Render mode
     \sa setMode()
@@ -394,5 +395,5 @@
     if ( d_engine == NULL )
     {
-        QwtNullPaintDevice *that = 
+        QwtNullPaintDevice *that =
             const_cast< QwtNullPaintDevice * >( this );
 
@@ -403,5 +404,5 @@
 }
 
-/*! 
+/*!
     See QPaintDevice::metric()
 
@@ -415,5 +416,5 @@
     int value;
 
-    switch ( deviceMetric ) 
+    switch ( deviceMetric )
     {
         case PdmWidth:
@@ -530,5 +531,5 @@
 //! See QPaintEngine::drawPolygon()
 void QwtNullPaintDevice::drawPolygon(
-    const QPointF *points, int pointCount, 
+    const QPointF *points, int pointCount,
     QPaintEngine::PolygonDrawMode mode)
 {
@@ -540,5 +541,5 @@
 //! See QPaintEngine::drawPolygon()
 void QwtNullPaintDevice::drawPolygon(
-    const QPoint *points, int pointCount, 
+    const QPoint *points, int pointCount,
     QPaintEngine::PolygonDrawMode mode)
 {
@@ -549,5 +550,5 @@
 
 //! See QPaintEngine::drawPixmap()
-void QwtNullPaintDevice::drawPixmap( const QRectF &rect, 
+void QwtNullPaintDevice::drawPixmap( const QRectF &rect,
     const QPixmap &pm, const QRectF &subRect )
 {
@@ -567,5 +568,5 @@
 //! See QPaintEngine::drawTiledPixmap()
 void QwtNullPaintDevice::drawTiledPixmap(
-    const QRectF &rect, const QPixmap &pixmap, 
+    const QRectF &rect, const QPixmap &pixmap,
     const QPointF &subRect)
 {
@@ -577,5 +578,5 @@
 //! See QPaintEngine::drawImage()
 void QwtNullPaintDevice::drawImage(
-    const QRectF &rect, const QImage &image, 
+    const QRectF &rect, const QImage &image,
     const QRectF &subRect, Qt::ImageConversionFlags flags)
 {
@@ -587,5 +588,5 @@
 
 //! See QPaintEngine::updateState()
-void QwtNullPaintDevice::updateState( 
+void QwtNullPaintDevice::updateState(
     const QPaintEngineState &state )
 {
Index: trunk/BNC/qwt/qwt_null_paintdevice.h
===================================================================
--- trunk/BNC/qwt/qwt_null_paintdevice.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_null_paintdevice.h	(revision 9383)
@@ -18,9 +18,9 @@
   \brief A null paint device doing nothing
 
-  Sometimes important layout/rendering geometries are not 
-  available or changeable from the public Qt class interface. 
+  Sometimes important layout/rendering geometries are not
+  available or changeable from the public Qt class interface.
   ( f.e hidden in the style implementation ).
 
-  QwtNullPaintDevice can be used to manipulate or filter out 
+  QwtNullPaintDevice can be used to manipulate or filter out
   this information by analyzing the stream of paint primitives.
 
@@ -43,5 +43,5 @@
            the corresponding draw methods
          */
-        NormalMode, 
+        NormalMode,
 
         /*!
@@ -77,5 +77,5 @@
     virtual QPaintEngine *paintEngine() const;
 
-    virtual int metric( PaintDeviceMetric metric ) const;
+    virtual int metric( PaintDeviceMetric ) const;
 
     virtual void drawRects(const QRect *, int );
@@ -105,10 +105,10 @@
 
     virtual void drawTiledPixmap(const QRectF &,
-        const QPixmap &, const QPointF &s);
+        const QPixmap &, const QPointF & );
 
     virtual void drawImage(const QRectF &,
         const QImage &, const QRectF &, Qt::ImageConversionFlags );
 
-    virtual void updateState( const QPaintEngineState &state );
+    virtual void updateState( const QPaintEngineState & );
 
 protected:
Index: trunk/BNC/qwt/qwt_painter.cpp
===================================================================
--- trunk/BNC/qwt/qwt_painter.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_painter.cpp	(revision 9383)
@@ -20,4 +20,5 @@
 #include <qpalette.h>
 #include <qpaintdevice.h>
+#include <qpainterpath.h>
 #include <qpixmap.h>
 #include <qstyle.h>
@@ -33,5 +34,5 @@
 #endif
 
-#if QT_VERSION < 0x050000 
+#if QT_VERSION < 0x050000
 
 #ifdef Q_WS_X11
@@ -44,5 +45,5 @@
 bool QwtPainter::d_roundingAlignment = true;
 
-static inline bool qwtIsClippingNeeded( 
+static inline bool qwtIsClippingNeeded(
     const QPainter *painter, QRectF &clipRect )
 {
@@ -142,4 +143,10 @@
 bool QwtPainter::isX11GraphicsSystem()
 {
+    /*
+        The X11 paint engine has been removed with Qt 5.0, but
+        reintroduced with Qt 5.10. It can be enabled with
+        "export QT_XCB_NATIVE_PAINTING=1".
+     */
+
     static int onX11 = -1;
     if ( onX11 < 0 )
@@ -181,5 +188,5 @@
         }
 
-        const QTransform tr = painter->transform();
+        const QTransform &tr = painter->transform();
         if ( tr.isRotating() || tr.isScaling() )
         {
@@ -196,8 +203,8 @@
   to a paint engine that floors to integer values. For other paint engines
   ( PDF, SVG ) this flag has no effect.
-  QwtPainter stores this flag only, the rounding itself is done in 
+  QwtPainter stores this flag only, the rounding itself is done in
   the painting code ( f.e the plot items ).
 
-  The default setting is true. 
+  The default setting is true.
 
   \sa roundingAlignment(), isAligning()
@@ -214,4 +221,8 @@
   much faster when they are split in smaller chunks: f.e all supported Qt versions
   >= Qt 5.0 when drawing an antialiased polyline with a pen width >=2.
+
+  Also the raster paint engine has a nasty bug in many versions ( Qt 4.8 - ... )
+  for short lines ( https://codereview.qt-project.org/#/c/99456 ), that is worked
+  around in this mode.
 
   The default setting is true.
@@ -397,5 +408,5 @@
             unscaledRect = transform.inverted().mapRect(rect);
         }
-    }  
+    }
 
     txt->setDefaultFont( painter->font() );
@@ -452,5 +463,5 @@
     QPolygonF cpa = polygon;
     if ( deviceClipping )
-        cpa = QwtClipper::clipPolygonF( clipRect, polygon );
+        cpa = QwtClipper::clipPolygonF( clipRect, polygon, true );
 
     painter->drawPolygon( cpa );
@@ -501,5 +512,5 @@
     QPolygon cpa = polygon;
     if ( deviceClipping )
-        cpa = QwtClipper::clipPolygon( clipRect, polygon );
+        cpa = QwtClipper::clipPolygon( clipRect, polygon, true );
 
     painter->drawPolygon( cpa );
@@ -537,5 +548,7 @@
     }
     else
+    {
         qwtDrawPolyline<QPoint>( painter, points, pointCount, d_polylineSplitting );
+    }
 }
 
@@ -565,5 +578,5 @@
         const int maxY = qFloor( clipRect.bottom() );
 
-        if ( pos.x() < minX || pos.x() > maxX 
+        if ( pos.x() < minX || pos.x() > maxX
             || pos.y() < minY || pos.y() > maxY )
         {
@@ -576,5 +589,5 @@
 
 //! Wrapper for QPainter::drawPoints()
-void QwtPainter::drawPoints( QPainter *painter, 
+void QwtPainter::drawPoints( QPainter *painter,
     const QPoint *points, int pointCount )
 {
@@ -609,5 +622,5 @@
 
 //! Wrapper for QPainter::drawPoints()
-void QwtPainter::drawPoints( QPainter *painter, 
+void QwtPainter::drawPoints( QPainter *painter,
     const QPointF *points, int pointCount )
 {
@@ -697,5 +710,5 @@
 
 /*!
-  Draw a round frame 
+  Draw a round frame
 
   \param painter Painter
@@ -708,5 +721,5 @@
 */
 void QwtPainter::drawRoundFrame( QPainter *painter,
-    const QRectF &rect, const QPalette &palette, 
+    const QRectF &rect, const QPalette &palette,
     int lineWidth, int frameStyle )
 {
@@ -787,5 +800,5 @@
     {
         const QRectF outerRect = rect.adjusted( 0.0, 0.0, -1.0, -1.0 );
-        const QRectF innerRect = outerRect.adjusted( 
+        const QRectF innerRect = outerRect.adjusted(
             frameWidth, frameWidth, -frameWidth, -frameWidth );
 
@@ -806,10 +819,10 @@
         {
             const QRectF outerRect = rect.adjusted( 0.0, 0.0, -1.0, -1.0 );
-            const QRectF midRect1 = outerRect.adjusted( 
+            const QRectF midRect1 = outerRect.adjusted(
                 frameWidth, frameWidth, -frameWidth, -frameWidth );
-            const QRectF midRect2 = midRect1.adjusted( 
+            const QRectF midRect2 = midRect1.adjusted(
                 midLineWidth, midLineWidth, -midLineWidth, -midLineWidth );
 
-            const QRectF innerRect = midRect2.adjusted( 
+            const QRectF innerRect = midRect2.adjusted(
                 frameWidth, frameWidth, -frameWidth, -frameWidth );
 
@@ -887,6 +900,6 @@
         {
             const QRectF outerRect = rect.adjusted( 0.0, 0.0, -1.0, -1.0 );
-            const QRectF innerRect = outerRect.adjusted( 
-                frameWidth - 1.0, frameWidth - 1.0, 
+            const QRectF innerRect = outerRect.adjusted(
+                frameWidth - 1.0, frameWidth - 1.0,
                 -( frameWidth - 1.0 ), -( frameWidth - 1.0 ) );
 
@@ -942,6 +955,6 @@
 */
 
-void QwtPainter::drawRoundedFrame( QPainter *painter, 
-    const QRectF &rect, double xRadius, double yRadius, 
+void QwtPainter::drawRoundedFrame( QPainter *painter,
+    const QRectF &rect, double xRadius, double yRadius,
     const QPalette &palette, int lineWidth, int frameStyle )
 {
@@ -951,8 +964,8 @@
 
     double lw2 = lineWidth * 0.5;
-    QRectF r = rect.adjusted( lw2, lw2, -lw2, -lw2 );
+    QRectF innerRect = rect.adjusted( lw2, lw2, -lw2, -lw2 );
 
     QPainterPath path;
-    path.addRoundedRect( r, xRadius, yRadius );
+    path.addRoundedRect( innerRect, xRadius, yRadius );
 
     enum Style
@@ -973,25 +986,25 @@
         // move + 4 * ( cubicTo + lineTo )
         QPainterPath pathList[8];
-        
+
         for ( int i = 0; i < 4; i++ )
         {
             const int j = i * 4 + 1;
-            
+
             pathList[ 2 * i ].moveTo(
                 path.elementAt(j - 1).x, path.elementAt( j - 1 ).y
-            );  
-            
+            );
+
             pathList[ 2 * i ].cubicTo(
                 path.elementAt(j + 0).x, path.elementAt(j + 0).y,
                 path.elementAt(j + 1).x, path.elementAt(j + 1).y,
                 path.elementAt(j + 2).x, path.elementAt(j + 2).y );
-                
+
             pathList[ 2 * i + 1 ].moveTo(
                 path.elementAt(j + 2).x, path.elementAt(j + 2).y
-            );  
+            );
             pathList[ 2 * i + 1 ].lineTo(
                 path.elementAt(j + 3).x, path.elementAt(j + 3).y
-            );  
-        }   
+            );
+        }
 
         QColor c1( palette.color( QPalette::Dark ) );
@@ -1003,5 +1016,5 @@
         for ( int i = 0; i < 4; i++ )
         {
-            QRectF r = pathList[2 * i].controlPointRect();
+            const QRectF r = pathList[2 * i].controlPointRect();
 
             QPen arcPen;
@@ -1147,8 +1160,8 @@
 }
 
-static inline void qwtFillRect( const QWidget *widget, QPainter *painter, 
+static inline void qwtFillRect( const QWidget *widget, QPainter *painter,
     const QRect &rect, const QBrush &brush)
 {
-    if ( brush.style() == Qt::TexturePattern ) 
+    if ( brush.style() == Qt::TexturePattern )
     {
         painter->save();
@@ -1158,5 +1171,5 @@
 
         painter->restore();
-    } 
+    }
     else if ( brush.gradient() )
     {
@@ -1164,10 +1177,10 @@
 
         painter->setClipRect( rect );
-        painter->fillRect(0, 0, widget->width(), 
+        painter->fillRect(0, 0, widget->width(),
             widget->height(), brush);
 
         painter->restore();
-    } 
-    else 
+    }
+    else
     {
         painter->fillRect(rect, brush);
@@ -1179,14 +1192,14 @@
 
   In Qt >= 5.0 QPixmap::fill() is a nop, in Qt 4.x it is buggy
-  for backgrounds with gradients. Thus fillPixmap() offers 
+  for backgrounds with gradients. Thus fillPixmap() offers
   an alternative implementation.
 
   \param widget Widget
   \param pixmap Pixmap to be filled
-  \param offset Offset 
+  \param offset Offset
 
   \sa QPixmap::fill()
  */
-void QwtPainter::fillPixmap( const QWidget *widget, 
+void QwtPainter::fillPixmap( const QWidget *widget,
     QPixmap &pixmap, const QPoint &offset )
 {
@@ -1196,8 +1209,8 @@
     painter.translate( -offset );
 
-    const QBrush autoFillBrush = 
+    const QBrush autoFillBrush =
         widget->palette().brush( widget->backgroundRole() );
 
-    if ( !( widget->autoFillBackground() && autoFillBrush.isOpaque() ) ) 
+    if ( !( widget->autoFillBackground() && autoFillBrush.isOpaque() ) )
     {
         const QBrush bg = widget->palette().brush( QPalette::Window );
@@ -1208,5 +1221,5 @@
         qwtFillRect( widget, &painter, rect, autoFillBrush);
 
-    if ( widget->testAttribute(Qt::WA_StyledBackground) ) 
+    if ( widget->testAttribute(Qt::WA_StyledBackground) )
     {
         painter.setClipRegion( rect );
@@ -1214,5 +1227,5 @@
         QStyleOption opt;
         opt.initFrom( widget );
-        widget->style()->drawPrimitive( QStyle::PE_Widget, 
+        widget->style()->drawPrimitive( QStyle::PE_Widget,
             &opt, &painter, widget );
     }
@@ -1285,5 +1298,5 @@
 #endif
 
-#if QT_VERSION < 0x050000 
+#if QT_VERSION < 0x050000
 #ifdef Q_WS_X11
     if ( widget && isX11GraphicsSystem() )
Index: trunk/BNC/qwt/qwt_painter.h
===================================================================
--- trunk/BNC/qwt/qwt_painter.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_painter.h	(revision 9383)
@@ -51,5 +51,5 @@
     static void drawText( QPainter *, double x, double y, double w, double h,
         int flags, const QString & );
-    static void drawText( QPainter *, const QRectF &, 
+    static void drawText( QPainter *, const QRectF &,
         int flags, const QString & );
 
@@ -64,5 +64,5 @@
 
     static void drawEllipse( QPainter *, const QRectF & );
-    static void drawPie( QPainter *, const QRectF & r, int a, int alen );
+    static void drawPie( QPainter *, const QRectF &, int a, int alen );
 
     static void drawLine( QPainter *, double x1, double y1, double x2, double y2 );
@@ -94,5 +94,5 @@
         const QRectF &, const QPalette &, int lineWidth, int frameStyle );
 
-    static void drawRoundedFrame( QPainter *, 
+    static void drawRoundedFrame( QPainter *,
         const QRectF &, double xRadius, double yRadius,
         const QPalette &, int lineWidth, int frameStyle );
@@ -100,5 +100,5 @@
     static void drawFrame( QPainter *, const QRectF &rect,
         const QPalette &palette, QPalette::ColorRole foregroundRole,
-        int lineWidth, int midLineWidth, int frameStyle ); 
+        int frameWidth, int midLineWidth, int frameStyle );
 
     static void drawFocusRect( QPainter *, const QWidget * );
@@ -112,5 +112,5 @@
     static bool isX11GraphicsSystem();
 
-    static void fillPixmap( const QWidget *, 
+    static void fillPixmap( const QWidget *,
         QPixmap &, const QPoint &offset = QPoint() );
 
Index: trunk/BNC/qwt/qwt_painter_command.cpp
===================================================================
--- trunk/BNC/qwt/qwt_painter_command.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_painter_command.cpp	(revision 9383)
@@ -64,8 +64,8 @@
 }
 
-/*! 
+/*!
   Constructor for State paint operation
   \param state Paint engine state
- */  
+ */
 QwtPainterCommand::QwtPainterCommand( const QPaintEngineState &state ):
     d_type( State )
@@ -75,17 +75,17 @@
     d_stateData->flags = state.state();
 
-    if ( d_stateData->flags & QPaintEngine::DirtyPen ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyPen )
         d_stateData->pen = state.pen();
 
-    if ( d_stateData->flags & QPaintEngine::DirtyBrush ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyBrush )
         d_stateData->brush = state.brush();
 
-    if ( d_stateData->flags & QPaintEngine::DirtyBrushOrigin ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyBrushOrigin )
         d_stateData->brushOrigin = state.brushOrigin();
 
-    if ( d_stateData->flags & QPaintEngine::DirtyFont ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyFont )
         d_stateData->font = state.font();
 
-    if ( d_stateData->flags & QPaintEngine::DirtyBackground ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyBackground )
     {
         d_stateData->backgroundMode = state.backgroundMode();
@@ -93,11 +93,11 @@
     }
 
-    if ( d_stateData->flags & QPaintEngine::DirtyTransform ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyTransform )
         d_stateData->transform = state.transform();
 
-    if ( d_stateData->flags & QPaintEngine::DirtyClipEnabled ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyClipEnabled )
         d_stateData->isClipEnabled = state.isClipEnabled();
 
-    if ( d_stateData->flags & QPaintEngine::DirtyClipRegion ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyClipRegion )
     {
         d_stateData->clipRegion = state.clipRegion();
@@ -105,5 +105,5 @@
     }
 
-    if ( d_stateData->flags & QPaintEngine::DirtyClipPath ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyClipPath )
     {
         d_stateData->clipPath = state.clipPath();
@@ -111,11 +111,11 @@
     }
 
-    if ( d_stateData->flags & QPaintEngine::DirtyHints ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyHints )
         d_stateData->renderHints = state.renderHints();
 
-    if ( d_stateData->flags & QPaintEngine::DirtyCompositionMode ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyCompositionMode )
         d_stateData->compositionMode = state.compositionMode();
 
-    if ( d_stateData->flags & QPaintEngine::DirtyOpacity ) 
+    if ( d_stateData->flags & QPaintEngine::DirtyOpacity )
         d_stateData->opacity = state.opacity();
 }
@@ -124,5 +124,5 @@
   Copy constructor
   \param other Command to be copied
-  
+
  */
 QwtPainterCommand::QwtPainterCommand(const QwtPainterCommand &other)
@@ -214,5 +214,5 @@
 
 //! \return Painter path to be painted
-QPainterPath *QwtPainterCommand::path() 
+QPainterPath *QwtPainterCommand::path()
 {
     return d_path;
@@ -220,5 +220,5 @@
 
 //! \return Attributes how to paint a QPixmap
-QwtPainterCommand::PixmapData* QwtPainterCommand::pixmapData() 
+QwtPainterCommand::PixmapData* QwtPainterCommand::pixmapData()
 {
     return d_pixmapData;
@@ -226,5 +226,5 @@
 
 //! \return Attributes how to paint a QImage
-QwtPainterCommand::ImageData* QwtPainterCommand::imageData() 
+QwtPainterCommand::ImageData* QwtPainterCommand::imageData()
 {
     return d_imageData;
@@ -232,5 +232,5 @@
 
 //! \return Attributes of a state change
-QwtPainterCommand::StateData* QwtPainterCommand::stateData() 
+QwtPainterCommand::StateData* QwtPainterCommand::stateData()
 {
     return d_stateData;
Index: trunk/BNC/qwt/qwt_painter_command.h
===================================================================
--- trunk/BNC/qwt/qwt_painter_command.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_painter_command.h	(revision 9383)
@@ -16,4 +16,5 @@
 #include <qimage.h>
 #include <qpolygon.h>
+#include <qpainterpath.h>
 
 class QPainterPath;
@@ -27,5 +28,5 @@
   \sa QwtGraphic::commands()
  */
-  
+
 class QWT_EXPORT QwtPainterCommand
 {
@@ -50,5 +51,5 @@
     };
 
-    //! Attributes how to paint a QPixmap 
+    //! Attributes how to paint a QPixmap
     struct PixmapData
     {
@@ -58,5 +59,5 @@
     };
 
-    //! Attributes how to paint a QImage 
+    //! Attributes how to paint a QImage
     struct ImageData
     {
@@ -151,5 +152,5 @@
 
 //! \return Attributes how to paint a QPixmap
-inline const QwtPainterCommand::PixmapData* 
+inline const QwtPainterCommand::PixmapData *
 QwtPainterCommand::pixmapData() const
 {
@@ -158,5 +159,5 @@
 
 //! \return Attributes how to paint a QImage
-inline const QwtPainterCommand::ImageData * 
+inline const QwtPainterCommand::ImageData *
 QwtPainterCommand::imageData() const
 {
@@ -165,5 +166,5 @@
 
 //! \return Attributes of a state change
-inline const QwtPainterCommand::StateData * 
+inline const QwtPainterCommand::StateData *
 QwtPainterCommand::stateData() const
 {
Index: trunk/BNC/qwt/qwt_panner.cpp
===================================================================
--- trunk/BNC/qwt/qwt_panner.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_panner.cpp	(revision 9383)
@@ -129,5 +129,5 @@
    \param modifiers Keyboard modifiers
 */
-void QwtPanner::setAbortKey( int key, 
+void QwtPanner::setAbortKey( int key,
     Qt::KeyboardModifiers modifiers )
 {
@@ -137,5 +137,5 @@
 
 //! Get the abort key and modifiers
-void QwtPanner::getAbortKey( int &key, 
+void QwtPanner::getAbortKey( int &key,
     Qt::KeyboardModifiers &modifiers ) const
 {
@@ -248,15 +248,19 @@
    fill the empty spaces by the background of the parent widget.
 
-   \param pe Paint event
-*/
-void QwtPanner::paintEvent( QPaintEvent *pe )
+   \param event Paint event
+*/
+void QwtPanner::paintEvent( QPaintEvent *event )
 {
     int dx = d_data->pos.x() - d_data->initialPos.x();
     int dy = d_data->pos.y() - d_data->initialPos.y();
 
-    QRect r( 0, 0, d_data->pixmap.width(), d_data->pixmap.height() );
-    r.moveCenter( QPoint( r.center().x() + dx, r.center().y() + dy ) );
-
-    QPixmap pm( size() );
+    QRectF r;
+    r.setSize( d_data->pixmap.size() );
+#if QT_VERSION >= 0x050000
+    r.setSize( r.size() / d_data->pixmap.devicePixelRatio() );
+#endif
+    r.moveCenter( QPointF( r.center().x() + dx, r.center().y() + dy ) );
+
+    QPixmap pm = QwtPainter::backingStore( this, size() );
     QwtPainter::fillPixmap( parentWidget(), pm );
 
@@ -267,9 +271,9 @@
         QPixmap masked = d_data->pixmap;
         masked.setMask( d_data->contentsMask );
-        painter.drawPixmap( r, masked );
+        painter.drawPixmap( r.toRect(), masked );
     }
     else
     {
-        painter.drawPixmap( r, d_data->pixmap );
+        painter.drawPixmap( r.toRect(), d_data->pixmap );
     }
 
@@ -280,5 +284,5 @@
 
     painter.begin( this );
-    painter.setClipRegion( pe->region() );
+    painter.setClipRegion( event->region() );
     painter.drawPixmap( 0, 0, pm );
 }
Index: trunk/BNC/qwt/qwt_panner.h
===================================================================
--- trunk/BNC/qwt/qwt_panner.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_panner.h	(revision 9383)
@@ -44,7 +44,7 @@
     bool isEnabled() const;
 
-    void setMouseButton( Qt::MouseButton, 
+    void setMouseButton( Qt::MouseButton,
         Qt::KeyboardModifiers = Qt::NoModifier );
-    void getMouseButton( Qt::MouseButton &button, 
+    void getMouseButton( Qt::MouseButton &button,
         Qt::KeyboardModifiers & ) const;
 
Index: trunk/BNC/qwt/qwt_picker.cpp
===================================================================
--- trunk/BNC/qwt/qwt_picker.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_picker.cpp	(revision 9383)
@@ -53,10 +53,10 @@
     if ( l.x1() == l.x2() )
     {
-        region += QRect( l.x1() - pw2, l.y1(), 
+        region += QRect( l.x1() - pw2, l.y1(),
             pw, l.y2() ).normalized();
     }
     else if ( l.y1() == l.y2() )
     {
-        region += QRect( l.x1(), l.y1() - pw2, 
+        region += QRect( l.x1(), l.y1() - pw2,
             l.x2(), pw ).normalized();
     }
@@ -78,14 +78,14 @@
 
 class QwtPickerTracker: public QwtWidgetOverlay
-{                                  
+{
 public:
     QwtPickerTracker( QwtPicker *, QWidget * );
-    
+
 protected:
     virtual void drawOverlay( QPainter * ) const;
     virtual QRegion maskHint() const;
-    
+
     QwtPicker *d_picker;
-};  
+};
 
 
@@ -105,5 +105,5 @@
     {
     }
-        
+
     bool enabled;
 
@@ -558,5 +558,5 @@
                 case VLineRubberBand:
                 {
-                    mask += qwtMaskRegion( QLine( pos.x(), pRect.top(), 
+                    mask += qwtMaskRegion( QLine( pos.x(), pRect.top(),
                         pos.x(), pRect.bottom() ), pw );
                     break;
@@ -564,5 +564,5 @@
                 case HLineRubberBand:
                 {
-                    mask += qwtMaskRegion( QLine( pRect.left(), pos.y(), 
+                    mask += qwtMaskRegion( QLine( pRect.left(), pos.y(),
                         pRect.right(), pos.y() ), pw );
                     break;
@@ -570,7 +570,7 @@
                 case CrossRubberBand:
                 {
-                    mask += qwtMaskRegion( QLine( pos.x(), pRect.top(), 
+                    mask += qwtMaskRegion( QLine( pos.x(), pRect.top(),
                         pos.x(), pRect.bottom() ), pw );
-                    mask += qwtMaskRegion( QLine( pRect.left(), pos.y(), 
+                    mask += qwtMaskRegion( QLine( pRect.left(), pos.y(),
                         pRect.right(), pos.y() ), pw );
                     break;
@@ -752,27 +752,31 @@
    depends on the application requirements. F.e. :
 
-   - A rectangular selection might need to have a specific aspect ratio only.\n
-   - A selection could accept non intersecting polygons only.\n
-   - ...\n
+     - A rectangular selection might need to have a specific aspect ratio only.
+     - A selection could accept non intersecting polygons only.
+     - ...
 
    The example below is for a rectangular selection, where the first
    point is the center of the selected rectangle.
+
   \par Example
-  \verbatim QPolygon MyPicker::adjustedPoints(const QPolygon &points) const
-{
-    QPolygon adjusted;
-    if ( points.size() == 2 )
-    {
-        const int width = qAbs(points[1].x() - points[0].x());
-        const int height = qAbs(points[1].y() - points[0].y());
-
-        QRect rect(0, 0, 2 * width, 2 * height);
-        rect.moveCenter(points[0]);
-
-        adjusted += rect.topLeft();
-        adjusted += rect.bottomRight();
-    }
-    return adjusted;
-}\endverbatim\n
+  \code
+    QPolygon MyPicker::adjustedPoints( const QPolygon &points ) const
+    {
+        QPolygon adjusted;
+        if ( points.size() == 2 )
+        {
+            const int width = qAbs( points[1].x() - points[0].x() );
+            const int height = qAbs( points[1].y() - points[0].y() );
+
+            QRect rect( 0, 0, 2 * width, 2 * height );
+            rect.moveCenter( points[0] );
+
+            adjusted += rect.topLeft();
+            adjusted += rect.bottomRight();
+        }
+        return adjusted;
+    }
+  \endcode
+  \endpar
 
   \param points Selected points
@@ -833,5 +837,5 @@
     {
         const QPoint last =
-            d_data->pickedPoints[int( d_data->pickedPoints.count() ) - 2];
+            d_data->pickedPoints[ d_data->pickedPoints.count() - 2 ];
 
         alignment |= ( pos.x() >= last.x() ) ? Qt::AlignRight : Qt::AlignLeft;
@@ -1183,5 +1187,5 @@
         case QEvent::MouseMove:
         {
-            const QMouseEvent *me = 
+            const QMouseEvent *me =
                 static_cast< const QMouseEvent * >( event );
             pos = me->pos();
@@ -1235,5 +1239,5 @@
         return;
 
-    d_data->pickedPoints.resize( 0 );
+    d_data->pickedPoints.clear();
     d_data->isActive = true;
     Q_EMIT activated( true );
@@ -1281,5 +1285,5 @@
             Q_EMIT selected( d_data->pickedPoints );
         else
-            d_data->pickedPoints.resize( 0 );
+            d_data->pickedPoints.clear();
 
         updateDisplay();
@@ -1315,7 +1319,5 @@
     if ( d_data->isActive )
     {
-        const int idx = d_data->pickedPoints.count();
-        d_data->pickedPoints.resize( idx + 1 );
-        d_data->pickedPoints[idx] = pos;
+        d_data->pickedPoints += pos;
 
         updateDisplay();
@@ -1333,16 +1335,13 @@
 void QwtPicker::move( const QPoint &pos )
 {
-    if ( d_data->isActive )
-    {
-        const int idx = d_data->pickedPoints.count() - 1;
-        if ( idx >= 0 )
-        {
-            if ( d_data->pickedPoints[idx] != pos )
-            {
-                d_data->pickedPoints[idx] = pos;
-
-                updateDisplay();
-                Q_EMIT moved( pos );
-            }
+    if ( d_data->isActive && !d_data->pickedPoints.isEmpty() )
+    {
+        QPoint &point = d_data->pickedPoints.last();
+        if ( point != pos )
+        {
+            point = pos;
+
+            updateDisplay();
+            Q_EMIT moved( pos );
         }
     }
@@ -1357,17 +1356,15 @@
 void QwtPicker::remove()
 {
-    if ( d_data->isActive )
-    {
-        const int idx = d_data->pickedPoints.count() - 1;
-        if ( idx > 0 )
-        {
-            const int idx = d_data->pickedPoints.count();
-
-            const QPoint pos = d_data->pickedPoints[idx - 1];
-            d_data->pickedPoints.resize( idx - 1 );
-
-            updateDisplay();
-            Q_EMIT removed( pos );
-        }
+    if ( d_data->isActive && !d_data->pickedPoints.isEmpty() )
+    {
+#if QT_VERSION >= 0x050100
+        const QPoint pos = d_data->pickedPoints.takeLast();
+#else
+        const QPoint pos = d_data->pickedPoints.last();
+        d_data->pickedPoints.resize( d_data->pickedPoints.count() - 1 );
+#endif
+
+        updateDisplay();
+        Q_EMIT removed( pos );
     }
 }
@@ -1424,10 +1421,8 @@
     }
 
-    const double xRatio =
-        double( newSize.width() ) / double( oldSize.width() );
-    const double yRatio =
-        double( newSize.height() ) / double( oldSize.height() );
-
-    for ( int i = 0; i < int( d_data->pickedPoints.count() ); i++ )
+    const double xRatio = double( newSize.width() ) / double( oldSize.width() );
+    const double yRatio = double( newSize.height() ) / double( oldSize.height() );
+
+    for ( int i = 0; i < d_data->pickedPoints.count(); i++ )
     {
         QPoint &p = d_data->pickedPoints[i];
@@ -1472,5 +1467,5 @@
   Find the area of the observed widget, where selection might happen.
 
-  \return parentWidget()->contentsRect() 
+  \return parentWidget()->contentsRect()
 */
 QPainterPath QwtPicker::pickArea() const
@@ -1504,5 +1499,5 @@
             ( trackerMode() == ActiveOnly && isActive() ) )
         {
-            if ( trackerPen() != Qt::NoPen 
+            if ( trackerPen() != Qt::NoPen
                 && !trackerRect( QFont() ).isEmpty() )
             {
Index: trunk/BNC/qwt/qwt_picker.h
===================================================================
--- trunk/BNC/qwt/qwt_picker.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_picker.h	(revision 9383)
@@ -59,11 +59,14 @@
 
   \par Example
-  \verbatim #include <qwt_picker.h>
-#include <qwt_picker_machine.h>
-
-QwtPicker *picker = new QwtPicker(widget);
-picker->setStateMachine(new QwtPickerDragRectMachine);
-picker->setTrackerMode(QwtPicker::ActiveOnly);
-picker->setRubberBand(QwtPicker::RectRubberBand); \endverbatim\n
+  \code
+    #include <qwt_picker.h>
+    #include <qwt_picker_machine.h>
+
+    QwtPicker *picker = new QwtPicker(widget);
+    picker->setStateMachine(new QwtPickerDragRectMachine);
+    picker->setTrackerMode(QwtPicker::ActiveOnly);
+    picker->setRubberBand(QwtPicker::RectRubberBand);
+  \endcode
+  \endpar
 
   The state machine triggers the following commands:
@@ -308,6 +311,6 @@
     virtual void widgetLeaveEvent( QEvent * );
 
-    virtual void stretchSelection( const QSize &oldSize,
-                                   const QSize &newSize );
+    virtual void stretchSelection(
+        const QSize &oldSize, const QSize &newSize );
 
     virtual void updateDisplay();
Index: trunk/BNC/qwt/qwt_picker_machine.cpp
===================================================================
--- trunk/BNC/qwt/qwt_picker_machine.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_picker_machine.cpp	(revision 9383)
@@ -106,5 +106,5 @@
         case QEvent::MouseButtonPress:
         {
-            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1, 
+            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1,
                 static_cast<const QMouseEvent *>( event ) ) )
             {
@@ -152,5 +152,5 @@
         case QEvent::MouseButtonPress:
         {
-            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1, 
+            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1,
                 static_cast<const QMouseEvent *>( event ) ) )
             {
@@ -225,5 +225,5 @@
         case QEvent::MouseButtonPress:
         {
-            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1, 
+            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1,
                 static_cast<const QMouseEvent *>( event ) ) )
             {
@@ -260,5 +260,5 @@
         case QEvent::MouseButtonRelease:
         {
-            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1, 
+            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1,
                 static_cast<const QMouseEvent *>( event ) ) )
             {
@@ -324,5 +324,5 @@
         case QEvent::MouseButtonPress:
         {
-            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1, 
+            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1,
                 static_cast<const QMouseEvent *>( event ) ) )
             {
@@ -355,5 +355,5 @@
         case QEvent::KeyPress:
         {
-            if ( eventPattern.keyMatch( QwtEventPattern::KeySelect1, 
+            if ( eventPattern.keyMatch( QwtEventPattern::KeySelect1,
                 static_cast<const QKeyEvent *> ( event ) ) )
             {
@@ -396,5 +396,5 @@
         case QEvent::MouseButtonPress:
         {
-            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1, 
+            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect1,
                 static_cast<const QMouseEvent *>( event ) ) )
             {
@@ -411,5 +411,5 @@
                 }
             }
-            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect2, 
+            if ( eventPattern.mouseMatch( QwtEventPattern::MouseSelect2,
                 static_cast<const QMouseEvent *>( event ) ) )
             {
Index: trunk/BNC/qwt/qwt_picker_machine.h
===================================================================
--- trunk/BNC/qwt/qwt_picker_machine.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_picker_machine.h	(revision 9383)
@@ -170,5 +170,5 @@
 /*!
   \brief A state machine for line selections
-    
+
   Pressing QwtEventPattern::MouseSelect1 selects
   the first point, releasing it the second point.
@@ -179,8 +179,8 @@
   A common use case of QwtPickerDragLineMachine are pickers for
   distance measurements.
-  
-  \sa QwtEventPattern::MousePatternCode, QwtEventPattern::KeyPatternCode
-*/              
-                    
+
+  \sa QwtEventPattern::MousePatternCode, QwtEventPattern::KeyPatternCode
+*/
+
 class QWT_EXPORT QwtPickerDragLineMachine: public QwtPickerMachine
 {
Index: trunk/BNC/qwt/qwt_plot.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot.cpp	(revision 9383)
@@ -28,21 +28,19 @@
     if ( on )
     {
-        QObject::connect( 
-            plot, SIGNAL( legendDataChanged(
-                const QVariant &, const QList<QwtLegendData> & ) ),
-            plot, SLOT( updateLegendItems( 
-                const QVariant &, const QList<QwtLegendData> & ) ) );
+        QObject::connect(
+            plot, SIGNAL(legendDataChanged(QVariant,QList<QwtLegendData>)),
+            plot, SLOT(updateLegendItems(QVariant,QList<QwtLegendData>))
+        );
     }
     else
     {
-        QObject::disconnect( 
-            plot, SIGNAL( legendDataChanged(
-                const QVariant &, const QList<QwtLegendData> & ) ),
-            plot, SLOT( updateLegendItems( 
-                const QVariant &, const QList<QwtLegendData> & ) ) );
-    }
-}
-
-static void qwtSetTabOrder( 
+        QObject::disconnect(
+            plot, SIGNAL(legendDataChanged(QVariant,QList<QwtLegendData>) ),
+            plot, SLOT( updateLegendItems(QVariant,QList<QwtLegendData>))
+        );
+    }
+}
+
+static void qwtSetTabOrder(
     QWidget *first, QWidget *second, bool withChildren )
 {
@@ -196,5 +194,5 @@
   QwtPlot invokes methods of the canvas as meta methods ( see QMetaObject ).
   In opposite to using conventional C++ techniques like virtual methods
-  they allow to use canvas implementations that are derived from 
+  they allow to use canvas implementations that are derived from
   QWidget or QGLWidget.
 
@@ -210,5 +208,5 @@
     it is o.k. not to implement this method.
 
-  The default canvas is a QwtPlotCanvas 
+  The default canvas is a QwtPlotCanvas
 
   \param canvas Canvas Widget
@@ -317,5 +315,5 @@
 }
 
-/*! 
+/*!
   \return true if the autoReplot option is set.
   \sa setAutoReplot()
@@ -371,5 +369,5 @@
 
 /*!
-  Change the text the footer 
+  Change the text the footer
   \param text New text of the footer
 */
@@ -384,5 +382,5 @@
 
 /*!
-  Change the text the footer 
+  Change the text the footer
   \param text New text of the footer
 */
@@ -560,5 +558,5 @@
     if ( d_data->canvas )
     {
-        const bool ok = QMetaObject::invokeMethod( 
+        const bool ok = QMetaObject::invokeMethod(
             d_data->canvas, "replot", Qt::DirectConnection );
         if ( !ok )
@@ -724,5 +722,5 @@
     getCanvasMarginsHint( maps, canvas()->contentsRect(),
         margins[yLeft], margins[xTop], margins[yRight], margins[xBottom] );
-    
+
     bool doUpdate = false;
     for ( int axisId = 0; axisId < axisCnt; axisId++ )
@@ -766,6 +764,6 @@
 
   \note Usually canvasRect is contentsRect() of the plot canvas.
-        Due to a bug in Qt this rectangle might be wrong for certain 
-        frame styles ( f.e QFrame::Box ) and it might be necessary to 
+        Due to a bug in Qt this rectangle might be wrong for certain
+        frame styles ( f.e QFrame::Box ) and it might be necessary to
         fix the margins manually using QWidget::setContentsMargins()
 */
@@ -914,5 +912,5 @@
 
   insertLegend() will set the plot widget as parent for the legend.
-  The legend will be deleted in the destructor of the plot or when 
+  The legend will be deleted in the destructor of the plot or when
   another legend is inserted.
 
@@ -952,10 +950,7 @@
         if ( d_data->legend )
         {
-            connect( this, 
-                SIGNAL( legendDataChanged( 
-                    const QVariant &, const QList<QwtLegendData> & ) ),
-                d_data->legend, 
-                SLOT( updateLegend( 
-                    const QVariant &, const QList<QwtLegendData> & ) ) 
+            connect(
+                this, SIGNAL(legendDataChanged(QVariant,QList<QwtLegendData>)),
+                d_data->legend, SLOT(updateLegend(QVariant,QList<QwtLegendData>) )
             );
 
@@ -1088,5 +1083,5 @@
 
 /*!
-  \brief Attach/Detach a plot item 
+  \brief Attach/Detach a plot item
 
   \param plotItem Plot item
@@ -1116,5 +1111,5 @@
     if ( on )
         insertItem( plotItem );
-    else 
+    else
         removeItem( plotItem );
 
@@ -1168,5 +1163,5 @@
          that has bee generated from itemToInfo().
 
-  The default implementation simply tries to unwrap a QwtPlotItem 
+  The default implementation simply tries to unwrap a QwtPlotItem
   pointer:
 
Index: trunk/BNC/qwt/qwt_plot.h
===================================================================
--- trunk/BNC/qwt/qwt_plot.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot.h	(revision 9383)
@@ -41,5 +41,5 @@
   can be configured separately for each axis.
 
-  The simpleplot example is a good starting point to see how to set up a 
+  The simpleplot example is a good starting point to see how to set up a
   plot widget.
 
@@ -47,27 +47,28 @@
 
   \par Example
-  The following example shows (schematically) the most simple
-  way to use QwtPlot. By default, only the left and bottom axes are
-  visible and their scales are computed automatically.
-  \verbatim
-#include <qwt_plot.h>
-#include <qwt_plot_curve.h>
-
-QwtPlot *myPlot = new QwtPlot("Two Curves", parent);
-
-// add curves
-QwtPlotCurve *curve1 = new QwtPlotCurve("Curve 1");
-QwtPlotCurve *curve2 = new QwtPlotCurve("Curve 2");
-
-// connect or copy the data to the curves
-curve1->setData(...);
-curve2->setData(...);
-
-curve1->attach(myPlot);
-curve2->attach(myPlot);
-
-// finally, refresh the plot
-myPlot->replot();
-\endverbatim
+    The following example shows (schematically) the most simple
+    way to use QwtPlot. By default, only the left and bottom axes are
+    visible and their scales are computed automatically.
+    \code
+      #include <qwt_plot.h>
+      #include <qwt_plot_curve.h>
+
+      QwtPlot *myPlot = new QwtPlot( "Two Curves", parent );
+
+      // add curves
+      QwtPlotCurve *curve1 = new QwtPlotCurve( "Curve 1" );
+      QwtPlotCurve *curve2 = new QwtPlotCurve( "Curve 2" );
+
+      // connect or copy the data to the curves
+      curve1->setData( ... );
+      curve2->setData( ... );
+
+      curve1->attach( myPlot );
+      curve2->attach( myPlot );
+
+      // finally, refresh the plot
+      myPlot->replot();
+    \endcode
+  \endpar
 */
 
@@ -76,5 +77,5 @@
     Q_OBJECT
 
-    Q_PROPERTY( QBrush canvasBackground 
+    Q_PROPERTY( QBrush canvasBackground
         READ canvasBackground WRITE setCanvasBackground )
     Q_PROPERTY( bool autoReplot READ autoReplot WRITE setAutoReplot )
@@ -122,5 +123,5 @@
         RightLegend,
 
-        //! The legend will be below the footer 
+        //! The legend will be below the footer
         BottomLegend,
 
@@ -150,5 +151,5 @@
 
     void setTitle( const QString & );
-    void setTitle( const QwtText &t );
+    void setTitle( const QwtText & );
     QwtText title() const;
 
@@ -159,5 +160,5 @@
 
     void setFooter( const QString & );
-    void setFooter( const QwtText &t );
+    void setFooter( const QwtText & );
     QwtText footer() const;
 
@@ -192,8 +193,8 @@
     bool axisEnabled( int axisId ) const;
 
-    void setAxisFont( int axisId, const QFont &f );
+    void setAxisFont( int axisId, const QFont & );
     QFont axisFont( int axisId ) const;
 
-    void setAxisScale( int axisId, double min, double max, double step = 0 );
+    void setAxisScale( int axisId, double min, double max, double stepSize = 0 );
     void setAxisScaleDiv( int axisId, const QwtScaleDiv & );
     void setAxisScaleDraw( int axisId, QwtScaleDraw * );
@@ -225,5 +226,5 @@
     // Legend
 
-    void insertLegend( QwtAbstractLegend *, 
+    void insertLegend( QwtAbstractLegend *,
         LegendPosition = QwtPlot::RightLegend, double ratio = -1.0 );
 
@@ -245,5 +246,5 @@
     void updateCanvasMargins();
 
-    virtual void getCanvasMarginsHint( 
+    virtual void getCanvasMarginsHint(
         const QwtScaleMap maps[], const QRectF &canvasRect,
         double &left, double &top, double &right, double &bottom) const;
@@ -268,5 +269,5 @@
 
     /*!
-      A signal with the attributes how to update 
+      A signal with the attributes how to update
       the legend entries for a plot item.
 
@@ -277,5 +278,5 @@
       \sa itemToInfo(), infoToItem(), QwtAbstractLegend::updateLegend()
      */
-    void legendDataChanged( const QVariant &itemInfo, 
+    void legendDataChanged( const QVariant &itemInfo,
         const QList<QwtLegendData> &data );
 
@@ -291,5 +292,5 @@
 private Q_SLOTS:
     void updateLegendItems( const QVariant &itemInfo,
-        const QList<QwtLegendData> &data );
+        const QList<QwtLegendData> &legendData );
 
 private:
Index: trunk/BNC/qwt/qwt_plot_abstract_barchart.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_abstract_barchart.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_abstract_barchart.cpp	(revision 9383)
@@ -181,6 +181,6 @@
    \brief Set the baseline
 
-   The baseline is the origin for the chart. Each bar is 
-   painted from the baseline in the direction of the sample 
+   The baseline is the origin for the chart. Each bar is
+   painted from the baseline in the direction of the sample
    value. In case of a horizontal orientation() the baseline
    is interpreted as x - otherwise as y - value.
@@ -201,5 +201,5 @@
 }
 
-/*! 
+/*!
    \return Value for the origin of the bar chart
    \sa setBaseline(), QwtPlotSeriesItem::orientation()
@@ -286,5 +286,5 @@
        QwtPlot::getCanvasMarginsHint(), QwtPlot::updateCanvasMargins()
  */
-void QwtPlotAbstractBarChart::getCanvasMarginHint( const QwtScaleMap &xMap, 
+void QwtPlotAbstractBarChart::getCanvasMarginHint( const QwtScaleMap &xMap,
     const QwtScaleMap &yMap, const QRectF &canvasRect,
     double &left, double &top, double &right, double &bottom ) const
Index: trunk/BNC/qwt/qwt_plot_abstract_barchart.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_abstract_barchart.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_abstract_barchart.h	(revision 9383)
@@ -18,5 +18,5 @@
   \brief Abstract base class for bar chart items
 
-  In opposite to almost all other plot items bar charts can't be 
+  In opposite to almost all other plot items bar charts can't be
   displayed inside of their bounding rectangle and need a special
   API  how to calculate the width of the bars and how they affect
@@ -79,5 +79,5 @@
     double baseline() const;
 
-    virtual void getCanvasMarginHint( 
+    virtual void getCanvasMarginHint(
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
         const QRectF &canvasRect,
@@ -87,5 +87,5 @@
 protected:
     double sampleWidth( const QwtScaleMap &map,
-        double canvasSize, double dataSize,
+        double canvasSize, double boundingSize,
         double value ) const;
 
Index: trunk/BNC/qwt/qwt_plot_axis.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_axis.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_axis.cpp	(revision 9383)
@@ -68,5 +68,5 @@
         d.scaleEngine = new QwtLinearScaleEngine;
 
-        d.scaleWidget->setTransformation( 
+        d.scaleWidget->setTransformation(
             d.scaleEngine->transformation() );
 
@@ -148,5 +148,5 @@
         d.scaleEngine = scaleEngine;
 
-        d_axisData[axisId]->scaleWidget->setTransformation( 
+        d_axisData[axisId]->scaleWidget->setTransformation(
             scaleEngine->transformation() );
 
@@ -190,5 +190,4 @@
     else
         return false;
-
 }
 
@@ -289,5 +288,5 @@
 
 /*!
-  \brief Return the step size parameter that has been set in setAxisScale. 
+  \brief Return the step size parameter that has been set in setAxisScale.
 
   This doesn't need to be the step size of the current scale.
@@ -310,5 +309,5 @@
 
   This is only a convenience function for axisScaleDiv( axisId )->interval();
-  
+
   \param axisId Axis index
   \return Scale interval
@@ -434,6 +433,6 @@
   \brief Disable autoscaling and specify a fixed scale for a selected axis.
 
-  In updateAxes() the scale engine calculates a scale division from the 
-  specified parameters, that will be assigned to the scale widget. So 
+  In updateAxes() the scale engine calculates a scale division from the
+  specified parameters, that will be assigned to the scale widget. So
   updates of the scale widget usually happen delayed with the next replot.
 
@@ -467,5 +466,5 @@
 
   The scale division will be stored locally only until the next call
-  of updateAxes(). So updates of the scale widget usually happen delayed with 
+  of updateAxes(). So updates of the scale widget usually happen delayed with
   the next replot.
 
@@ -615,24 +614,24 @@
 }
 
-/*! 
+/*!
   \brief Rebuild the axes scales
 
-  In case of autoscaling the boundaries of a scale are calculated 
-  from the bounding rectangles of all plot items, having the 
-  QwtPlotItem::AutoScale flag enabled ( QwtScaleEngine::autoScale() ). 
-  Then a scale division is calculated ( QwtScaleEngine::didvideScale() ) 
+  In case of autoscaling the boundaries of a scale are calculated
+  from the bounding rectangles of all plot items, having the
+  QwtPlotItem::AutoScale flag enabled ( QwtScaleEngine::autoScale() ).
+  Then a scale division is calculated ( QwtScaleEngine::didvideScale() )
   and assigned to scale widget.
 
-  When the scale boundaries have been assigned with setAxisScale() a 
+  When the scale boundaries have been assigned with setAxisScale() a
   scale division is calculated ( QwtScaleEngine::didvideScale() )
   for this interval and assigned to the scale widget.
 
-  When the scale has been set explicitly by setAxisScaleDiv() the 
+  When the scale has been set explicitly by setAxisScaleDiv() the
   locally stored scale division gets assigned to the scale widget.
 
-  The scale widget indicates modifications by emitting a 
+  The scale widget indicates modifications by emitting a
   QwtScaleWidget::scaleDivChanged() signal.
 
-  updateAxes() is usually called by replot(). 
+  updateAxes() is usually called by replot().
 
   \sa setAxisAutoScale(), setAxisScale(), setAxisScaleDiv(), replot()
Index: trunk/BNC/qwt/qwt_plot_barchart.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_barchart.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_barchart.cpp	(revision 9383)
@@ -22,5 +22,5 @@
     {
     }
- 
+
     ~PrivateData()
     {
@@ -121,5 +121,5 @@
 
   The bar chart will take the ownership of the symbol, hence the previously
-  set symbol will be delete by setting a new one. If \p symbol is 
+  set symbol will be delete by setting a new one. If \p symbol is
   \c NULL no symbol will be drawn.
 
@@ -305,5 +305,5 @@
 
 /*!
-  Draw a bar 
+  Draw a bar
 
   \param painter Painter
@@ -313,8 +313,8 @@
  */
 void QwtPlotBarChart::drawBar( QPainter *painter,
-    int sampleIndex, const QPointF &sample, 
+    int sampleIndex, const QPointF &sample,
     const QwtColumnRect &rect ) const
 {
-    const QwtColumnSymbol *specialSym = 
+    const QwtColumnSymbol *specialSym =
         specialSymbol( sampleIndex, sample );
 
@@ -330,8 +330,8 @@
     {
         // we build a temporary default symbol
-        QwtColumnSymbol sym( QwtColumnSymbol::Box );
-        sym.setLineWidth( 1 );
-        sym.setFrameStyle( QwtColumnSymbol::Plain );
-        sym.draw( painter, rect );
+        QwtColumnSymbol columnSymbol( QwtColumnSymbol::Box );
+        columnSymbol.setLineWidth( 1 );
+        columnSymbol.setFrameStyle( QwtColumnSymbol::Plain );
+        columnSymbol.draw( painter, rect );
     }
 
@@ -340,5 +340,5 @@
 
 /*!
-  Needs to be overloaded to return a 
+  Needs to be overloaded to return a
   non default symbol for a specific sample
 
@@ -348,5 +348,5 @@
   \return NULL, indicating to use the default symbol
  */
-QwtColumnSymbol *QwtPlotBarChart::specialSymbol( 
+QwtColumnSymbol *QwtPlotBarChart::specialSymbol(
     int sampleIndex, const QPointF &sample ) const
 {
@@ -429,11 +429,11 @@
    displays the default symbol.
 
-   \param index Index of the legend entry 
+   \param index Index of the legend entry
    \param size Icon size
 
-   \sa setLegendMode(), drawBar(), 
+   \sa setLegendMode(), drawBar(),
        QwtPlotItem::setLegendIconSize(), QwtPlotItem::legendData()
  */
-QwtGraphic QwtPlotBarChart::legendIcon( 
+QwtGraphic QwtPlotBarChart::legendIcon(
     int index, const QSizeF &size ) const
 {
@@ -453,5 +453,5 @@
     if ( d_data->legendMode == QwtPlotBarChart::LegendBarTitles )
         barIndex = index;
-        
+
     drawBar( &painter, barIndex, QPointF(), column );
 
Index: trunk/BNC/qwt/qwt_plot_barchart.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_barchart.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_barchart.h	(revision 9383)
@@ -24,6 +24,6 @@
   a specialSymbol(). Otherwise it is rendered using a default symbol.
 
-  Depending on its orientation() the bars are displayed horizontally 
-  or vertically. The bars cover the interval between the baseline() 
+  Depending on its orientation() the bars are displayed horizontally
+  or vertically. The bars cover the interval between the baseline()
   and the value.
 
@@ -51,5 +51,5 @@
     enum LegendMode
     {
-        /*! 
+        /*!
           One entry on the legend showing the default symbol
           and the title() of the chart
@@ -68,5 +68,5 @@
     };
 
-    explicit QwtPlotBarChart( const QString &title = QString::null );
+    explicit QwtPlotBarChart( const QString &title = QString() );
     explicit QwtPlotBarChart( const QwtText &title );
 
@@ -77,5 +77,5 @@
     void setSamples( const QVector<QPointF> & );
     void setSamples( const QVector<double> & );
-    void setSamples( QwtSeriesData<QPointF> *series );
+    void setSamples( QwtSeriesData<QPointF> * );
 
     void setSymbol( QwtColumnSymbol * );
@@ -91,5 +91,5 @@
     virtual QRectF boundingRect() const;
 
-    virtual QwtColumnSymbol *specialSymbol( 
+    virtual QwtColumnSymbol *specialSymbol(
         int sampleIndex, const QPointF& ) const;
 
@@ -103,5 +103,5 @@
 
     virtual void drawBar( QPainter *,
-        int sampleIndex, const QPointF& point, 
+        int sampleIndex, const QPointF& sample,
         const QwtColumnRect & ) const;
 
Index: trunk/BNC/qwt/qwt_plot_canvas.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_canvas.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_canvas.cpp	(revision 9383)
@@ -49,4 +49,10 @@
     }
 
+    virtual void drawRects(const QRect *rects, int count )
+    {
+        // to silence -Woverloaded-virtual
+        QwtNullPaintDevice::drawRects( rects, count );
+    }
+
     virtual void drawPath( const QPainterPath &path )
     {
@@ -73,5 +79,5 @@
         for ( int i = 0; i < path.elementCount(); i++ )
         {
-            QPainterPath::Element el = path.elementAt(i); 
+            QPainterPath::Element el = path.elementAt(i);
             switch( el.type )
             {
@@ -98,5 +104,5 @@
                     {
                         QRectF r = clipRects.last();
-                        r.setCoords( 
+                        r.setCoords(
                             qMin( r.left(), el.x ),
                             qMin( r.top(), el.y ),
@@ -170,5 +176,5 @@
         painter->setClipPath( borderClip, Qt::IntersectClip );
 
-    const QBrush &brush = 
+    const QBrush &brush =
         canvas->palette().brush( canvas->backgroundRole() );
 
@@ -186,6 +192,6 @@
         {
             rects += canvas->rect();
-        } 
-        else 
+        }
+        else
         {
             rects = painter->clipRegion().rects();
@@ -197,5 +203,5 @@
         if ( painter->paintEngine()->type() == QPaintEngine::X11 )
         {
-            // Qt 4.7.1: gradients on X11 are broken ( subrects + 
+            // Qt 4.7.1: gradients on X11 are broken ( subrects +
             // QGradient::StretchToDeviceMode ) and horrible slow.
             // As workaround we have to use the raster paintengine.
@@ -223,5 +229,5 @@
                 }
             }
-            
+
             QImage image( canvas->size(), format );
 
@@ -268,5 +274,5 @@
 }
 
-static QPainterPath qwtCombinePathList( const QRectF &rect, 
+static QPainterPath qwtCombinePathList( const QRectF &rect,
     const QList<QPainterPath> &pathList )
 {
@@ -286,5 +292,5 @@
             if ( br.center().y() < rect.center().y() )
             {
-                if ( qAbs( br.top() - rect.top() ) < 
+                if ( qAbs( br.top() - rect.top() ) <
                     qAbs( br.left() - rect.left() ) )
                 {
@@ -298,5 +304,5 @@
             else
             {
-                if ( qAbs( br.bottom() - rect.bottom() ) < 
+                if ( qAbs( br.bottom() - rect.bottom() ) <
                     qAbs( br.left() - rect.left() ) )
                 {
@@ -316,5 +322,5 @@
             if ( br.center().y() < rect.center().y() )
             {
-                if ( qAbs( br.top() - rect.top() ) < 
+                if ( qAbs( br.top() - rect.top() ) <
                     qAbs( br.right() - rect.right() ) )
                 {
@@ -328,5 +334,5 @@
             else
             {
-                if ( qAbs( br.bottom() - rect.bottom() ) < 
+                if ( qAbs( br.bottom() - rect.bottom() ) <
                     qAbs( br.right() - rect.right() ) )
                 {
@@ -340,5 +346,5 @@
             if ( subPath.currentPosition().y() < br.center().y() )
                 qwtRevertPath( subPath );
-        }   
+        }
         ordered[index] = subPath;
     }
@@ -381,5 +387,5 @@
 }
 
-static inline void qwtDrawStyledBackground( 
+static inline void qwtDrawStyledBackground(
     QWidget *w, QPainter *painter )
 {
@@ -418,5 +424,5 @@
 }
 
-static void qwtFillBackground( QPainter *painter, 
+static void qwtFillBackground( QPainter *painter,
     QWidget *widget, const QVector<QRectF> &fillRects )
 {
@@ -521,5 +527,5 @@
 };
 
-/*! 
+/*!
   \brief Constructor
 
@@ -595,5 +601,5 @@
                     *d_data->backingStore = grab( rect() );
 #else
-                    *d_data->backingStore = 
+                    *d_data->backingStore =
                         QPixmap::grabWidget( this, rect() );
 #endif
@@ -695,17 +701,17 @@
 bool QwtPlotCanvas::event( QEvent *event )
 {
-    if ( event->type() == QEvent::PolishRequest ) 
+    if ( event->type() == QEvent::PolishRequest )
     {
         if ( testPaintAttribute( QwtPlotCanvas::Opaque ) )
         {
-            // Setting a style sheet changes the 
+            // Setting a style sheet changes the
             // Qt::WA_OpaquePaintEvent attribute, but we insist
             // on painting the background.
-            
+
             setAttribute( Qt::WA_OpaquePaintEvent, true );
         }
     }
 
-    if ( event->type() == QEvent::PolishRequest || 
+    if ( event->type() == QEvent::PolishRequest ||
         event->type() == QEvent::StyleChange )
     {
@@ -729,5 +735,12 @@
     {
         QPixmap &bs = *d_data->backingStore;
-        if ( bs.size() != size() )
+
+        qreal pixelRatio = 1.0;
+
+#if QT_VERSION >= 0x050000
+        pixelRatio = bs.devicePixelRatio();
+#endif
+
+        if ( bs.size() != size() * pixelRatio )
         {
             bs = QwtPainter::backingStore( this, size() );
@@ -806,5 +819,5 @@
             drawCanvas( &painter, false );
 
-            if ( frameWidth() > 0 ) 
+            if ( frameWidth() > 0 )
                 drawBorder( &painter );
         }
@@ -815,13 +828,13 @@
 }
 
-void QwtPlotCanvas::drawCanvas( QPainter *painter, bool withBackground ) 
+void QwtPlotCanvas::drawCanvas( QPainter *painter, bool withBackground )
 {
     bool hackStyledBackground = false;
 
-    if ( withBackground && testAttribute( Qt::WA_StyledBackground ) 
+    if ( withBackground && testAttribute( Qt::WA_StyledBackground )
         && testPaintAttribute( HackStyledBackground ) )
     {
         // Antialiasing rounded borders is done by
-        // inserting pixels with colors between the 
+        // inserting pixels with colors between the
         // border color and the color on the canvas,
         // When the border is painted before the plot items
@@ -853,5 +866,5 @@
 
                 painter->setPen( Qt::NoPen );
-                painter->setBrush( d_data->styleSheet.background.brush ); 
+                painter->setBrush( d_data->styleSheet.background.brush );
                 painter->setBrushOrigin( d_data->styleSheet.background.origin );
                 painter->setClipPath( d_data->styleSheet.borderPath );
@@ -894,5 +907,5 @@
     if ( !d_data->styleSheet.borderPath.isEmpty() )
     {
-        painter->setClipPath( 
+        painter->setClipPath(
             d_data->styleSheet.borderPath, Qt::IntersectClip );
     }
@@ -930,5 +943,5 @@
         if ( frameWidth() > 0 )
         {
-            QwtPainter::drawRoundedFrame( painter, QRectF( frameRect() ), 
+            QwtPainter::drawRoundedFrame( painter, QRectF( frameRect() ),
                 d_data->borderRadius, d_data->borderRadius,
                 palette(), frameWidth(), frameStyle() );
@@ -953,5 +966,5 @@
 #endif
 
-        switch (frameShape) 
+        switch (frameShape)
         {
             case QFrame::Box:
@@ -963,7 +976,7 @@
                 opt.lineWidth = lineWidth();
                 opt.midLineWidth = midLineWidth();
-                break; 
-            }
-            default: 
+                break;
+            }
+            default:
             {
                 opt.lineWidth = frameWidth();
@@ -971,5 +984,5 @@
             }
         }
-    
+
         if ( frameShadow == Sunken )
             opt.state |= QStyle::State_Sunken;
@@ -1030,11 +1043,11 @@
 
     QwtStyleSheetRecorder recorder( size() );
-    
+
     QPainter painter( &recorder );
-    
+
     QStyleOption opt;
     opt.initFrom(this);
     style()->drawPrimitive( QStyle::PE_Widget, &opt, &painter, this);
-    
+
     painter.end();
 
@@ -1046,5 +1059,5 @@
         if ( !recorder.border.rectList.isEmpty() )
         {
-            d_data->styleSheet.borderPath = 
+            d_data->styleSheet.borderPath =
                 qwtCombinePathList( rect(), recorder.border.pathList );
         }
@@ -1097,5 +1110,5 @@
         return path;
     }
-    
+
     return QPainterPath();
 }
Index: trunk/BNC/qwt/qwt_plot_canvas.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_canvas.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_canvas.h	(revision 9383)
@@ -20,5 +20,5 @@
 /*!
   \brief Canvas of a QwtPlot.
-  
+
    Canvas is the widget where all plot items are displayed
 
@@ -43,6 +43,6 @@
     {
         /*!
-          \brief Paint double buffered reusing the content 
-                 of the pixmap buffer when possible. 
+          \brief Paint double buffered reusing the content
+                 of the pixmap buffer when possible.
 
           Using a backing store might improve the performance
@@ -60,5 +60,5 @@
 
           When using styled backgrounds Qt assumes, that the
-          canvas doesn't fill its area completely 
+          canvas doesn't fill its area completely
           ( f.e because of rounded borders ) and fills the area
           below the canvas. When this is done with gradients it might
@@ -66,7 +66,7 @@
 
           When the Opaque attribute is enabled the canvas tries to
-          identify the gaps with some heuristics and to fill those only. 
+          identify the gaps with some heuristics and to fill those only.
 
-          \warning Will not work for semitransparent backgrounds 
+          \warning Will not work for semitransparent backgrounds
          */
         Opaque       = 2,
Index: trunk/BNC/qwt/qwt_plot_curve.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_curve.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_curve.cpp	(revision 9383)
@@ -25,5 +25,5 @@
 static void qwtUpdateLegendIconSize( QwtPlotCurve *curve )
 {
-    if ( curve->symbol() && 
+    if ( curve->symbol() &&
         curve->testLegendAttribute( QwtPlotCurve::LegendShowSymbol ) )
     {
@@ -68,5 +68,5 @@
         symbol( NULL ),
         attributes( 0 ),
-        paintAttributes( 
+        paintAttributes(
             QwtPlotCurve::ClipPolygons | QwtPlotCurve::FilterPoints ),
         legendAttributes( 0 )
@@ -225,5 +225,5 @@
 
   The curve will take the ownership of the symbol, hence the previously
-  set symbol will be delete by setting a new one. If \p symbol is 
+  set symbol will be delete by setting a new one. If \p symbol is
   \c NULL no symbol will be drawn.
 
@@ -475,5 +475,5 @@
 
         if ( !doFit && !doFill )
-            doIntegers = true; 
+            doIntegers = true;
     }
 #endif
@@ -488,10 +488,10 @@
     if ( doIntegers )
     {
-        QPolygon polyline = mapper.toPolygon( 
+        QPolygon polyline = mapper.toPolygon(
             xMap, yMap, data(), from, to );
 
         if ( d_data->paintAttributes & ClipPolygons )
         {
-            polyline = QwtClipper::clipPolygon( 
+            polyline = QwtClipper::clipPolygon(
                 clipRect.toAlignedRect(), polyline, false );
         }
@@ -519,5 +519,5 @@
                 if ( d_data->paintAttributes & ClipPolygons )
                 {
-                    polyline = QwtClipper::clipPolygonF( 
+                    polyline = QwtClipper::clipPolygonF(
                         clipRect, polyline, false );
                 }
@@ -557,6 +557,8 @@
 void QwtPlotCurve::drawSticks( QPainter *painter,
     const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-    const QRectF &, int from, int to ) const
-{
+    const QRectF &canvasRect, int from, int to ) const
+{
+    Q_UNUSED( canvasRect )
+
     painter->save();
     painter->setRenderHint( QPainter::Antialiasing, false );
@@ -640,5 +642,5 @@
         mapper.setFlag( QwtPointMapper::WeedOutPoints, false );
 
-        QPolygonF points = mapper.toPointsF( 
+        QPolygonF points = mapper.toPointsF(
             xMap, yMap, data(), from, to );
 
@@ -649,5 +651,5 @@
     {
         const QImage image = mapper.toImage( xMap, yMap,
-            data(), from, to, d_data->pen, 
+            data(), from, to, d_data->pen,
             painter->testRenderHint( QPainter::Antialiasing ),
             renderThreadCount() );
@@ -680,5 +682,5 @@
         {
             const QPolygon points = mapper.toPoints(
-                xMap, yMap, data(), from, to ); 
+                xMap, yMap, data(), from, to );
 
             QwtPainter::drawPoints( painter, points );
@@ -686,5 +688,5 @@
         else
         {
-            const QPolygonF points = mapper.toPointsF( 
+            const QPolygonF points = mapper.toPointsF(
                 xMap, yMap, data(), from, to );
 
@@ -761,6 +763,6 @@
         qreal pw = qMax( qreal( 1.0 ), painter->pen().widthF());
         const QRectF clipRect = canvasRect.adjusted(-pw, -pw, pw, pw);
-        
-        const QPolygonF clipped = QwtClipper::clipPolygonF( 
+
+        const QPolygonF clipped = QwtClipper::clipPolygonF(
             clipRect, polygon, false );
 
@@ -884,5 +886,5 @@
 
 /*!
-  \brief Complete a polygon to be a closed polygon including the 
+  \brief Complete a polygon to be a closed polygon including the
          area between the original polygon and the baseline.
 
@@ -902,5 +904,5 @@
 
     double baseline = d_data->baseline;
-    
+
     if ( orientation() == Qt::Vertical )
     {
@@ -947,7 +949,7 @@
 {
     QwtPointMapper mapper;
-    mapper.setFlag( QwtPointMapper::RoundPoints, 
+    mapper.setFlag( QwtPointMapper::RoundPoints,
         QwtPainter::roundingAlignment( painter ) );
-    mapper.setFlag( QwtPointMapper::WeedOutPoints, 
+    mapper.setFlag( QwtPointMapper::WeedOutPoints,
         testPaintAttribute( QwtPlotCurve::FilterPoints ) );
     mapper.setBoundingRect( canvasRect );
@@ -974,6 +976,6 @@
 
   The interpretation of the baseline depends on the orientation().
-  With Qt::Horizontal, the baseline is interpreted as a horizontal line
-  at y = baseline(), with Qt::Vertical, it is interpreted as a vertical
+  With Qt::Vertical, the baseline is interpreted as a horizontal line
+  at y = baseline(), with Qt::Horizontal, it is interpreted as a vertical
   line at x = baseline().
 
@@ -1050,5 +1052,5 @@
    \return Icon representing the curve on the legend
 
-   \param index Index of the legend entry 
+   \param index Index of the legend entry
                 ( ignored as there is only one )
    \param size Icon size
@@ -1056,5 +1058,5 @@
    \sa QwtPlotItem::setLegendIconSize(), QwtPlotItem::legendData()
  */
-QwtGraphic QwtPlotCurve::legendIcon( int index, 
+QwtGraphic QwtPlotCurve::legendIcon( int index,
     const QSizeF &size ) const
 {
@@ -1154,8 +1156,8 @@
 
 /*!
-  \brief Initialize the data by pointing to memory blocks which 
+  \brief Initialize the data by pointing to memory blocks which
          are not managed by QwtPlotCurve.
 
-  setRawSamples is provided for efficiency. 
+  setRawSamples is provided for efficiency.
   It is important to keep the pointers
   during the lifetime of the underlying QwtCPointerData class.
@@ -1167,5 +1169,5 @@
   \sa QwtCPointerData
 */
-void QwtPlotCurve::setRawSamples( 
+void QwtPlotCurve::setRawSamples(
     const double *xData, const double *yData, int size )
 {
@@ -1184,5 +1186,5 @@
   \sa QwtPointArrayData
 */
-void QwtPlotCurve::setSamples( 
+void QwtPlotCurve::setSamples(
     const double *xData, const double *yData, int size )
 {
Index: trunk/BNC/qwt/qwt_plot_curve.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_curve.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_curve.h	(revision 9383)
@@ -34,5 +34,5 @@
   <dl><dt>a) Assign curve properties</dt>
   <dd>When a curve is created, it is configured to draw black solid lines
-  with in QwtPlotCurve::Lines style and no symbols. 
+  with in QwtPlotCurve::Lines style and no symbols.
   You can change this by calling
   setPen(), setStyle() and setSymbol().</dd>
@@ -53,5 +53,5 @@
   \sa QwtPointSeriesData, QwtSymbol, QwtScaleMap
 */
-class QWT_EXPORT QwtPlotCurve: 
+class QWT_EXPORT QwtPlotCurve:
     public QwtPlotSeriesItem, public QwtSeriesStore<QPointF>
 {
@@ -76,5 +76,5 @@
 
         /*!
-           Draw vertical or horizontal sticks ( depending on the 
+           Draw vertical or horizontal sticks ( depending on the
            orientation() ) from a baseline which is defined by setBaseline().
         */
@@ -91,5 +91,5 @@
            Draw dots at the locations of the data points. Note:
            This is different from a dotted line (see setPen()), and faster
-           as a curve in QwtPlotCurve::NoStyle style and a symbol 
+           as a curve in QwtPlotCurve::NoStyle style and a symbol
            painting a point.
         */
@@ -111,5 +111,5 @@
     {
         /*!
-           For QwtPlotCurve::Steps only. 
+           For QwtPlotCurve::Steps only.
            Draws a step function from the right to the left.
          */
@@ -142,5 +142,5 @@
     {
         /*!
-          QwtPlotCurve tries to find a color representing the curve 
+          QwtPlotCurve tries to find a color representing the curve
           and paints a rectangle with it.
          */
@@ -148,5 +148,5 @@
 
         /*!
-          If the style() is not QwtPlotCurve::NoCurve a line 
+          If the style() is not QwtPlotCurve::NoCurve a line
           is painted with the curve pen().
          */
@@ -192,7 +192,7 @@
 
         /*!
-          Minimize memory usage that is temporarily needed for the 
+          Minimize memory usage that is temporarily needed for the
           translated points, before they get painted.
-          This might slow down the performance of painting 
+          This might slow down the performance of painting
          */
         MinimizeMemory = 0x04,
@@ -201,5 +201,5 @@
           Render the points to a temporary image and paint the image.
           This is a very special optimization for Dots style, when
-          having a huge amount of points. 
+          having a huge amount of points.
           With a reasonable number of points QPainter::drawPoints()
           will be faster.
@@ -211,5 +211,5 @@
     typedef QFlags<PaintAttribute> PaintAttributes;
 
-    explicit QwtPlotCurve( const QString &title = QString::null );
+    explicit QwtPlotCurve( const QString &title = QString() );
     explicit QwtPlotCurve( const QwtText &title );
 
@@ -271,30 +271,30 @@
     void init();
 
-    virtual void drawCurve( QPainter *p, int style,
-        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &canvasRect, int from, int to ) const;
-
-    virtual void drawSymbols( QPainter *p, const QwtSymbol &,
-        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &canvasRect, int from, int to ) const;
-
-    virtual void drawLines( QPainter *p,
-        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &canvasRect, int from, int to ) const;
-
-    virtual void drawSticks( QPainter *p,
-        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &canvasRect, int from, int to ) const;
-
-    virtual void drawDots( QPainter *p,
-        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &canvasRect, int from, int to ) const;
-
-    virtual void drawSteps( QPainter *p,
+    virtual void drawCurve( QPainter *, int style,
+        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
+        const QRectF &canvasRect, int from, int to ) const;
+
+    virtual void drawSymbols( QPainter *, const QwtSymbol &,
+        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
+        const QRectF &canvasRect, int from, int to ) const;
+
+    virtual void drawLines( QPainter *,
+        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
+        const QRectF &canvasRect, int from, int to ) const;
+
+    virtual void drawSticks( QPainter *,
+        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
+        const QRectF &canvasRect, int from, int to ) const;
+
+    virtual void drawDots( QPainter *,
+        const QwtScaleMap &xMap, const QwtScaleMap &yMap,
+        const QRectF &canvasRect, int from, int to ) const;
+
+    virtual void drawSteps( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
         const QRectF &canvasRect, int from, int to ) const;
 
     virtual void fillCurve( QPainter *,
-        const QwtScaleMap &, const QwtScaleMap &, 
+        const QwtScaleMap &, const QwtScaleMap &,
         const QRectF &canvasRect, QPolygonF & ) const;
 
Index: trunk/BNC/qwt/qwt_plot_dict.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_dict.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_dict.cpp	(revision 9383)
@@ -138,6 +138,6 @@
 {
     PrivateData::ItemList list = d_data->itemList;
-    QwtPlotItemIterator it = list.begin();
-    while ( it != list.end() )
+    QwtPlotItemIterator it = list.constBegin();
+    while ( it != list.constEnd() )
     {
         QwtPlotItem *item = *it;
@@ -181,5 +181,5 @@
 
     PrivateData::ItemList list = d_data->itemList;
-    for ( QwtPlotItemIterator it = list.begin(); it != list.end(); ++it )
+    for ( QwtPlotItemIterator it = list.constBegin(); it != list.constEnd(); ++it )
     {
         QwtPlotItem *item = *it;
Index: trunk/BNC/qwt/qwt_plot_directpainter.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_directpainter.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_directpainter.cpp	(revision 9383)
@@ -18,5 +18,5 @@
 #include <qpixmap.h>
 
-static inline void qwtRenderItem( 
+static inline void qwtRenderItem(
     QPainter *painter, const QRect &canvasRect,
     QwtPlotSeriesItem *seriesItem, int from, int to )
@@ -110,5 +110,5 @@
 
 /*!
-  En/Disables clipping 
+  En/Disables clipping
 
   \param enable Enables clipping is true, disable it otherwise
@@ -132,9 +132,9 @@
    \brief Assign a clip region and enable clipping
 
-   Depending on the environment setting a proper clip region might improve 
+   Depending on the environment setting a proper clip region might improve
    the performance heavily. F.e. on Qt embedded only the clipped part of
    the backing store will be copied to a ( maybe unaccelerated ) frame buffer
    device.
-   
+
    \param region Clip region
    \sa clipRegion(), hasClipping(), setClipping()
@@ -201,5 +201,5 @@
 
     bool immediatePaint = true;
-    if ( !canvas->testAttribute( Qt::WA_WState_InPaintEvent ) ) 
+    if ( !canvas->testAttribute( Qt::WA_WState_InPaintEvent ) )
     {
 #if QT_VERSION < 0x050000
@@ -221,5 +221,5 @@
         if ( d_data->hasClipping )
         {
-            d_data->painter.setClipRegion( 
+            d_data->painter.setClipRegion(
                 QRegion( canvasRect ) & d_data->clipRegion );
         }
@@ -295,5 +295,5 @@
             if ( doCopyCache )
             {
-                QwtPlotCanvas *plotCanvas = 
+                QwtPlotCanvas *plotCanvas =
                     qobject_cast<QwtPlotCanvas *>( canvas );
                 if ( plotCanvas )
@@ -302,5 +302,5 @@
                     if ( doCopyCache )
                     {
-                        painter.drawPixmap( plotCanvas->rect().topLeft(), 
+                        painter.drawPixmap( plotCanvas->rect().topLeft(),
                             *plotCanvas->backingStore() );
                     }
Index: trunk/BNC/qwt/qwt_plot_directpainter.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_directpainter.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_directpainter.h	(revision 9383)
@@ -30,5 +30,5 @@
     On certain environments it might be important to calculate a proper
     clip region before painting. F.e. for Qt Embedded only the clipped part
-    of the backing store will be copied to a ( maybe unaccelerated ) 
+    of the backing store will be copied to a ( maybe unaccelerated )
     frame buffer.
 
@@ -62,6 +62,6 @@
         /*!
           When QwtPlotCanvas::BackingStore is enabled the painter
-          has to paint to the backing store and the widget. In certain 
-          situations/environments it might be faster to paint to 
+          has to paint to the backing store and the widget. In certain
+          situations/environments it might be faster to paint to
           the backing store only and then copy the backing store to the canvas.
           This flag can also be useful for settings, where Qt fills the
Index: trunk/BNC/qwt/qwt_plot_glcanvas.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_glcanvas.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_glcanvas.cpp	(revision 9383)
@@ -25,5 +25,5 @@
     for ( ; w->parentWidget() != NULL; w = w->parentWidget() )
     {
-        if ( w->autoFillBackground() || 
+        if ( w->autoFillBackground() ||
             w->testAttribute( Qt::WA_StyledBackground ) )
         {
@@ -66,5 +66,5 @@
 };
 
-/*! 
+/*!
   \brief Constructor
 
@@ -94,7 +94,7 @@
   Set the frame style
 
-  \param style The bitwise OR between a shape and a shadow. 
-  
-  \sa frameStyle(), QFrame::setFrameStyle(), 
+  \param style The bitwise OR between a shape and a shadow.
+
+  \sa frameStyle(), QFrame::setFrameStyle(),
       setFrameShadow(), setFrameShape()
  */
@@ -209,5 +209,5 @@
   \return Midline width of the frame
   \sa setMidLineWidth(), lineWidth()
- */ 
+ */
 int QwtPlotGLCanvas::midLineWidth() const
 {
@@ -279,5 +279,5 @@
 
   \sa QwtPlot::drawCanvas()
-*/  
+*/
 void QwtPlotGLCanvas::drawItems( QPainter *painter )
 {
@@ -296,5 +296,5 @@
   Draw the background of the canvas
   \param painter Painter
-*/ 
+*/
 void QwtPlotGLCanvas::drawBackground( QPainter *painter )
 {
@@ -316,5 +316,5 @@
         w->style()->drawPrimitive( QStyle::PE_Widget, &opt, painter, w);
     }
-    else 
+    else
     {
         painter->fillRect( fillRect,
@@ -337,5 +337,5 @@
     if ( frameShadow() == QwtPlotGLCanvas::Plain )
     {
-        qDrawPlainRect( painter, frameRect(), 
+        qDrawPlainRect( painter, frameRect(),
             palette().shadow().color(), lineWidth() );
     }
@@ -349,5 +349,5 @@
         else
         {
-            qDrawShadePanel( painter, frameRect(), palette(), 
+            qDrawShadePanel( painter, frameRect(), palette(),
                 frameShadow() == Sunken, lineWidth() );
         }
Index: trunk/BNC/qwt/qwt_plot_glcanvas.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_glcanvas.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_glcanvas.h	(revision 9383)
@@ -14,4 +14,5 @@
 #include <qframe.h>
 #include <qgl.h>
+#include <qpainterpath.h>
 
 class QwtPlot;
@@ -19,5 +20,5 @@
 /*!
   \brief An alternative canvas for a QwtPlot derived from QGLWidget
-  
+
   QwtPlotGLCanvas implements the very basics to act as canvas
   inside of a QwtPlot widget. It might be extended to a full
@@ -31,5 +32,5 @@
 
   \note With Qt4 you might want to use the QPaintEngine::OpenGL paint engine
-        ( see QGL::setPreferredPaintEngine() ). On a Linux test system 
+        ( see QGL::setPreferredPaintEngine() ). On a Linux test system
         QPaintEngine::OpenGL2 shows very basic problems like translated
         geometries.
@@ -77,5 +78,5 @@
         to use QFrame::Shadow instead.
 
-        \note QFrame::StyledPanel and QFrame::WinPanel are unsuported 
+        \note QFrame::StyledPanel and QFrame::WinPanel are unsupported
               and will be displayed as QFrame::Panel.
      */
Index: trunk/BNC/qwt/qwt_plot_grid.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_grid.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_grid.h	(revision 9383)
@@ -40,20 +40,20 @@
     virtual int rtti() const;
 
-    void enableX( bool tf );
+    void enableX( bool );
     bool xEnabled() const;
 
-    void enableY( bool tf );
+    void enableY( bool );
     bool yEnabled() const;
 
-    void enableXMin( bool tf );
+    void enableXMin( bool );
     bool xMinEnabled() const;
 
-    void enableYMin( bool tf );
+    void enableYMin( bool );
     bool yMinEnabled() const;
 
-    void setXDiv( const QwtScaleDiv &sx );
+    void setXDiv( const QwtScaleDiv & );
     const QwtScaleDiv &xScaleDiv() const;
 
-    void setYDiv( const QwtScaleDiv &sy );
+    void setYDiv( const QwtScaleDiv & );
     const QwtScaleDiv &yScaleDiv() const;
 
@@ -66,17 +66,17 @@
 
     void setMinorPen( const QColor &, qreal width = 0.0, Qt::PenStyle = Qt::SolidLine );
-    void setMinorPen( const QPen &p );
+    void setMinorPen( const QPen & );
     const QPen& minorPen() const;
 
-    virtual void draw( QPainter *p,
+    virtual void draw( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &rect ) const;
+        const QRectF &canvasRect ) const;
 
-    virtual void updateScaleDiv( 
-        const QwtScaleDiv &xMap, const QwtScaleDiv &yMap );
+    virtual void updateScaleDiv(
+        const QwtScaleDiv &xScaleDiv, const QwtScaleDiv &yScaleDiv );
 
 private:
-    void drawLines( QPainter *painter, const QRectF &,
-        Qt::Orientation orientation, const QwtScaleMap &,
+    void drawLines( QPainter *, const QRectF &,
+        Qt::Orientation, const QwtScaleMap &,
         const QList<double> & ) const;
 
Index: trunk/BNC/qwt/qwt_plot_histogram.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_histogram.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_histogram.cpp	(revision 9383)
@@ -123,19 +123,19 @@
 /*!
   Build and assign a pen
-    
+
   In Qt5 the default pen width is 1.0 ( 0.0 in Qt4 ) what makes it
   non cosmetic ( see QPen::isCosmetic() ). This method has been introduced
   to hide this incompatibility.
-    
+
   \param color Pen color
   \param width Pen width
   \param style Pen style
-    
+
   \sa pen(), brush()
  */
 void QwtPlotHistogram::setPen( const QColor &color, qreal width, Qt::PenStyle style )
-{   
+{
     setPen( QPen( color, width, style ) );
-}   
+}
 
 /*!
@@ -304,13 +304,13 @@
 /*!
   Assign a series of samples
-    
+
   setSamples() is just a wrapper for setData() without any additional
   value - beside that it is easier to find for the developer.
-    
+
   \param data Data
   \warning The item takes ownership of the data object, deleting
            it when its not used anymore.
 */
-void QwtPlotHistogram::setSamples( 
+void QwtPlotHistogram::setSamples(
     QwtSeriesData<QwtIntervalSample> *data )
 {
@@ -333,6 +333,8 @@
 void QwtPlotHistogram::drawSeries( QPainter *painter,
     const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-    const QRectF &, int from, int to ) const
-{
+    const QRectF &canvasRect, int from, int to ) const
+{
+    Q_UNUSED( canvasRect )
+
     if ( !painter || dataSize() <= 0 )
         return;
@@ -676,9 +678,9 @@
   A plain rectangle without pen using the brush()
 
-  \param index Index of the legend entry 
+  \param index Index of the legend entry
                 ( ignored as there is only one )
   \param size Icon size
   \return A graphic displaying the icon
-    
+
   \sa QwtPlotItem::setLegendIconSize(), QwtPlotItem::legendData()
 */
Index: trunk/BNC/qwt/qwt_plot_histogram.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_histogram.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_histogram.h	(revision 9383)
@@ -37,5 +37,5 @@
 */
 
-class QWT_EXPORT QwtPlotHistogram: 
+class QWT_EXPORT QwtPlotHistogram:
     public QwtPlotSeriesItem, public QwtSeriesStore<QwtIntervalSample>
 {
@@ -59,5 +59,5 @@
         /*!
            Draw a column for each interval. When a symbol() has been set
-           the symbol is used otherwise the column is displayed as 
+           the symbol is used otherwise the column is displayed as
            plain rectangle using pen() and brush().
          */
@@ -77,5 +77,5 @@
     };
 
-    explicit QwtPlotHistogram( const QString &title = QString::null );
+    explicit QwtPlotHistogram( const QString &title = QString() );
     explicit QwtPlotHistogram( const QwtText &title );
     virtual ~QwtPlotHistogram();
@@ -93,5 +93,5 @@
     void setSamples( QwtSeriesData<QwtIntervalSample> * );
 
-    void setBaseline( double reference );
+    void setBaseline( double );
     double baseline() const;
 
@@ -102,5 +102,5 @@
     const QwtColumnSymbol *symbol() const;
 
-    virtual void drawSeries( QPainter *p,
+    virtual void drawSeries( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
         const QRectF &canvasRect, int from, int to ) const;
Index: trunk/BNC/qwt/qwt_plot_intervalcurve.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_intervalcurve.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_intervalcurve.cpp	(revision 9383)
@@ -154,13 +154,13 @@
 /*!
   Assign a series of samples
-    
+
   setSamples() is just a wrapper for setData() without any additional
   value - beside that it is easier to find for the developer.
-    
+
   \param data Data
   \warning The item takes ownership of the data object, deleting
            it when its not used anymore.
 */
-void QwtPlotIntervalCurve::setSamples( 
+void QwtPlotIntervalCurve::setSamples(
     QwtSeriesData<QwtIntervalSample> *data )
 {
@@ -223,19 +223,19 @@
 /*!
   Build and assign a pen
-    
+
   In Qt5 the default pen width is 1.0 ( 0.0 in Qt4 ) what makes it
   non cosmetic ( see QPen::isCosmetic() ). This method has been introduced
   to hide this incompatibility.
-    
+
   \param color Pen color
   \param width Pen width
   \param style Pen style
-    
+
   \sa pen(), brush()
  */
 void QwtPlotIntervalCurve::setPen( const QColor &color, qreal width, Qt::PenStyle style )
-{   
+{
     setPen( QPen( color, width, style ) );
-}   
+}
 
 /*!
@@ -299,5 +299,5 @@
 {
     QRectF rect = QwtPlotSeriesItem::boundingRect();
-    if ( rect.isValid() && orientation() == Qt::Vertical )
+    if ( orientation() == Qt::Vertical )
         rect.setRect( rect.y(), rect.x(), rect.height(), rect.width() );
 
@@ -546,11 +546,11 @@
   If a symbol is assigned it is scaled to size.
 
-  \param index Index of the legend entry 
+  \param index Index of the legend entry
                ( ignored as there is only one )
   \param size Icon size
-    
+
   \sa QwtPlotItem::setLegendIconSize(), QwtPlotItem::legendData()
 */
-QwtGraphic QwtPlotIntervalCurve::legendIcon( 
+QwtGraphic QwtPlotIntervalCurve::legendIcon(
     int index, const QSizeF &size ) const
 {
Index: trunk/BNC/qwt/qwt_plot_intervalcurve.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_intervalcurve.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_intervalcurve.h	(revision 9383)
@@ -25,5 +25,5 @@
   to display error bars or the area between 2 curves.
 */
-class QWT_EXPORT QwtPlotIntervalCurve: 
+class QWT_EXPORT QwtPlotIntervalCurve:
     public QwtPlotSeriesItem, public QwtSeriesStore<QwtIntervalSample>
 {
@@ -77,5 +77,5 @@
     typedef QFlags<PaintAttribute> PaintAttributes;
 
-    explicit QwtPlotIntervalCurve( const QString &title = QString::null );
+    explicit QwtPlotIntervalCurve( const QString &title = QString() );
     explicit QwtPlotIntervalCurve( const QwtText &title );
 
@@ -103,5 +103,5 @@
     const QwtIntervalSymbol *symbol() const;
 
-    virtual void drawSeries( QPainter *p,
+    virtual void drawSeries( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
         const QRectF &canvasRect, int from, int to ) const;
Index: trunk/BNC/qwt/qwt_plot_item.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_item.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_item.cpp	(revision 9383)
@@ -95,5 +95,5 @@
 
 /*!
-   \brief This method detaches a QwtPlotItem from any 
+   \brief This method detaches a QwtPlotItem from any
           QwtPlot it has been associated with.
 
@@ -305,6 +305,6 @@
 
 /*!
-   On multi core systems rendering of certain plot item 
-   ( f.e QwtPlotRasterItem ) can be done in parallel in 
+   On multi core systems rendering of certain plot item
+   ( f.e QwtPlotRasterItem ) can be done in parallel in
    several threads.
 
@@ -363,5 +363,5 @@
    The default implementation returns an invalid icon
 
-   \param index Index of the legend entry 
+   \param index Index of the legend entry
                 ( usually there is only one )
    \param size Icon size
@@ -369,5 +369,5 @@
    \sa setLegendIconSize(), legendData()
  */
-QwtGraphic QwtPlotItem::legendIcon( 
+QwtGraphic QwtPlotItem::legendIcon(
     int index, const QSizeF &size ) const
 {
@@ -389,20 +389,20 @@
    \return A filled rectangle
  */
-QwtGraphic QwtPlotItem::defaultIcon( 
+QwtGraphic QwtPlotItem::defaultIcon(
     const QBrush &brush, const QSizeF &size ) const
-{   
+{
     QwtGraphic icon;
     if ( !size.isEmpty() )
     {
         icon.setDefaultSize( size );
-        
+
         QRectF r( 0, 0, size.width(), size.height() );
-        
+
         QPainter painter( &icon );
         painter.fillRect( r, brush );
-    }   
-    
+    }
+
     return icon;
-}   
+}
 
 //! Show the item
@@ -558,9 +558,9 @@
    \param bottom Returns the bottom margin
 
-   \return The default implementation returns 0 for all margins
+   The default implementation returns 0 for all margins
 
    \sa QwtPlot::getCanvasMarginsHint(), QwtPlot::updateCanvasMargins()
  */
-void QwtPlotItem::getCanvasMarginHint( const QwtScaleMap &xMap, 
+void QwtPlotItem::getCanvasMarginHint( const QwtScaleMap &xMap,
     const QwtScaleMap &yMap, const QRectF &canvasRect,
     double &left, double &top, double &right, double &bottom ) const
@@ -583,9 +583,9 @@
 
    QwtLegendData is basically a list of QVariants that makes it
-   possible to overload and reimplement legendData() to 
+   possible to overload and reimplement legendData() to
    return almost any type of information, that is understood
    by the receiver that acts as the legend.
 
-   The default implementation returns one entry with 
+   The default implementation returns one entry with
    the title() of the item and the legendIcon().
 
@@ -599,17 +599,17 @@
     QwtText label = title();
     label.setRenderFlags( label.renderFlags() & Qt::AlignLeft );
-            
+
     QVariant titleValue;
     qVariantSetValue( titleValue, label );
     data.setValue( QwtLegendData::TitleRole, titleValue );
-        
+
     const QwtGraphic graphic = legendIcon( 0, legendIconSize() );
     if ( !graphic.isNull() )
-    {   
+    {
         QVariant iconValue;
         qVariantSetValue( iconValue, graphic );
         data.setValue( QwtLegendData::IconRole, iconValue );
-    }   
-        
+    }
+
     QList<QwtLegendData> list;
     list += data;
@@ -659,5 +659,5 @@
          legendData() and legendIcon()
  */
-void QwtPlotItem::updateLegend( const QwtPlotItem *item, 
+void QwtPlotItem::updateLegend( const QwtPlotItem *item,
     const QList<QwtLegendData> &data )
 {
Index: trunk/BNC/qwt/qwt_plot_item.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_item.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_item.h	(revision 9383)
@@ -124,5 +124,5 @@
         Rtti_PlotZone,
 
-        /*! 
+        /*!
            Values >= Rtti_PlotUserItem are reserved for plot items
            not implemented in the Qwt library.
@@ -135,7 +135,7 @@
 
        Various aspects of a plot widget depend on the attributes of
-       the attached plot items. If and how a single plot item 
+       the attached plot items. If and how a single plot item
        participates in these updates depends on its attributes.
-       
+
        \sa setItemAttribute(), testItemAttribute(), ItemInterest
      */
@@ -154,5 +154,5 @@
         /*!
            The item needs extra space to display something outside
-           its bounding rectangle. 
+           its bounding rectangle.
            \sa getCanvasMarginHint()
          */
@@ -175,5 +175,5 @@
     enum ItemInterest
     {
-        /*! 
+        /*!
            The item is interested in updates of the scales
            \sa updateScaleDiv()
@@ -181,5 +181,5 @@
         ScaleInterest = 0x01,
 
-        /*! 
+        /*!
            The item is interested in updates of the legend ( of other items )
            This flag is intended for items, that want to implement a legend
@@ -269,10 +269,10 @@
     virtual QRectF boundingRect() const;
 
-    virtual void getCanvasMarginHint( 
+    virtual void getCanvasMarginHint(
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &canvasSize,
+        const QRectF &canvasRect,
         double &left, double &top, double &right, double &bottom) const;
 
-    virtual void updateScaleDiv( 
+    virtual void updateScaleDiv(
         const QwtScaleDiv&, const QwtScaleDiv& );
 
Index: trunk/BNC/qwt/qwt_plot_layout.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_layout.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_layout.cpp	(revision 9383)
@@ -164,6 +164,6 @@
     // canvas
 
-    plot->canvas()->getContentsMargins( 
-        &canvas.contentsMargins[ QwtPlot::yLeft ], 
+    plot->canvas()->getContentsMargins(
+        &canvas.contentsMargins[ QwtPlot::yLeft ],
         &canvas.contentsMargins[ QwtPlot::xTop ],
         &canvas.contentsMargins[ QwtPlot::yRight ],
@@ -845,14 +845,14 @@
   \param dimTitle Expanded height of the title widget
   \param dimFooter Expanded height of the footer widget
-  \param dimAxis Expanded heights of the axis in axis orientation.
+  \param dimAxes Expanded heights of the axis in axis orientation.
 
   \sa Options
 */
 void QwtPlotLayout::expandLineBreaks( Options options, const QRectF &rect,
-    int &dimTitle, int &dimFooter, int dimAxis[QwtPlot::axisCnt] ) const
+    int &dimTitle, int &dimFooter, int dimAxes[QwtPlot::axisCnt] ) const
 {
     dimTitle = dimFooter = 0;
     for ( int axis = 0; axis < QwtPlot::axisCnt; axis++ )
-        dimAxis[axis] = 0;
+        dimAxes[axis] = 0;
 
     int backboneOffset[QwtPlot::axisCnt];
@@ -889,5 +889,5 @@
             {
                 // center to the canvas
-                w -= dimAxis[QwtPlot::yLeft] + dimAxis[QwtPlot::yRight];
+                w -= dimAxes[QwtPlot::yLeft] + dimAxes[QwtPlot::yRight];
             }
 
@@ -912,5 +912,5 @@
             {
                 // center to the canvas
-                w -= dimAxis[QwtPlot::yLeft] + dimAxis[QwtPlot::yRight];
+                w -= dimAxes[QwtPlot::yLeft] + dimAxes[QwtPlot::yRight];
             }
 
@@ -936,29 +936,29 @@
                 if ( axis == QwtPlot::xTop || axis == QwtPlot::xBottom )
                 {
-                    length = rect.width() - dimAxis[QwtPlot::yLeft]
-                        - dimAxis[QwtPlot::yRight];
+                    length = rect.width() - dimAxes[QwtPlot::yLeft]
+                        - dimAxes[QwtPlot::yRight];
                     length -= scaleData.start + scaleData.end;
 
-                    if ( dimAxis[QwtPlot::yRight] > 0 )
+                    if ( dimAxes[QwtPlot::yRight] > 0 )
                         length -= 1;
 
-                    length += qMin( dimAxis[QwtPlot::yLeft],
+                    length += qMin( dimAxes[QwtPlot::yLeft],
                         scaleData.start - backboneOffset[QwtPlot::yLeft] );
-                    length += qMin( dimAxis[QwtPlot::yRight],
+                    length += qMin( dimAxes[QwtPlot::yRight],
                         scaleData.end - backboneOffset[QwtPlot::yRight] );
                 }
                 else // QwtPlot::yLeft, QwtPlot::yRight
                 {
-                    length = rect.height() - dimAxis[QwtPlot::xTop]
-                        - dimAxis[QwtPlot::xBottom];
+                    length = rect.height() - dimAxes[QwtPlot::xTop]
+                        - dimAxes[QwtPlot::xBottom];
                     length -= scaleData.start + scaleData.end;
                     length -= 1;
 
-                    if ( dimAxis[QwtPlot::xBottom] <= 0 )
+                    if ( dimAxes[QwtPlot::xBottom] <= 0 )
                         length -= 1;
-                    if ( dimAxis[QwtPlot::xTop] <= 0 )
+                    if ( dimAxes[QwtPlot::xTop] <= 0 )
                         length -= 1;
 
-                    if ( dimAxis[QwtPlot::xBottom] > 0 )
+                    if ( dimAxes[QwtPlot::xBottom] > 0 )
                     {
                         length += qMin(
@@ -966,5 +966,5 @@
                             double( scaleData.start - backboneOffset[QwtPlot::xBottom] ) );
                     }
-                    if ( dimAxis[QwtPlot::xTop] > 0 )
+                    if ( dimAxes[QwtPlot::xTop] > 0 )
                     {
                         length += qMin(
@@ -984,7 +984,7 @@
 
 
-                if ( d > dimAxis[axis] )
-                {
-                    dimAxis[axis] = d;
+                if ( d > dimAxes[axis] )
+                {
+                    dimAxes[axis] = d;
                     done = false;
                 }
@@ -1020,5 +1020,5 @@
         if ( !( options & IgnoreFrames ) )
         {
-            backboneOffset[axis] += 
+            backboneOffset[axis] +=
                 d_data->layoutData.canvas.contentsMargins[axis];
         }
@@ -1089,5 +1089,5 @@
                     const double cRight = canvasRect.right(); // qreal -> double
                     canvasRect.setRight( qMin( cRight, axisRect.right() + dx ) );
-                }   
+                }
 
                 const double maxRight = rightScaleRect.right();
Index: trunk/BNC/qwt/qwt_plot_layout.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_layout.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_layout.h	(revision 9383)
@@ -42,5 +42,5 @@
         IgnoreScrollbars = 0x02,
 
-        //! Ignore all frames. 
+        //! Ignore all frames.
         IgnoreFrames = 0x04,
 
@@ -62,5 +62,5 @@
 
     void setCanvasMargin( int margin, int axis = -1 );
-    int canvasMargin( int axis ) const;
+    int canvasMargin( int axisId ) const;
 
     void setAlignCanvasToScales( bool );
@@ -82,5 +82,5 @@
 
     virtual void activate( const QwtPlot *,
-        const QRectF &rect, Options options = 0x00 );
+        const QRectF &plotRect, Options options = Options() );
 
     virtual void invalidate();
Index: trunk/BNC/qwt/qwt_plot_legenditem.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_legenditem.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_legenditem.cpp	(revision 9383)
@@ -49,5 +49,5 @@
 };
 
-QwtLegendLayoutItem::QwtLegendLayoutItem( 
+QwtLegendLayoutItem::QwtLegendLayoutItem(
         const QwtPlotLegendItem *legendItem, const QwtPlotItem *plotItem ):
     d_legendItem( legendItem ),
@@ -167,5 +167,5 @@
 };
 
-//! Constructor 
+//! Constructor
 QwtPlotLegendItem::QwtPlotLegendItem():
     QwtPlotItem( QwtText( "Legend" ) )
@@ -194,5 +194,5 @@
 
   Alignment means the position of the legend relative
-  to the geometry of the plot canvas. 
+  to the geometry of the plot canvas.
 
   \param alignment Alignment flags
@@ -200,5 +200,5 @@
   \sa alignment(), setMaxColumns()
 
-  \note To align a legend with many items horizontally 
+  \note To align a legend with many items horizontally
         the number of columns need to be limited
  */
@@ -262,5 +262,5 @@
     if ( margin != this->margin() )
     {
-        d_data->layout->setContentsMargins( 
+        d_data->layout->setContentsMargins(
             margin, margin, margin, margin );
 
@@ -418,5 +418,5 @@
 /*!
   Set the radius for the border
-  
+
   \param radius A value <= 0 defines a rectangular border
   \sa borderRadius(), setBorderPen()
@@ -495,5 +495,5 @@
   \brief Set the background mode
 
-  Depending on the mode the complete legend or each item 
+  Depending on the mode the complete legend or each item
   might have an background.
 
@@ -511,5 +511,5 @@
 }
 
-/*! 
+/*!
   \return backgroundMode
   \sa setBackgroundMode(), backgroundBrush(), drawBackground()
@@ -568,8 +568,8 @@
     if ( d_data->backgroundMode == QwtPlotLegendItem::LegendBackground )
         drawBackground( painter, d_data->layout->geometry() );
-    
+
     for ( int i = 0; i <  d_data->layout->count(); i++ )
     {
-        const QwtLegendLayoutItem *layoutItem = 
+        const QwtLegendLayoutItem *layoutItem =
             static_cast<QwtLegendLayoutItem *>( d_data->layout->itemAt( i ) );
 
@@ -595,5 +595,5 @@
       setBackgroundBrush(), setBackgroundMode()
  */
-void QwtPlotLegendItem::drawBackground( 
+void QwtPlotLegendItem::drawBackground(
     QPainter *painter, const QRectF &rect ) const
 {
@@ -602,8 +602,8 @@
     painter->setPen( d_data->borderPen );
     painter->setBrush( d_data->backgroundBrush );
-    
+
     const double radius = d_data->borderRadius;
     painter->drawRoundedRect( rect, radius, radius );
-    
+
     painter->restore();
 }
@@ -624,5 +624,5 @@
     {
         int x = qRound( canvasRect.center().x() );
-        rect.moveCenter( QPoint( x, rect.center().y() ) ); 
+        rect.moveCenter( QPoint( x, rect.center().y() ) );
     }
     else if ( d_data->alignment & Qt::AlignRight )
@@ -630,5 +630,5 @@
         rect.moveRight( qFloor( canvasRect.right() - margin ) );
     }
-    else 
+    else
     {
         rect.moveLeft( qCeil( canvasRect.left() + margin ) );
@@ -644,7 +644,7 @@
         rect.moveBottom( qFloor( canvasRect.bottom() - margin ) );
     }
-    else 
-    {
-        rect.moveTop( qCeil( canvasRect.top() + margin ) ); 
+    else
+    {
+        rect.moveTop( qCeil( canvasRect.top() + margin ) );
     }
 
@@ -653,5 +653,5 @@
 
 /*!
-  Update the legend items according to modifications of a 
+  Update the legend items according to modifications of a
   plot item
 
@@ -667,5 +667,5 @@
     QList<QwtLegendLayoutItem *> layoutItems;
 
-    QMap<const QwtPlotItem *, QList<QwtLegendLayoutItem *> >::iterator it = 
+    QMap<const QwtPlotItem *, QList<QwtLegendLayoutItem *> >::iterator it =
         d_data->map.find( plotItem );
     if ( it != d_data->map.end() )
@@ -692,5 +692,5 @@
             for ( int i = 0; i < data.size(); i++ )
             {
-                QwtLegendLayoutItem *layoutItem = 
+                QwtLegendLayoutItem *layoutItem =
                     new QwtLegendLayoutItem( this, plotItem );
                 d_data->layout->addItem( layoutItem );
@@ -741,5 +741,5 @@
  */
 void QwtPlotLegendItem::drawLegendData( QPainter *painter,
-    const QwtPlotItem *plotItem, const QwtLegendData &data, 
+    const QwtPlotItem *plotItem, const QwtLegendData &data,
     const QRectF &rect ) const
 {
@@ -758,5 +758,5 @@
         QRectF iconRect( r.topLeft(), graphic.defaultSize() );
 
-        iconRect.moveCenter( 
+        iconRect.moveCenter(
             QPoint( iconRect.center().x(), rect.center().y() ) );
 
@@ -822,5 +822,5 @@
   \param width Width
 */
-int QwtPlotLegendItem::heightForWidth( 
+int QwtPlotLegendItem::heightForWidth(
     const QwtLegendData &data, int width ) const
 {
@@ -842,5 +842,5 @@
 }
 
-/*! 
+/*!
   \return All plot items with an entry on the legend
   \note A plot item might have more than one entry on the legend
@@ -855,5 +855,5 @@
   \note Usually a plot item has only one entry on the legend
 */
-QList< QRect > QwtPlotLegendItem::legendGeometries( 
+QList< QRect > QwtPlotLegendItem::legendGeometries(
     const QwtPlotItem *plotItem ) const
 {
Index: trunk/BNC/qwt/qwt_plot_legenditem.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_legenditem.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_legenditem.h	(revision 9383)
@@ -24,17 +24,17 @@
   to have more space for the plot canvas.
 
-  In opposite to QwtLegend the legend item is not interactive. 
+  In opposite to QwtLegend the legend item is not interactive.
   To identify mouse clicks on a legend item an event filter
   needs to be installed catching mouse events ob the plot canvas.
   The geometries of the legend items are available using
   legendGeometries().
-  
-  The legend item is aligned to plot canvas according to 
+
+  The legend item is aligned to plot canvas according to
   its alignment() flags. It might have a background for the
   complete legend ( usually semi transparent ) or for
   each legend item.
 
-  \note An external QwtLegend with a transparent background 
-        on top the plot canvas might be another option 
+  \note An external QwtLegend with a transparent background
+        on top the plot canvas might be another option
         with a similar effect.
 */
@@ -46,5 +46,5 @@
       \brief Background mode
 
-      Depending on the mode the complete legend or each item 
+      Depending on the mode the complete legend or each item
       might have an background.
 
@@ -84,9 +84,9 @@
     void setItemSpacing( int );
     int itemSpacing() const;
-    
+
     void setFont( const QFont& );
     QFont font() const;
 
-    void setBorderDistance( int numPixels );
+    void setBorderDistance( int );
     int borderDistance() const;
 
@@ -106,7 +106,7 @@
     QPen textPen() const;
 
-    virtual void draw( QPainter *p,
+    virtual void draw( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &rect ) const;
+        const QRectF &canvasRect ) const;
 
     void clearLegend();
@@ -118,5 +118,5 @@
 
     virtual QSize minimumSize( const QwtLegendData & ) const;
-    virtual int heightForWidth( const QwtLegendData &, int w ) const;
+    virtual int heightForWidth( const QwtLegendData &, int width ) const;
 
     QList< const QwtPlotItem * > plotItems() const;
@@ -124,5 +124,5 @@
 
 protected:
-    virtual void drawLegendData( QPainter *painter, 
+    virtual void drawLegendData( QPainter *painter,
         const QwtPlotItem *, const QwtLegendData &, const QRectF & ) const;
 
Index: trunk/BNC/qwt/qwt_plot_marker.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_marker.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_marker.cpp	(revision 9383)
@@ -135,5 +135,5 @@
     const QRectF &canvasRect ) const
 {
-    const QPointF pos( xMap.transform( d_data->xValue ), 
+    const QPointF pos( xMap.transform( d_data->xValue ),
         yMap.transform( d_data->yValue ) );
 
@@ -148,5 +148,5 @@
         const QSizeF sz = d_data->symbol->size();
 
-        const QRectF clipRect = canvasRect.adjusted( 
+        const QRectF clipRect = canvasRect.adjusted(
             -sz.width(), -sz.height(), sz.width(), sz.height() );
 
@@ -338,5 +338,5 @@
 /*!
   \brief Set the line style
-  \param style Line style. 
+  \param style Line style.
   \sa lineStyle()
 */
@@ -424,5 +424,5 @@
   In all other styles the alignment is relative to the marker's position.
 
-  \param align Alignment. 
+  \param align Alignment.
   \sa labelAlignment(), labelOrientation()
 */
@@ -503,19 +503,19 @@
 }
 
-/*! 
+/*!
   Build and assign a line pen
-    
+
   In Qt5 the default pen width is 1.0 ( 0.0 in Qt4 ) what makes it
   non cosmetic ( see QPen::isCosmetic() ). This method has been introduced
   to hide this incompatibility.
-    
+
   \param color Pen color
   \param width Pen width
   \param style Pen style
-    
+
   \sa pen(), brush()
- */ 
+ */
 void QwtPlotMarker::setLinePen( const QColor &color, qreal width, Qt::PenStyle style )
-{   
+{
     setLinePen( QPen( color, width, style ) );
 }
@@ -549,5 +549,17 @@
 QRectF QwtPlotMarker::boundingRect() const
 {
-    return QRectF( d_data->xValue, d_data->yValue, 0.0, 0.0 );
+    // width/height of -1 does not affect the autoscale calculation
+
+    switch (d_data->style)
+    {
+        case QwtPlotMarker::HLine:
+            return QRectF( d_data->xValue, d_data->yValue, -1.0, 0.0 );
+
+        case QwtPlotMarker::VLine:
+            return QRectF( d_data->xValue, d_data->yValue, 0.0, -1.0 );
+
+        default :
+            return QRectF( d_data->xValue, d_data->yValue, 0.0, 0.0 );
+    }
 }
 
@@ -555,5 +567,5 @@
    \return Icon representing the marker on the legend
 
-   \param index Index of the legend entry 
+   \param index Index of the legend entry
                 ( usually there is only one )
    \param size Icon size
@@ -586,5 +598,5 @@
             const double y = 0.5 * size.height();
 
-            QwtPainter::drawLine( &painter, 
+            QwtPainter::drawLine( &painter,
                 0.0, y, size.width(), y );
         }
@@ -595,5 +607,5 @@
             const double x = 0.5 * size.width();
 
-            QwtPainter::drawLine( &painter, 
+            QwtPainter::drawLine( &painter,
                 x, 0.0, x, size.height() );
         }
Index: trunk/BNC/qwt/qwt_plot_marker.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_marker.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_marker.h	(revision 9383)
@@ -38,9 +38,9 @@
   line style. The alignment refers to the center point of
   the marker, which means, for example, that the label would be printed
-  left above the center point if the alignment was set to 
+  left above the center point if the alignment was set to
   Qt::AlignLeft | Qt::AlignTop.
 
   \note QwtPlotTextLabel is intended to align a text label
-        according to the geometry of canvas 
+        according to the geometry of canvas
         ( unrelated to plot coordinates )
 */
@@ -69,5 +69,5 @@
     };
 
-    explicit QwtPlotMarker( const QString &title = QString::null );
+    explicit QwtPlotMarker( const QString &title = QString() );
     explicit QwtPlotMarker( const QwtText &title );
 
@@ -85,9 +85,9 @@
     void setValue( const QPointF & );
 
-    void setLineStyle( LineStyle st );
+    void setLineStyle( LineStyle );
     LineStyle lineStyle() const;
 
     void setLinePen( const QColor &, qreal width = 0.0, Qt::PenStyle = Qt::SolidLine );
-    void setLinePen( const QPen &p );
+    void setLinePen( const QPen & );
     const QPen &linePen() const;
 
@@ -107,5 +107,5 @@
     int spacing() const;
 
-    virtual void draw( QPainter *p,
+    virtual void draw( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
         const QRectF & ) const;
@@ -116,8 +116,8 @@
 
 protected:
-    virtual void drawLines( QPainter *, 
+    virtual void drawLines( QPainter *,
         const QRectF &, const QPointF & ) const;
 
-    virtual void drawLabel( QPainter *, 
+    virtual void drawLabel( QPainter *,
         const QRectF &, const QPointF & ) const;
 
Index: trunk/BNC/qwt/qwt_plot_multi_barchart.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_multi_barchart.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_multi_barchart.cpp	(revision 9383)
@@ -109,17 +109,17 @@
 /*!
   Assign a series of samples
-    
+
   setSamples() is just a wrapper for setData() without any additional
   value - beside that it is easier to find for the developer.
-    
+
   \param data Data
   \warning The item takes ownership of the data object, deleting
            it when its not used anymore.
-*/  
-void QwtPlotMultiBarChart::setSamples( 
+*/
+void QwtPlotMultiBarChart::setSamples(
     QwtSeriesData<QwtSetSample> *data )
-{       
+{
     setData( data );
-}       
+}
 
 /*!
@@ -138,5 +138,5 @@
 }
 
-/*! 
+/*!
   \return Bar titles
   \sa setBarTitles(), legendData()
@@ -163,5 +163,5 @@
         return;
 
-    QMap<int, QwtColumnSymbol *>::iterator it = 
+    QMap<int, QwtColumnSymbol *>::iterator it =
         d_data->symbolMap.find(valueIndex);
     if ( it == d_data->symbolMap.end() )
@@ -207,7 +207,7 @@
 {
     QMap<int, QwtColumnSymbol *>::const_iterator it =
-        d_data->symbolMap.find( valueIndex );
-
-    return ( it == d_data->symbolMap.end() ) ? NULL : it.value();
+        d_data->symbolMap.constFind( valueIndex );
+
+    return ( it == d_data->symbolMap.constEnd() ) ? NULL : it.value();
 }
 
@@ -220,10 +220,10 @@
   \sa setSymbol(), specialSymbol(), drawBar()
 */
-QwtColumnSymbol *QwtPlotMultiBarChart::symbol( int valueIndex ) 
-{
-    QMap<int, QwtColumnSymbol *>::iterator it =
-        d_data->symbolMap.find( valueIndex );
-
-    return ( it == d_data->symbolMap.end() ) ? NULL : it.value();
+QwtColumnSymbol *QwtPlotMultiBarChart::symbol( int valueIndex )
+{
+    QMap<int, QwtColumnSymbol *>::const_iterator it =
+        d_data->symbolMap.constFind( valueIndex );
+
+    return ( it == d_data->symbolMap.constEnd() ) ? NULL : it.value();
 }
 
@@ -233,10 +233,5 @@
 void QwtPlotMultiBarChart::resetSymbolMap()
 {
-    for ( QMap<int, QwtColumnSymbol *>::iterator it 
-        = d_data->symbolMap.begin(); it != d_data->symbolMap.end(); ++it )
-    {
-        delete it.value();
-    }
-
+    qDeleteAll( d_data->symbolMap );
     d_data->symbolMap.clear();
 }
@@ -253,5 +248,5 @@
 
   When no symbol ( NULL ) is returned, the value will be displayed
-  with the standard symbol that is used for all symbols with the same 
+  with the standard symbol that is used for all symbols with the same
   valueIndex.
 
@@ -260,7 +255,7 @@
 
   \return NULL, meaning that the value is not special
-    
+
  */
-QwtColumnSymbol *QwtPlotMultiBarChart::specialSymbol( 
+QwtColumnSymbol *QwtPlotMultiBarChart::specialSymbol(
     int sampleIndex, int valueIndex ) const
 {
@@ -456,5 +451,5 @@
   \param index Index of the sample to be painted
   \param sampleWidth Boundng width for all bars of the smaple
-  \param sample Sample 
+  \param sample Sample
 
   \sa drawSeries(), sampleWidth()
@@ -536,5 +531,5 @@
   \param index Index of the sample to be painted
   \param sampleWidth Width of the bars
-  \param sample Sample 
+  \param sample Sample
 
   \sa drawSeries(), sampleWidth()
@@ -542,5 +537,5 @@
 void QwtPlotMultiBarChart::drawStackedBars( QPainter *painter,
     const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-    const QRectF &canvasRect, int index, 
+    const QRectF &canvasRect, int index,
     double sampleWidth, const QwtSetSample& sample ) const
 {
@@ -568,5 +563,4 @@
         double sum = baseline();
 
-        const int numBars = sample.set.size();
         for ( int i = 0; i < numBars; i++ )
         {
@@ -670,8 +664,8 @@
     {
         // we build a temporary default symbol
-        QwtColumnSymbol sym( QwtColumnSymbol::Box );
-        sym.setLineWidth( 1 );
-        sym.setFrameStyle( QwtColumnSymbol::Plain );
-        sym.draw( painter, rect );
+        QwtColumnSymbol columnSymbol( QwtColumnSymbol::Box );
+        columnSymbol.setLineWidth( 1 );
+        columnSymbol.setFrameStyle( QwtColumnSymbol::Plain );
+        columnSymbol.draw( painter, rect );
     }
 
@@ -702,5 +696,5 @@
         {
             QVariant iconValue;
-            qVariantSetValue( iconValue, 
+            qVariantSetValue( iconValue,
                 legendIcon( i, legendIconSize() ) );
 
@@ -719,5 +713,5 @@
   \param index Index of the bar
   \param size Icon size
-  
+
   \return An icon showing a bar
   \sa drawBar(), legendData()
Index: trunk/BNC/qwt/qwt_plot_multi_barchart.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_multi_barchart.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_multi_barchart.h	(revision 9383)
@@ -20,7 +20,7 @@
 /*!
   \brief QwtPlotMultiBarChart displays a series of a samples that consist
-         each of a set of values. 
+         each of a set of values.
 
-  Each value is displayed as a bar, the bars of each set can be organized 
+  Each value is displayed as a bar, the bars of each set can be organized
   side by side or accumulated.
 
@@ -29,15 +29,15 @@
   by overloading specialSymbol() or overloading drawBar().
 
-  Depending on its orientation() the bars are displayed horizontally 
-  or vertically. The bars cover the interval between the baseline() 
+  Depending on its orientation() the bars are displayed horizontally
+  or vertically. The bars cover the interval between the baseline()
   and the value.
 
   In opposite to most other plot items, QwtPlotMultiBarChart returns more
   than one entry for the legend - one for each symbol.
-   
+
   \sa QwtPlotBarChart, QwtPlotHistogram
       QwtPlotSeriesItem::orientation(), QwtPlotAbstractBarChart::baseline()
  */
-class QWT_EXPORT QwtPlotMultiBarChart: 
+class QWT_EXPORT QwtPlotMultiBarChart:
     public QwtPlotAbstractBarChart, public QwtSeriesStore<QwtSetSample>
 {
@@ -62,5 +62,5 @@
     };
 
-    explicit QwtPlotMultiBarChart( const QString &title = QString::null );
+    explicit QwtPlotMultiBarChart( const QString &title = QString() );
     explicit QwtPlotMultiBarChart( const QwtText &title );
 
@@ -79,6 +79,6 @@
     ChartStyle style() const;
 
-    void setSymbol( int barIndex, QwtColumnSymbol *symbol );
-    const QwtColumnSymbol *symbol( int barIndex ) const;
+    void setSymbol( int valueIndex, QwtColumnSymbol * );
+    const QwtColumnSymbol *symbol( int valueIndex ) const;
 
     void resetSymbolMap();
@@ -95,7 +95,7 @@
 
 protected:
-    QwtColumnSymbol *symbol( int barIndex );
+    QwtColumnSymbol *symbol( int valueIndex );
 
-    virtual QwtColumnSymbol *specialSymbol( 
+    virtual QwtColumnSymbol *specialSymbol(
         int sampleIndex, int valueIndex ) const;
 
@@ -106,5 +106,5 @@
 
     virtual void drawBar( QPainter *, int sampleIndex,
-        int barIndex, const QwtColumnRect & ) const;
+        int valueIndex, const QwtColumnRect & ) const;
 
     void drawStackedBars( QPainter *painter,
Index: trunk/BNC/qwt/qwt_plot_panner.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_panner.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_panner.cpp	(revision 9383)
@@ -15,12 +15,33 @@
 #include <qstyle.h>
 #include <qstyleoption.h>
+#include <qpainterpath.h>
+
+#if QT_VERSION >= 0x050000
+#if QT_VERSION < 0x050100
+#define QWT_USE_WINDOW_HANDLE 1
+#endif
+#endif
+
+#ifdef QWT_USE_WINDOW_HANDLE
+#include <qwindow.h>
+#endif
 
 static QBitmap qwtBorderMask( const QWidget *canvas, const QSize &size )
 {
+#if QT_VERSION >= 0x050000
+    qreal pixelRatio = 1.0;
+
+#ifdef QWT_USE_WINDOW_HANDLE
+    pixelRatio = canvas->windowHandle()->devicePixelRatio();
+#else
+    pixelRatio = canvas->devicePixelRatio();
+#endif
+#endif
+
     const QRect r( 0, 0, size.width(), size.height() );
 
     QPainterPath borderPath;
 
-    ( void )QMetaObject::invokeMethod( 
+    ( void )QMetaObject::invokeMethod(
         const_cast< QWidget *>( canvas ), "borderPath", Qt::DirectConnection,
         Q_RETURN_ARG( QPainterPath, borderPath ), Q_ARG( QRect, r ) );
@@ -31,5 +52,10 @@
             return QBitmap();
 
+#if QT_VERSION >= 0x050000
+        QBitmap mask( size * pixelRatio );
+        mask.setDevicePixelRatio( pixelRatio );
+#else
         QBitmap mask( size );
+#endif
         mask.fill( Qt::color0 );
 
@@ -40,5 +66,10 @@
     }
 
+#if QT_VERSION >= 0x050000
+    QImage image( size * pixelRatio, QImage::Format_ARGB32_Premultiplied );
+    image.setDevicePixelRatio( pixelRatio );
+#else
     QImage image( size, QImage::Format_ARGB32_Premultiplied );
+#endif
     image.fill( Qt::color0 );
 
@@ -63,10 +94,10 @@
         const QVariant frameWidth = canvas->property( "frameWidth" );
 
-        if ( borderRadius.type() == QVariant::Double 
+        if ( borderRadius.type() == QVariant::Double
             && frameWidth.type() == QVariant::Int )
         {
             const double br = borderRadius.toDouble();
             const int fw = frameWidth.toInt();
-        
+
             if ( br > 0.0 && fw > 0 )
             {
@@ -114,6 +145,6 @@
     d_data = new PrivateData();
 
-    connect( this, SIGNAL( panned( int, int ) ),
-        SLOT( moveCanvas( int, int ) ) );
+    connect( this, SIGNAL(panned(int,int)),
+        SLOT(moveCanvas(int,int)) );
 }
 
@@ -256,5 +287,5 @@
  */
 QPixmap QwtPlotPanner::grab() const
-{   
+{
     const QWidget *cv = canvas();
     if ( cv && cv->inherits( "QGLWidget" ) )
@@ -272,4 +303,4 @@
 
     return QwtPanner::grab();
-}   
-
+}
+
Index: trunk/BNC/qwt/qwt_plot_picker.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_picker.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_picker.cpp	(revision 9383)
@@ -193,4 +193,7 @@
 QwtText QwtPlotPicker::trackerText( const QPoint &pos ) const
 {
+    if ( plot() == NULL )
+        return QwtText();
+
     return trackerTextF( invTransform( pos ) );
 }
Index: trunk/BNC/qwt/qwt_plot_rasteritem.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_rasteritem.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_rasteritem.cpp	(revision 9383)
@@ -159,5 +159,7 @@
     py0 += strippedRect.top() - paintRect.top();
 
-    QImage expanded(sz, image.format());
+    QImage expanded( sz, image.format() );
+    if ( image.format() == QImage::Format_Indexed8 )
+        expanded.setColorTable( image.colorTable() );
 
     switch( image.depth() )
@@ -191,5 +193,5 @@
                 }
 
-                const quint32 *line1 = 
+                const quint32 *line1 =
                     reinterpret_cast<const quint32 *>( image.scanLine( y1 ) );
 
@@ -223,12 +225,12 @@
                     for ( int y2 = yy1; y2 < yy2; y2++ )
                     {
-                        quint32 *line2 = reinterpret_cast<quint32 *>( 
+                        quint32 *line2 = reinterpret_cast<quint32 *>(
                             expanded.scanLine( y2 ) );
 
-                        for ( int x2 = xx1; x2 < xx2; x2++ ) 
+                        for ( int x2 = xx1; x2 < xx2; x2++ )
                             line2[x2] = rgb;
-                    }       
-                }   
-            }   
+                    }
+                }
+            }
             break;
         }
@@ -241,17 +243,17 @@
                 {
                     yy1 = 0;
-                }   
+                }
                 else
                 {
                     yy1 = qRound( y1 * ph - py0 );
                     if ( yy1 < 0 )
-                        yy1 = 0; 
-                }       
-                
+                        yy1 = 0;
+                }
+
                 int yy2;
                 if ( y1 == h - 1 )
                 {
                     yy2 = sz.height();
-                }   
+                }
                 else
                 {
@@ -260,5 +262,5 @@
                         yy2 = sz.height();
                 }
-    
+
                 const uchar *line1 = image.scanLine( y1 );
 
@@ -293,6 +295,6 @@
                         uchar *line2 = expanded.scanLine( y2 );
                         memset( line2 + xx1, line1[x1], xx2 - xx1 );
-                    }       
-                }   
+                    }
+                }
             }
             break;
@@ -301,7 +303,7 @@
             expanded = image;
     }
-    
+
     return expanded;
-}   
+}
 
 static QRectF qwtExpandToPixels(const QRectF &rect, const QRectF &pixelRect)
@@ -385,5 +387,5 @@
 }
 
-static void qwtToRgba( const QImage* from, QImage* to,  
+static void qwtToRgba( const QImage* from, QImage* to,
     const QRect& tile, int alpha )
 {
@@ -573,14 +575,14 @@
 
    The geometry of a pixel is used to calculated the resolution and
-   alignment of the rendered image. 
-
-   Width and height of the hint need to be the horizontal  
-   and vertical distances between 2 neighbored points. 
-   The center of the hint has to be the position of any point 
+   alignment of the rendered image.
+
+   Width and height of the hint need to be the horizontal
+   and vertical distances between 2 neighbored points.
+   The center of the hint has to be the position of any point
    ( it doesn't matter which one ).
 
    Limiting the resolution of the image might significantly improve
    the performance and heavily reduce the amount of memory when rendering
-   a QImage from the raster data. 
+   a QImage from the raster data.
 
    The default implementation returns an empty rectangle (QRectF()),
@@ -664,5 +666,5 @@
         {
             /*
-              If only one dimension is of the data pixel is higher 
+              If only one dimension is of the data pixel is higher
               we expand the pixel rect to the resolution of the target device.
              */
@@ -690,5 +692,5 @@
         // data pixels we render in resolution of the paint device.
 
-        image = compose(xxMap, yyMap, 
+        image = compose(xxMap, yyMap,
             area, paintRect, paintRect.size().toSize(), doCache);
         if ( image.isNull() )
@@ -698,17 +700,17 @@
         // excluded in the intervals
 
-        imageRect = qwtStripRect(paintRect, area, 
+        imageRect = qwtStripRect(paintRect, area,
             xxMap, yyMap, xInterval, yInterval);
 
         if ( imageRect != paintRect )
         {
-            const QRect r( 
+            const QRect r(
                 qRound( imageRect.x() - paintRect.x()),
                 qRound( imageRect.y() - paintRect.y() ),
                 qRound( imageRect.width() ),
                 qRound( imageRect.height() ) );
-                
+
             image = image.copy(r);
-        }   
+        }
     }
     else
@@ -735,5 +737,5 @@
         imageSize.setHeight( qRound( imageArea.height() / pixelRect.height() ) );
 
-        image = compose(xxMap, yyMap, 
+        image = compose(xxMap, yyMap,
             imageArea, paintRect, imageSize, doCache );
 
@@ -741,5 +743,5 @@
             return;
 
-        imageRect = qwtStripRect(paintRect, area, 
+        imageRect = qwtStripRect(paintRect, area,
             xxMap, yyMap, xInterval, yInterval);
 
@@ -747,9 +749,9 @@
             testPaintAttribute( PaintInDeviceResolution ) )
         {
-            // Because of rounding errors the pixels 
-            // need to be expanded manually to rectangles of 
+            // Because of rounding errors the pixels
+            // need to be expanded manually to rectangles of
             // different sizes
 
-            image = qwtExpandImage(image, xxMap, yyMap, 
+            image = qwtExpandImage(image, xxMap, yyMap,
                 imageArea, area, paintRect, xInterval, yInterval );
         }
@@ -758,5 +760,5 @@
     painter->save();
     painter->setWorldTransform( QTransform() );
-    
+
     QwtPainter::drawImage( painter, imageRect, image );
 
@@ -769,5 +771,5 @@
    This method is intended to be reimplemented by derived classes.
    The default implementation returns an invalid interval.
-   
+
    \param axis X, Y, or Z axis
 */
@@ -817,7 +819,7 @@
 }
 
-QImage QwtPlotRasterItem::compose( 
+QImage QwtPlotRasterItem::compose(
     const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-    const QRectF &imageArea, const QRectF &paintRect, 
+    const QRectF &imageArea, const QRectF &paintRect,
     const QSize &imageSize, bool doCache) const
 {
@@ -842,12 +844,12 @@
             dx = imageArea.width() / imageSize.width();
 
-        const QwtScaleMap xxMap = 
+        const QwtScaleMap xxMap =
             imageMap(Qt::Horizontal, xMap, imageArea, imageSize, dx);
-        
+
         double dy = 0.0;
         if ( paintRect.toRect().height() > imageSize.height() )
             dy = imageArea.height() / imageSize.height();
 
-        const QwtScaleMap yyMap = 
+        const QwtScaleMap yyMap =
             imageMap(Qt::Vertical, yMap, imageArea, imageSize, dy);
 
@@ -937,5 +939,5 @@
     }
 
-    if ( pixelSize > 0.0 )
+    if ( pixelSize > 0.0 || p2 == 1.0 )
     {
         double off = 0.5 * pixelSize;
Index: trunk/BNC/qwt/qwt_plot_rasteritem.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_rasteritem.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_rasteritem.h	(revision 9383)
@@ -51,8 +51,8 @@
         /*!
           renderImage() is called, whenever the image cache is not valid,
-          or the scales, or the size of the canvas has changed. 
+          or the scales, or the size of the canvas has changed.
 
-          This type of cache is useful for improving the performance 
-          of hide/show operations or manipulations of the alpha value. 
+          This type of cache is useful for improving the performance
+          of hide/show operations or manipulations of the alpha value.
           All other situations are handled by the canvas backing store.
          */
@@ -69,9 +69,9 @@
           When the image is rendered according to the data pixels
           ( QwtRasterData::pixelHint() ) it can be expanded to paint
-          device resolution before it is passed to QPainter. 
-          The expansion algorithm rounds the pixel borders in the same 
+          device resolution before it is passed to QPainter.
+          The expansion algorithm rounds the pixel borders in the same
           way as the axis ticks, what is usually better than the
           scaling algorithm implemented in Qt.
-          Disabling this flag might make sense, to reduce the size of a 
+          Disabling this flag might make sense, to reduce the size of a
           document/file. If this is possible for a document format
           depends on the implementation of the specific QPaintEngine.
@@ -84,5 +84,5 @@
     typedef QFlags<PaintAttribute> PaintAttributes;
 
-    explicit QwtPlotRasterItem( const QString& title = QString::null );
+    explicit QwtPlotRasterItem( const QString& title = QString() );
     explicit QwtPlotRasterItem( const QwtText& title );
     virtual ~QwtPlotRasterItem();
@@ -99,7 +99,7 @@
     void invalidateCache();
 
-    virtual void draw( QPainter *p,
+    virtual void draw( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &rect ) const;
+        const QRectF &canvasRect ) const;
 
     virtual QRectF pixelHint( const QRectF & ) const;
@@ -110,8 +110,8 @@
 protected:
     /*!
-      \brief Render an image 
+      \brief Render an image
 
       An implementation of render() might iterate over all
-      pixels of imageRect. Each pixel has to be translated into 
+      pixels of imageRect. Each pixel has to be translated into
       the corresponding position in scale coordinates using the maps.
       This position can be used to look up a value in a implementation
@@ -122,5 +122,5 @@
       \param area Requested area for the image in scale coordinates
       \param imageSize Requested size of the image
-   
+
       \return Rendered image
      */
Index: trunk/BNC/qwt/qwt_plot_renderer.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_renderer.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_renderer.cpp	(revision 9383)
@@ -15,24 +15,63 @@
 #include "qwt_scale_widget.h"
 #include "qwt_scale_engine.h"
+#include "qwt_scale_map.h"
 #include "qwt_text.h"
 #include "qwt_text_label.h"
 #include "qwt_math.h"
+
 #include <qpainter.h>
-#include <qpaintengine.h>
+#include <qpainterpath.h>
 #include <qtransform.h>
 #include <qprinter.h>
-#include <qprintdialog.h>
 #include <qfiledialog.h>
 #include <qfileinfo.h>
-#include <qstyle.h>
-#include <qstyleoption.h>
 #include <qimagewriter.h>
+#include <qvariant.h>
+
 #ifndef QWT_NO_SVG
 #ifdef QT_SVG_LIB
+#if QT_VERSION >= 0x040500
+#define QWT_FORMAT_SVG 1
+#endif
+#endif
+#endif
+
+#ifndef QT_NO_PRINTER
+#define QWT_FORMAT_PDF 1
+#endif
+
+#ifndef QT_NO_PDF
+
+// QPdfWriter::setResolution() has been introduced with
+// Qt 5.3. Guess it is o.k. to stay with QPrinter for older
+// versions.
+
+#if QT_VERSION >= 0x050300
+
+#ifndef QWT_FORMAT_PDF
+#define QWT_FORMAT_PDF 1
+#endif
+
+#define QWT_PDF_WRITER 1
+
+#endif
+#endif
+
+#ifndef QT_NO_PRINTER
+// postscript support has been dropped in Qt5
+#if QT_VERSION < 0x050000
+#define QWT_FORMAT_POSTSCRIPT 1
+#endif
+#endif
+
+#if QWT_FORMAT_SVG
 #include <qsvggenerator.h>
 #endif
-#endif
-
-static QPainterPath qwtCanvasClip( 
+
+#if QWT_PDF_WRITER
+#include <qpdfwriter.h>
+#endif
+
+static QPainterPath qwtCanvasClip(
     const QWidget* canvas, const QRectF &canvasRect )
 {
@@ -58,4 +97,12 @@
 }
 
+static inline QFont qwtResolvedFont( const QWidget *widget )
+{
+    QFont font = widget->font();
+    font.resolve( QFont::AllPropertiesResolved );
+
+    return font;
+}
+
 class QwtPlotRenderer::PrivateData
 {
@@ -71,5 +118,5 @@
 };
 
-/*! 
+/*!
    Constructor
    \param parent Parent object
@@ -239,7 +286,18 @@
 
     const QString fmt = format.toLower();
-    if ( fmt == "pdf" )
-    {
-#ifndef QT_NO_PRINTER
+    if ( fmt == QLatin1String( "pdf" ) )
+    {
+#if QWT_FORMAT_PDF
+
+#if QWT_PDF_WRITER
+        QPdfWriter pdfWriter( fileName );
+        pdfWriter.setPageSizeMM( sizeMM );
+        pdfWriter.setTitle( title );
+        pdfWriter.setPageMargins( QMarginsF() );
+        pdfWriter.setResolution( resolution );
+
+        QPainter painter( &pdfWriter );
+        render( plot, &painter, documentRect );
+#else
         QPrinter printer;
         printer.setOutputFormat( QPrinter::PdfFormat );
@@ -254,9 +312,9 @@
         render( plot, &painter, documentRect );
 #endif
-    }
-    else if ( fmt == "ps" )
-    {
-#if QT_VERSION < 0x050000
-#ifndef QT_NO_PRINTER
+#endif
+    }
+    else if ( fmt == QLatin1String( "ps" ) )
+    {
+#if QWT_FORMAT_POSTSCRIPT
         QPrinter printer;
         printer.setOutputFormat( QPrinter::PostScriptFormat );
@@ -271,11 +329,8 @@
         render( plot, &painter, documentRect );
 #endif
-#endif
-    }
-    else if ( fmt == "svg" )
-    {
-#ifndef QWT_NO_SVG
-#ifdef QT_SVG_LIB
-#if QT_VERSION >= 0x040500
+    }
+    else if ( fmt == QLatin1String( "svg" ) )
+    {
+#if QWT_FORMAT_SVG
         QSvgGenerator generator;
         generator.setTitle( title );
@@ -287,6 +342,4 @@
         render( plot, &painter, documentRect );
 #endif
-#endif
-#endif
     }
     else
@@ -367,7 +420,5 @@
 #endif
 
-#ifndef QWT_NO_SVG
-#ifdef QT_SVG_LIB
-#if QT_VERSION >= 0x040500
+#if QWT_FORMAT_SVG
 
 /*!
@@ -395,6 +446,5 @@
     render( plot, &p, rect );
 }
-#endif
-#endif
+
 #endif
 
@@ -461,9 +511,4 @@
             if ( !plot->axisEnabled( axisId ) )
             {
-                int left = 0;
-                int right = 0;
-                int top = 0;
-                int bottom = 0;
-
                 // When we have a scale the frame is painted on
                 // the position of the backbone - otherwise we
@@ -487,5 +532,4 @@
                         break;
                 }
-                layoutRect.adjust( left, top, right, bottom );
             }
         }
@@ -500,6 +544,5 @@
     {
         layoutOptions |= QwtPlotLayout::IgnoreFrames;
-    } 
-
+    }
 
     if ( d_data->discardFlags & DiscardLegend )
@@ -591,10 +634,10 @@
   \param plot Plot widget
   \param painter Painter
-  \param rect Bounding rectangle
+  \param titleRect Bounding rectangle for the title
 */
 void QwtPlotRenderer::renderTitle( const QwtPlot *plot,
-    QPainter *painter, const QRectF &rect ) const
-{
-    painter->setFont( plot->titleLabel()->font() );
+    QPainter *painter, const QRectF &titleRect ) const
+{
+    painter->setFont( qwtResolvedFont( plot->titleLabel() ) );
 
     const QColor color = plot->titleLabel()->palette().color(
@@ -602,5 +645,5 @@
 
     painter->setPen( color );
-    plot->titleLabel()->text().draw( painter, rect );
+    plot->titleLabel()->text().draw( painter, titleRect );
 }
 
@@ -610,10 +653,10 @@
   \param plot Plot widget
   \param painter Painter
-  \param rect Bounding rectangle
+  \param footerRect Bounding rectangle for the footer
 */
 void QwtPlotRenderer::renderFooter( const QwtPlot *plot,
-    QPainter *painter, const QRectF &rect ) const
-{
-    painter->setFont( plot->footerLabel()->font() );
+    QPainter *painter, const QRectF &footerRect ) const
+{
+    painter->setFont( qwtResolvedFont( plot->footerLabel() ) );
 
     const QColor color = plot->footerLabel()->palette().color(
@@ -621,7 +664,6 @@
 
     painter->setPen( color );
-    plot->footerLabel()->text().draw( painter, rect );
-}
-
+    plot->footerLabel()->text().draw( painter, footerRect );
+}
 
 /*!
@@ -630,13 +672,13 @@
   \param plot Plot widget
   \param painter Painter
-  \param rect Bounding rectangle
+  \param legendRect Bounding rectangle for the legend
 */
 void QwtPlotRenderer::renderLegend( const QwtPlot *plot,
-    QPainter *painter, const QRectF &rect ) const
+    QPainter *painter, const QRectF &legendRect ) const
 {
     if ( plot->legend() )
     {
         bool fillBackground = !( d_data->discardFlags & DiscardBackground );
-        plot->legend()->renderLegend( painter, rect, fillBackground );
+        plot->legend()->renderLegend( painter, legendRect, fillBackground );
     }
 }
@@ -652,10 +694,10 @@
   \param endDist End border distance
   \param baseDist Base distance
-  \param rect Bounding rectangle
+  \param scaleRect Bounding rectangle for the scale
 */
 void QwtPlotRenderer::renderScale( const QwtPlot *plot,
     QPainter *painter,
     int axisId, int startDist, int endDist, int baseDist,
-    const QRectF &rect ) const
+    const QRectF &scaleRect ) const
 {
     if ( !plot->axisEnabled( axisId ) )
@@ -666,5 +708,5 @@
         && scaleWidget->colorBarWidth() > 0 )
     {
-        scaleWidget->drawColorBar( painter, scaleWidget->colorBarRect( rect ) );
+        scaleWidget->drawColorBar( painter, scaleWidget->colorBarRect( scaleRect ) );
         baseDist += scaleWidget->colorBarWidth() + scaleWidget->spacing();
     }
@@ -679,7 +721,7 @@
         case QwtPlot::yLeft:
         {
-            x = rect.right() - 1.0 - baseDist;
-            y = rect.y() + startDist;
-            w = rect.height() - startDist - endDist;
+            x = scaleRect.right() - 1.0 - baseDist;
+            y = scaleRect.y() + startDist;
+            w = scaleRect.height() - startDist - endDist;
             align = QwtScaleDraw::LeftScale;
             break;
@@ -687,7 +729,7 @@
         case QwtPlot::yRight:
         {
-            x = rect.left() + baseDist;
-            y = rect.y() + startDist;
-            w = rect.height() - startDist - endDist;
+            x = scaleRect.left() + baseDist;
+            y = scaleRect.y() + startDist;
+            w = scaleRect.height() - startDist - endDist;
             align = QwtScaleDraw::RightScale;
             break;
@@ -695,7 +737,7 @@
         case QwtPlot::xTop:
         {
-            x = rect.left() + startDist;
-            y = rect.bottom() - 1.0 - baseDist;
-            w = rect.width() - startDist - endDist;
+            x = scaleRect.left() + startDist;
+            y = scaleRect.bottom() - 1.0 - baseDist;
+            w = scaleRect.width() - startDist - endDist;
             align = QwtScaleDraw::TopScale;
             break;
@@ -703,7 +745,7 @@
         case QwtPlot::xBottom:
         {
-            x = rect.left() + startDist;
-            y = rect.top() + baseDist;
-            w = rect.width() - startDist - endDist;
+            x = scaleRect.left() + startDist;
+            y = scaleRect.top() + baseDist;
+            w = scaleRect.width() - startDist - endDist;
             align = QwtScaleDraw::BottomScale;
             break;
@@ -713,7 +755,7 @@
     }
 
-    scaleWidget->drawTitle( painter, align, rect );
-
-    painter->setFont( scaleWidget->font() );
+    scaleWidget->drawTitle( painter, align, scaleRect );
+
+    painter->setFont( qwtResolvedFont( scaleWidget ) );
 
     QwtScaleDraw *sd = const_cast<QwtScaleDraw *>( scaleWidget->scaleDraw() );
@@ -740,10 +782,10 @@
   \param plot Plot widget
   \param painter Painter
-  \param map Maps mapping between plot and paint device coordinates
+  \param maps Maps mapping between plot and paint device coordinates
   \param canvasRect Canvas rectangle
 */
 void QwtPlotRenderer::renderCanvas( const QwtPlot *plot,
-    QPainter *painter, const QRectF &canvasRect, 
-    const QwtScaleMap *map ) const
+    QPainter *painter, const QRectF &canvasRect,
+    const QwtScaleMap *maps ) const
 {
     const QWidget *canvas = plot->canvas();
@@ -771,5 +813,5 @@
 
         painter->setClipRect( canvasRect );
-        plot->drawItems( painter, canvasRect, map );
+        plot->drawItems( painter, canvasRect, maps );
 
         painter->restore();
@@ -795,5 +837,5 @@
             painter->setClipPath( clipPath );
 
-        plot->drawItems( painter, canvasRect, map );
+        plot->drawItems( painter, canvasRect, maps );
 
         painter->restore();
@@ -814,5 +856,5 @@
         }
 
-        QRectF innerRect = canvasRect.adjusted( 
+        QRectF innerRect = canvasRect.adjusted(
             frameWidth, frameWidth, -frameWidth, -frameWidth );
 
@@ -833,5 +875,5 @@
         }
 
-        plot->drawItems( painter, innerRect, map );
+        plot->drawItems( painter, innerRect, maps );
 
         painter->restore();
@@ -845,15 +887,12 @@
                 canvas->property( "frameShape" ).toInt();
 
-            const int frameWidth = canvas->property( "frameWidth" ).toInt();
-
-
             const QVariant borderRadius = canvas->property( "borderRadius" );
-            if ( borderRadius.type() == QVariant::Double 
+            if ( borderRadius.type() == QVariant::Double
                 && borderRadius.toDouble() > 0.0 )
             {
-                const double r = borderRadius.toDouble();
+                const double radius = borderRadius.toDouble();
 
                 QwtPainter::drawRoundedFrame( painter, canvasRect,
-                    r, r, canvas->palette(), frameWidth, frameStyle );
+                    radius, radius, canvas->palette(), frameWidth, frameStyle );
             }
             else
@@ -933,5 +972,5 @@
     double margins[QwtPlot::axisCnt];
     plot->getCanvasMarginsHint( maps, canvasRect,
-        margins[QwtPlot::yLeft], margins[QwtPlot::xTop], 
+        margins[QwtPlot::yLeft], margins[QwtPlot::xTop],
         margins[QwtPlot::yRight], margins[QwtPlot::xBottom] );
 
@@ -963,27 +1002,27 @@
 bool QwtPlotRenderer::exportTo( QwtPlot *plot, const QString &documentName,
      const QSizeF &sizeMM, int resolution )
-{       
+{
     if ( plot == NULL )
         return false;
-    
+
     QString fileName = documentName;
 
-    // What about translation 
+    // What about translation
 
 #ifndef QT_NO_FILEDIALOG
     const QList<QByteArray> imageFormats =
         QImageWriter::supportedImageFormats();
-        
+
     QStringList filter;
-#ifndef QT_NO_PRINTER
+#if QWT_FORMAT_PDF
     filter += QString( "PDF " ) + tr( "Documents" ) + " (*.pdf)";
 #endif
-#ifndef QWT_NO_SVG 
+#if QWT_FORMAT_SVG
     filter += QString( "SVG " ) + tr( "Documents" ) + " (*.svg)";
 #endif
-#ifndef QT_NO_PRINTER
+#if QWT_FORMAT_POSTSCRIPT
     filter += QString( "Postscript " ) + tr( "Documents" ) + " (*.ps)";
 #endif
-    
+
     if ( imageFormats.size() > 0 )
     {
@@ -994,16 +1033,16 @@
             if ( i > 0 )
                 imageFilter += " ";
-            imageFilter += "*."; 
+            imageFilter += "*.";
             imageFilter += imageFormats[i];
-        }   
+        }
         imageFilter += ")";
-        
+
         filter += imageFilter;
-    }   
-    
+    }
+
     fileName = QFileDialog::getSaveFileName(
         NULL, tr( "Export File Name" ), fileName,
         filter.join( ";;" ), NULL, QFileDialog::DontConfirmOverwrite );
-#endif  
+#endif
     if ( fileName.isEmpty() )
         return false;
@@ -1012,3 +1051,3 @@
 
     return true;
-}   
+}
Index: trunk/BNC/qwt/qwt_plot_renderer.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_renderer.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_renderer.h	(revision 9383)
@@ -61,5 +61,5 @@
         DiscardFooter           = 0x10,
 
-        /*! 
+        /*!
             Don't render the frame of the canvas
 
@@ -128,18 +128,18 @@
 #endif
 
-    void renderTo( QwtPlot *, QPaintDevice &p ) const;
+    void renderTo( QwtPlot *, QPaintDevice & ) const;
 
     virtual void render( QwtPlot *,
-        QPainter *, const QRectF &rect ) const;
+        QPainter *, const QRectF &plotRect ) const;
 
     virtual void renderTitle( const QwtPlot *,
-        QPainter *, const QRectF & ) const;
+        QPainter *, const QRectF &titleRect ) const;
 
     virtual void renderFooter( const QwtPlot *,
-        QPainter *, const QRectF & ) const;
+        QPainter *, const QRectF &footerRect ) const;
 
     virtual void renderScale( const QwtPlot *, QPainter *,
         int axisId, int startDist, int endDist,
-        int baseDist, const QRectF & ) const;
+        int baseDist, const QRectF &scaleRect ) const;
 
     virtual void renderCanvas( const QwtPlot *,
@@ -147,6 +147,6 @@
         const QwtScaleMap* maps ) const;
 
-    virtual void renderLegend( 
-        const QwtPlot *, QPainter *, const QRectF & ) const;
+    virtual void renderLegend(
+        const QwtPlot *, QPainter *, const QRectF &legendRect ) const;
 
     bool exportTo( QwtPlot *, const QString &documentName,
Index: trunk/BNC/qwt/qwt_plot_rescaler.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_rescaler.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_rescaler.h	(revision 9383)
@@ -117,5 +117,5 @@
 
     virtual void rescale( const QSize &oldSize, const QSize &newSize ) const;
-    virtual QwtInterval expandScale( 
+    virtual QwtInterval expandScale(
         int axis, const QSize &oldSize, const QSize &newSize ) const;
 
Index: trunk/BNC/qwt/qwt_plot_scaleitem.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_scaleitem.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_scaleitem.cpp	(revision 9383)
@@ -350,5 +350,5 @@
     if ( d_data->scaleDivFromAxis )
     {
-        const QwtInterval interval = 
+        const QwtInterval interval =
             d_data->scaleInterval( canvasRect, xMap, yMap );
 
@@ -448,5 +448,5 @@
     if ( d_data->scaleDivFromAxis && scaleDraw )
     {
-        const QwtScaleDiv &scaleDiv = 
+        const QwtScaleDiv &scaleDiv =
             scaleDraw->orientation() == Qt::Horizontal ? xScaleDiv : yScaleDiv;
 
@@ -456,5 +456,5 @@
             const QRectF canvasRect = plt->canvas()->contentsRect();
 
-            const QwtInterval interval = d_data->scaleInterval( 
+            const QwtInterval interval = d_data->scaleInterval(
                 canvasRect, plt->canvasMap( xAxis() ), plt->canvasMap( yAxis() ) );
 
Index: trunk/BNC/qwt/qwt_plot_scaleitem.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_scaleitem.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_scaleitem.h	(revision 9383)
@@ -33,14 +33,14 @@
 
   \par Example
-  The following example shows how to replace the left axis, by a scale item
-  at the x position 0.0.
-  \verbatim
-QwtPlotScaleItem *scaleItem =
-    new QwtPlotScaleItem(QwtScaleDraw::RightScale, 0.0);
-scaleItem->setFont(plot->axisWidget(QwtPlot::yLeft)->font());
-scaleItem->attach(plot);
+    The following example shows how to replace the left axis, by a scale item
+    at the x position 0.0.
+    \code
+      QwtPlotScaleItem *scaleItem = new QwtPlotScaleItem( QwtScaleDraw::RightScale, 0.0 );
+      scaleItem->setFont( plot->axisWidget( QwtPlot::yLeft )->font() );
+      scaleItem->attach(plot);
 
-plot->enableAxis(QwtPlot::yLeft, false);
-\endverbatim
+      plot->enableAxis( QwtPlot::yLeft, false );
+    \endcode
+  \endpar
 */
 
@@ -76,12 +76,12 @@
     double position() const;
 
-    void setBorderDistance( int numPixels );
+    void setBorderDistance( int );
     int borderDistance() const;
 
     void setAlignment( QwtScaleDraw::Alignment );
 
-    virtual void draw( QPainter *p,
+    virtual void draw( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &rect ) const;
+        const QRectF &canvasRect ) const;
 
     virtual void updateScaleDiv( const QwtScaleDiv &, const QwtScaleDiv & );
Index: trunk/BNC/qwt/qwt_plot_seriesitem.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_seriesitem.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_seriesitem.cpp	(revision 9383)
@@ -40,4 +40,5 @@
 {
     d_data = new PrivateData();
+    setItemInterest( QwtPlotItem::ScaleInterest, true );
 }
 
@@ -99,11 +100,11 @@
 void QwtPlotSeriesItem::updateScaleDiv(
     const QwtScaleDiv &xScaleDiv, const QwtScaleDiv &yScaleDiv )
-{   
+{
     const QRectF rect = QRectF(
         xScaleDiv.lowerBound(), yScaleDiv.lowerBound(),
         xScaleDiv.range(), yScaleDiv.range() );
-        
+
     setRectOfInterest( rect );
-}   
+}
 
 void QwtPlotSeriesItem::dataChanged()
Index: trunk/BNC/qwt/qwt_plot_seriesitem.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_seriesitem.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_seriesitem.h	(revision 9383)
@@ -24,5 +24,5 @@
 {
 public:
-    explicit QwtPlotSeriesItem( const QString &title = QString::null );
+    explicit QwtPlotSeriesItem( const QString &title = QString() );
     explicit QwtPlotSeriesItem( const QwtText &title );
 
@@ -32,5 +32,5 @@
     Qt::Orientation orientation() const;
 
-    virtual void draw( QPainter *p,
+    virtual void draw( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
         const QRectF & ) const;
@@ -53,5 +53,5 @@
     virtual QRectF boundingRect() const;
 
-    virtual void updateScaleDiv( 
+    virtual void updateScaleDiv(
         const QwtScaleDiv &, const QwtScaleDiv & );
 
Index: trunk/BNC/qwt/qwt_plot_shapeitem.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_shapeitem.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_shapeitem.cpp	(revision 9383)
@@ -208,5 +208,5 @@
   \sa setShape(), setPolygon(), shape()
  */
-void QwtPlotShapeItem::setRect( const QRectF &rect ) 
+void QwtPlotShapeItem::setRect( const QRectF &rect )
 {
     QPainterPath path;
@@ -263,19 +263,19 @@
 }
 
-/*! 
+/*!
   Build and assign a pen
-    
+
   In Qt5 the default pen width is 1.0 ( 0.0 in Qt4 ) what makes it
   non cosmetic ( see QPen::isCosmetic() ). This method has been introduced
   to hide this incompatibility.
-    
+
   \param color Pen color
   \param width Pen width
   \param style Pen style
-    
+
   \sa pen(), brush()
- */ 
+ */
 void QwtPlotShapeItem::setPen( const QColor &color, qreal width, Qt::PenStyle style )
-{   
+{
     setPen( QPen( color, width, style ) );
 }
@@ -336,5 +336,5 @@
   \brief Set the tolerance for the weeding optimization
 
-  After translating the shape into target device coordinate 
+  After translating the shape into target device coordinate
   ( usually widget geometries ) the painter path can be simplified
   by a point weeding algorithm ( Douglas-Peucker ).
@@ -384,5 +384,5 @@
         return;
 
-    if ( d_data->pen.style() == Qt::NoPen 
+    if ( d_data->pen.style() == Qt::NoPen
         && d_data->brush.style() == Qt::NoBrush )
     {
@@ -404,5 +404,5 @@
     const bool doAlign = QwtPainter::roundingAlignment( painter );
 
-    QPainterPath path = qwtTransformPath( xMap, yMap, 
+    QPainterPath path = qwtTransformPath( xMap, yMap,
         d_data->shape, doAlign );
 
@@ -451,5 +451,5 @@
   \return A rectangle filled with the color of the brush ( or the pen )
 
-  \param index Index of the legend entry 
+  \param index Index of the legend entry
                 ( usually there is only one )
   \param size Icon size
Index: trunk/BNC/qwt/qwt_plot_shapeitem.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_shapeitem.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_shapeitem.h	(revision 9383)
@@ -16,5 +16,5 @@
 
 /*!
-  \brief A plot item, which displays any graphical shape, 
+  \brief A plot item, which displays any graphical shape,
          that can be defined by a QPainterPath
 
@@ -61,9 +61,9 @@
         LegendShape,
 
-        //! Display a filled rectangle 
+        //! Display a filled rectangle
         LegendColor
     };
 
-    explicit QwtPlotShapeItem( const QString &title = QString::null );
+    explicit QwtPlotShapeItem( const QString &title = QString() );
     explicit QwtPlotShapeItem( const QwtText &title );
 
@@ -94,7 +94,7 @@
     virtual QRectF boundingRect() const;
 
-    virtual void draw( QPainter *p,
+    virtual void draw( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &rect ) const;
+        const QRectF &canvasRect ) const;
 
     virtual QwtGraphic legendIcon( int index, const QSizeF & ) const;
Index: trunk/BNC/qwt/qwt_plot_spectrocurve.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_spectrocurve.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_spectrocurve.cpp	(revision 9383)
@@ -118,11 +118,11 @@
 /*!
   Assign a series of samples
-    
+
   setSamples() is just a wrapper for setData() without any additional
   value - beside that it is easier to find for the developer.
-    
+
   \param data Data
   \warning The item takes ownership of the data object, deleting
-           it when its not used anymore. 
+           it when its not used anymore.
 */
 void QwtPlotSpectroCurve::setSamples(
@@ -130,5 +130,5 @@
 {
     setData( data );
-}  
+}
 
 /*!
@@ -311,5 +311,5 @@
                 d_data->colorRange, sample.z() );
 
-            painter->setPen( QPen( QColor::fromRgba( d_data->colorTable[index] ), 
+            painter->setPen( QPen( QColor::fromRgba( d_data->colorTable[index] ),
                 d_data->penWidth ) );
         }
Index: trunk/BNC/qwt/qwt_plot_spectrocurve.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_spectrocurve.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_spectrocurve.h	(revision 9383)
@@ -22,6 +22,6 @@
            mapped to a color.
 */
-class QWT_EXPORT QwtPlotSpectroCurve: 
-    public QwtPlotSeriesItem, QwtSeriesStore<QwtPoint3D>
+class QWT_EXPORT QwtPlotSpectroCurve:
+    public QwtPlotSeriesItem, public QwtSeriesStore<QwtPoint3D>
 {
 public:
@@ -36,5 +36,5 @@
     typedef QFlags<PaintAttribute> PaintAttributes;
 
-    explicit QwtPlotSpectroCurve( const QString &title = QString::null );
+    explicit QwtPlotSpectroCurve( const QString &title = QString() );
     explicit QwtPlotSpectroCurve( const QwtText &title );
 
@@ -60,5 +60,5 @@
         const QRectF &canvasRect, int from, int to ) const;
 
-    void setPenWidth(double width);
+    void setPenWidth( double );
     double penWidth() const;
 
Index: trunk/BNC/qwt/qwt_plot_spectrogram.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_spectrogram.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_spectrogram.cpp	(revision 9383)
@@ -162,20 +162,20 @@
 }
 
-/*! 
+/*!
   Build and assign the default pen for the contour lines
-    
+
   In Qt5 the default pen width is 1.0 ( 0.0 in Qt4 ) what makes it
   non cosmetic ( see QPen::isCosmetic() ). This method has been introduced
   to hide this incompatibility.
-    
+
   \param color Pen color
   \param width Pen width
   \param style Pen style
-    
+
   \sa pen(), brush()
- */ 
-void QwtPlotSpectrogram::setDefaultContourPen( 
+ */
+void QwtPlotSpectrogram::setDefaultContourPen(
     const QColor &color, qreal width, Qt::PenStyle style )
-{   
+{
     setDefaultContourPen( QPen( color, width, style ) );
 }
@@ -363,5 +363,5 @@
 
    The geometry of a pixel is used to calculated the resolution and
-   alignment of the rendered image. 
+   alignment of the rendered image.
 
    The default implementation returns data()->pixelHint( rect );
@@ -372,5 +372,5 @@
    \return Bounding rectangle of a pixel
 
-   \sa QwtPlotRasterItem::pixelHint(), QwtRasterData::pixelHint(), 
+   \sa QwtPlotRasterItem::pixelHint(), QwtRasterData::pixelHint(),
        render(), renderImage()
 */
@@ -403,5 +403,5 @@
     const QRectF &area, const QSize &imageSize ) const
 {
-    if ( imageSize.isEmpty() || d_data->data == NULL 
+    if ( imageSize.isEmpty() || d_data->data == NULL
         || d_data->colorMap == NULL )
     {
@@ -424,6 +424,6 @@
 
 #if DEBUG_RENDER
-	QElapsedTimer time;
-	time.start();
+    QElapsedTimer time;
+    time.start();
 #endif
 
@@ -547,5 +547,5 @@
    \sa drawContourLines(), QwtRasterData::contourLines()
 */
-QSize QwtPlotSpectrogram::contourRasterSize( 
+QSize QwtPlotSpectrogram::contourRasterSize(
     const QRectF &area, const QRect &rect ) const
 {
Index: trunk/BNC/qwt/qwt_plot_spectrogram.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_spectrogram.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_spectrogram.h	(revision 9383)
@@ -56,5 +56,5 @@
     typedef QFlags<DisplayMode> DisplayModes;
 
-    explicit QwtPlotSpectrogram( const QString &title = QString::null );
+    explicit QwtPlotSpectrogram( const QString &title = QString() );
     virtual ~QwtPlotSpectrogram();
 
@@ -72,5 +72,5 @@
     virtual QRectF pixelHint( const QRectF & ) const;
 
-    void setDefaultContourPen( const QColor &, 
+    void setDefaultContourPen( const QColor &,
         qreal width = 0.0, Qt::PenStyle = Qt::SolidLine );
     void setDefaultContourPen( const QPen & );
@@ -87,7 +87,7 @@
     virtual int rtti() const;
 
-    virtual void draw( QPainter *p,
+    virtual void draw( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &rect ) const;
+        const QRectF &canvasRect ) const;
 
 protected:
@@ -102,10 +102,10 @@
         const QRectF &rect, const QSize &raster ) const;
 
-    virtual void drawContourLines( QPainter *p,
+    virtual void drawContourLines( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QwtRasterData::ContourLines& lines ) const;
+        const QwtRasterData::ContourLines& ) const;
 
     void renderTile( const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRect &imageRect, QImage *image ) const;
+        const QRect &tile, QImage * ) const;
 
 private:
Index: trunk/BNC/qwt/qwt_plot_svgitem.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_svgitem.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_svgitem.h	(revision 9383)
@@ -28,5 +28,5 @@
 {
 public:
-    explicit QwtPlotSvgItem( const QString& title = QString::null );
+    explicit QwtPlotSvgItem( const QString& title = QString() );
     explicit QwtPlotSvgItem( const QwtText& title );
     virtual ~QwtPlotSvgItem();
@@ -37,7 +37,7 @@
     virtual QRectF boundingRect() const;
 
-    virtual void draw( QPainter *p,
+    virtual void draw( QPainter *,
         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QRectF &rect ) const;
+        const QRectF &canvasRect ) const;
 
     virtual int rtti() const;
@@ -47,8 +47,8 @@
     QSvgRenderer &renderer();
 
-    void render( QPainter *painter,
+    void render( QPainter *,
         const QRectF &viewBox, const QRectF &rect ) const;
 
-    QRectF viewBox( const QRectF &area ) const;
+    QRectF viewBox( const QRectF &rect ) const;
 
 private:
Index: trunk/BNC/qwt/qwt_plot_textlabel.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_textlabel.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_textlabel.cpp	(revision 9383)
@@ -16,5 +16,5 @@
 
 static QRect qwtItemRect( int renderFlags,
-    const QRectF &rect, const QSizeF &itemSize ) 
+    const QRectF &rect, const QSizeF &itemSize )
 {
     int x;
@@ -33,5 +33,5 @@
 
     int y;
-    if ( renderFlags & Qt::AlignTop ) 
+    if ( renderFlags & Qt::AlignTop )
     {
         y = rect.top();
@@ -50,5 +50,5 @@
 
 class QwtPlotTextLabel::PrivateData
-{   
+{
 public:
     PrivateData():
@@ -61,5 +61,5 @@
 
     QPixmap pixmap;
-};  
+};
 
 /*!
@@ -102,5 +102,5 @@
 
 /*!
-  Set the text 
+  Set the text
 
   The label will be aligned to the plot canvas according to
@@ -211,10 +211,10 @@
             pw = qMax( d_data->text.borderPen().width(), 1 );
 
-        QRect pixmapRect; 
+        QRect pixmapRect;
         pixmapRect.setLeft( qFloor( rect.left() ) - pw );
         pixmapRect.setTop( qFloor( rect.top() ) - pw );
         pixmapRect.setRight( qCeil( rect.right() ) + pw );
         pixmapRect.setBottom( qCeil( rect.bottom() ) + pw );
-        
+
 #define QWT_HIGH_DPI 1
 
@@ -225,5 +225,5 @@
         const QSize scaledSize = pixmapRect.size();
 #endif
-        if ( d_data->pixmap.isNull() || 
+        if ( d_data->pixmap.isNull() ||
             ( scaledSize != d_data->pixmap.size() )  )
         {
@@ -234,5 +234,5 @@
             d_data->pixmap.fill( Qt::transparent );
 
-            const QRect r( pw, pw, 
+            const QRect r( pw, pw,
                 pixmapRect.width() - 2 * pw, pixmapRect.height() - 2 * pw );
 
@@ -260,5 +260,5 @@
    \sa setMargin(), QwtText::renderFlags(), QwtText::textSize()
  */
-QRectF QwtPlotTextLabel::textRect( 
+QRectF QwtPlotTextLabel::textRect(
     const QRectF &rect, const QSizeF &textSize ) const
 {
Index: trunk/BNC/qwt/qwt_plot_textlabel.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_textlabel.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_textlabel.h	(revision 9383)
@@ -22,26 +22,26 @@
   In opposite to QwtPlotMarker the position of the label is unrelated to
   plot coordinates.
-    
+
   As drawing a text is an expensive operation the label is cached
   in a pixmap to speed up replots.
 
   \par Example
-  The following code shows how to add a title.
+    The following code shows how to add a title.
+    \code
+      QwtText title( "Plot Title" );
+      title.setRenderFlags( Qt::AlignHCenter | Qt::AlignTop );
 
-\verbatim
-    QwtText title( "Plot Title" );
-    title.setRenderFlags( Qt::AlignHCenter | Qt::AlignTop );
+      QFont font;
+      font.setBold( true );
+      title.setFont( font );
 
-    QFont font;
-    font.setBold( true );
-    title.setFont( font );
-
-    QwtPlotTextLabel *titleItem = new QwtPlotTextLabel();
-    titleItem->setText( title );
-    titleItem->attach( this );
-\endverbatim
+      QwtPlotTextLabel *titleItem = new QwtPlotTextLabel();
+      titleItem->setText( title );
+      titleItem->attach( plot );
+    \endcode
+  \endpar
 
   \sa QwtPlotMarker
-*/  
+*/
 
 class QWT_EXPORT QwtPlotTextLabel: public QwtPlotItem
Index: trunk/BNC/qwt/qwt_plot_tradingcurve.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_tradingcurve.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_tradingcurve.cpp	(revision 9383)
@@ -135,11 +135,11 @@
 /*!
   Assign a series of samples
-    
+
   setSamples() is just a wrapper for setData() without any additional
   value - beside that it is easier to find for the developer.
-    
+
   \param data Data
   \warning The item takes ownership of the data object, deleting
-           it when its not used anymore. 
+           it when its not used anymore.
 */
 void QwtPlotTradingCurve::setSamples(
@@ -147,5 +147,5 @@
 {
     setData( data );
-}   
+}
 
 /*!
@@ -177,20 +177,20 @@
 }
 
-/*! 
+/*!
   Build and assign the symbol pen
-    
+
   In Qt5 the default pen width is 1.0 ( 0.0 in Qt4 ) what makes it
   non cosmetic ( see QPen::isCosmetic() ). This method has been introduced
   to hide this incompatibility.
-    
+
   \param color Pen color
   \param width Pen width
   \param style Pen style
-    
+
   \sa pen(), brush()
- */ 
-void QwtPlotTradingCurve::setSymbolPen( 
+ */
+void QwtPlotTradingCurve::setSymbolPen(
     const QColor &color, qreal width, Qt::PenStyle style )
-{   
+{
     setSymbolPen( QPen( color, width, style ) );
 }
@@ -236,10 +236,12 @@
     Direction direction, const QBrush &brush )
 {
-    if ( direction < 0 || direction >= 2 )
+    // silencing -Wtautological-constant-out-of-range-compare
+    const int index = static_cast< int >( direction );
+    if ( index < 0 || index >= 2 )
         return;
 
-    if ( brush != d_data->symbolBrush[ direction ] )
-    {
-        d_data->symbolBrush[ direction ] = brush;
+    if ( brush != d_data->symbolBrush[ index ] )
+    {
+        d_data->symbolBrush[ index ] = brush;
 
         legendChanged();
@@ -257,8 +259,9 @@
 QBrush QwtPlotTradingCurve::symbolBrush( Direction direction ) const
 {
-    if ( direction < 0 || direction >= 2 )
+    const int index = static_cast< int >( direction );
+    if ( index < 0 || index >= 2 )
         return QBrush();
 
-    return d_data->symbolBrush[ direction ];
+    return d_data->symbolBrush[ index ];
 }
 
@@ -273,5 +276,5 @@
   \param extent Symbol width in scale coordinates
 
-  \sa symbolExtent(), scaledSymbolWidth(), 
+  \sa symbolExtent(), scaledSymbolWidth(),
       setMinSymbolWidth(), setMaxSymbolWidth()
 */
@@ -338,5 +341,5 @@
     {
         d_data->maxSymbolWidth = width;
-    
+
         legendChanged();
         itemChanged();
@@ -360,5 +363,5 @@
 {
     QRectF rect = QwtPlotSeriesItem::boundingRect();
-    if ( rect.isValid() && orientation() == Qt::Vertical )
+    if ( orientation() == Qt::Vertical )
         rect.setRect( rect.y(), rect.x(), rect.height(), rect.width() );
 
@@ -487,5 +490,5 @@
                 case Bar:
                 {
-                    drawBar( painter, translatedSample, 
+                    drawBar( painter, translatedSample,
                         orient, inverted, symbolWidth );
                     break;
@@ -494,5 +497,5 @@
                 {
                     painter->setBrush( d_data->symbolBrush[ brushIndex ] );
-                    drawCandleStick( painter, translatedSample, 
+                    drawCandleStick( painter, translatedSample,
                         orient, symbolWidth );
                     break;
@@ -521,5 +524,5 @@
   \param sample Samples already translated into paint device coordinates
   \param orientation Vertical or horizontal
-  \param inverted True, when the opposite scale 
+  \param inverted True, when the opposite scale
                   ( Qt::Vertical: x, Qt::Horizontal: y ) is increasing
                   in the opposite direction as QPainter coordinates.
@@ -555,5 +558,5 @@
 */
 void QwtPlotTradingCurve::drawBar( QPainter *painter,
-    const QwtOHLCSample &sample, Qt::Orientation orientation, 
+    const QwtOHLCSample &sample, Qt::Orientation orientation,
     bool inverted, double width ) const
 {
@@ -594,5 +597,5 @@
 */
 void QwtPlotTradingCurve::drawCandleStick( QPainter *painter,
-    const QwtOHLCSample &sample, Qt::Orientation orientation, 
+    const QwtOHLCSample &sample, Qt::Orientation orientation,
     double width ) const
 {
@@ -628,5 +631,5 @@
   \return A rectangle filled with the color of the symbol pen
 
-  \param index Index of the legend entry 
+  \param index Index of the legend entry
                 ( usually there is only one )
   \param size Icon size
@@ -671,5 +674,5 @@
         ( orientation() == Qt::Vertical ) ? &xMap : &yMap;
 
-    const double pos = map->transform( map->s1() + d_data->symbolExtent ); 
+    const double pos = map->transform( map->s1() + d_data->symbolExtent );
 
     double width = qAbs( pos - map->p1() );
Index: trunk/BNC/qwt/qwt_plot_tradingcurve.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_tradingcurve.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_tradingcurve.h	(revision 9383)
@@ -22,5 +22,5 @@
   that are used in the domain of technical analysis.
 
-  While the length ( height or width depending on orientation() ) 
+  While the length ( height or width depending on orientation() )
   of each symbol depends on the corresponding OHLC sample the size
   of the other dimension can be controlled using:
@@ -32,10 +32,10 @@
   The extent is a size in scale coordinates, so that the symbol width
   is increasing when the plot is zoomed in. Minimum/Maximum width
-  is in widget coordinates independent from the zoom level. 
-  When setting the minimum and maximum to the same value, the width of 
-  the symbol is fixed. 
+  is in widget coordinates independent from the zoom level.
+  When setting the minimum and maximum to the same value, the width of
+  the symbol is fixed.
 */
-class QWT_EXPORT QwtPlotTradingCurve: 
-    public QwtPlotSeriesItem, QwtSeriesStore<QwtOHLCSample>
+class QWT_EXPORT QwtPlotTradingCurve:
+    public QwtPlotSeriesItem, public QwtSeriesStore<QwtOHLCSample>
 {
 public:
@@ -102,5 +102,5 @@
     typedef QFlags<PaintAttribute> PaintAttributes;
 
-    explicit QwtPlotTradingCurve( const QString &title = QString::null );
+    explicit QwtPlotTradingCurve( const QString &title = QString() );
     explicit QwtPlotTradingCurve( const QwtText &title );
 
@@ -118,5 +118,5 @@
     SymbolStyle symbolStyle() const;
 
-    void setSymbolPen( const QColor &, 
+    void setSymbolPen( const QColor &,
         qreal width = 0.0, Qt::PenStyle = Qt::SolidLine );
     void setSymbolPen( const QPen & );
@@ -126,5 +126,5 @@
     QBrush symbolBrush( Direction ) const;
 
-    void setSymbolExtent( double width );
+    void setSymbolExtent( double );
     double symbolExtent() const;
 
@@ -151,12 +151,12 @@
         const QRectF &canvasRect, int from, int to ) const;
 
-    virtual void drawUserSymbol( QPainter *, 
+    virtual void drawUserSymbol( QPainter *,
         SymbolStyle, const QwtOHLCSample &,
+        Qt::Orientation, bool inverted, double symbolWidth ) const;
+
+    void drawBar( QPainter *painter, const QwtOHLCSample &,
         Qt::Orientation, bool inverted, double width ) const;
 
-    void drawBar( QPainter *painter, const QwtOHLCSample &, 
-        Qt::Orientation, bool inverted, double width ) const;
-
-    void drawCandleStick( QPainter *, const QwtOHLCSample &, 
+    void drawCandleStick( QPainter *, const QwtOHLCSample &,
         Qt::Orientation, double width ) const;
 
Index: trunk/BNC/qwt/qwt_plot_xml.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_xml.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_xml.cpp	(revision 9383)
@@ -29,5 +29,5 @@
   from a specific editor in the Qwt designer plugin.
 
-  \return QString::null
+  \return QString()
   \warning The plot editor has never been implemented.
 */
@@ -38,5 +38,5 @@
     return title().text();
 #else
-    return QString::null;
+    return QString();
 #endif
 }
Index: trunk/BNC/qwt/qwt_plot_zoneitem.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_zoneitem.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_zoneitem.cpp	(revision 9383)
@@ -14,5 +14,5 @@
 
 class QwtPlotZoneItem::PrivateData
-{   
+{
 public:
     PrivateData():
@@ -24,10 +24,10 @@
         brush = QBrush( c );
     }
-        
+
     Qt::Orientation orientation;
     QPen pen;
     QBrush brush;
     QwtInterval interval;
-};  
+};
 
 /*!
@@ -68,24 +68,24 @@
 }
 
-/*! 
+/*!
   Build and assign a pen
-    
+
   In Qt5 the default pen width is 1.0 ( 0.0 in Qt4 ) what makes it
   non cosmetic ( see QPen::isCosmetic() ). This method has been introduced
   to hide this incompatibility.
-    
+
   \param color Pen color
   \param width Pen width
   \param style Pen style
-    
+
   \sa pen(), brush()
- */ 
+ */
 void QwtPlotZoneItem::setPen( const QColor &color, qreal width, Qt::PenStyle style )
-{   
+{
     setPen( QPen( color, width, style ) );
 }
 
 /*!
-  \brief Assign a pen 
+  \brief Assign a pen
 
   The pen is used to draw the border lines of the zone
@@ -112,7 +112,7 @@
 }
 
-/*! 
-  \brief Assign a brush 
-    
+/*!
+  \brief Assign a brush
+
   The brush is used to fill the zone
 
@@ -141,6 +141,6 @@
   \brief Set the orientation of the zone
 
-  A horizontal zone highlights an interval of the y axis, 
-  a vertical zone of the x axis. It is unbounded in the 
+  A horizontal zone highlights an interval of the y axis,
+  a vertical zone of the x axis. It is unbounded in the
   opposite direction.
 
@@ -196,7 +196,7 @@
     {
         d_data->interval = interval;
-        itemChanged(); 
-    }   
-}   
+        itemChanged();
+    }
+}
 
 /*!
@@ -207,5 +207,5 @@
 {
     return d_data->interval;
-}   
+}
 
 /*!
@@ -286,5 +286,5 @@
 }
 
-/*! 
+/*!
   The bounding rectangle is build from the interval in one direction
   and something invalid for the opposite direction.
Index: trunk/BNC/qwt/qwt_plot_zoneitem.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_zoneitem.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_zoneitem.h	(revision 9383)
@@ -21,13 +21,13 @@
   \brief A plot item, which displays a zone
 
-  A horizontal zone highlights an interval of the y axis - a vertical 
+  A horizontal zone highlights an interval of the y axis - a vertical
   zone an interval of the x axis - and is unbounded in the opposite direction.
-  It is filled with a brush and its border lines are optionally displayed with a pen. 
+  It is filled with a brush and its border lines are optionally displayed with a pen.
 
-  \note For displaying an area that is bounded for x and y coordinates 
+  \note For displaying an area that is bounded for x and y coordinates
         use QwtPlotShapeItem
 */
 
-class QWT_EXPORT QwtPlotZoneItem: 
+class QWT_EXPORT QwtPlotZoneItem:
     public QwtPlotItem
 {
Index: trunk/BNC/qwt/qwt_plot_zoomer.cpp
===================================================================
--- trunk/BNC/qwt/qwt_plot_zoomer.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_zoomer.cpp	(revision 9383)
@@ -14,5 +14,5 @@
 #include <qalgorithms.h>
 
-static QwtInterval qwtExpandedZoomInterval( double v1, double v2, 
+static QwtInterval qwtExpandedZoomInterval( double v1, double v2,
     double minRange, const QwtTransform* transform )
 {
Index: trunk/BNC/qwt/qwt_plot_zoomer.h
===================================================================
--- trunk/BNC/qwt/qwt_plot_zoomer.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_plot_zoomer.h	(revision 9383)
@@ -23,12 +23,12 @@
   the coordinates of the current mouse position.
 
-  Zooming can be repeated as often as possible, limited only by 
+  Zooming can be repeated as often as possible, limited only by
   maxStackDepth() or minZoomSize().  Each rectangle is pushed on a stack.
 
-  The default setting how to select rectangles is 
+  The default setting how to select rectangles is
   a QwtPickerDragRectMachine with the following bindings:
 
   - QwtEventPattern::MouseSelect1\n
-    The first point of the zoom rectangle is selected by a mouse press, 
+    The first point of the zoom rectangle is selected by a mouse press,
     the second point from the position, where the mouse is released.
 
@@ -45,5 +45,5 @@
   - QwtEventPattern::MouseSelect3, QwtEventPattern::KeyUndo\n
     Zoom out one position on the zoom stack
-    
+
   - QwtEventPattern::MouseSelect6, QwtEventPattern::KeyRedo\n
     Zoom in one position on the zoom stack
@@ -53,7 +53,7 @@
 
   The setKeyPattern() and setMousePattern() functions can be used
-  to configure the zoomer actions. The following example 
-  shows, how to configure the 'I' and 'O' keys for zooming in and out 
-  one position on the zoom stack. The "Home" key is used to 
+  to configure the zoomer actions. The following example
+  shows, how to configure the 'I' and 'O' keys for zooming in and out
+  one position on the zoom stack. The "Home" key is used to
   "unzoom" the plot.
 
@@ -103,9 +103,9 @@
 
 public Q_SLOTS:
-    void moveBy( double x, double y );
+    void moveBy( double dx, double dy );
     virtual void moveTo( const QPointF & );
 
     virtual void zoom( const QRectF & );
-    virtual void zoom( int up );
+    virtual void zoom( int offset );
 
 Q_SIGNALS:
Index: trunk/BNC/qwt/qwt_point_3d.cpp
===================================================================
--- trunk/BNC/qwt/qwt_point_3d.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_point_3d.cpp	(revision 9383)
@@ -14,5 +14,5 @@
 QDebug operator<<( QDebug debug, const QwtPoint3D &point )
 {
-    debug.nospace() << "QwtPoint3D(" << point.x() 
+    debug.nospace() << "QwtPoint3D(" << point.x()
         << "," << point.y() << "," << point.z() << ")";
     return debug.space();
Index: trunk/BNC/qwt/qwt_point_data.cpp
===================================================================
--- trunk/BNC/qwt/qwt_point_data.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_point_data.cpp	(revision 9383)
@@ -287,5 +287,5 @@
    interval is calculated from the "rectangle of interest".
 
-   \param index Index of the requested point 
+   \param index Index of the requested point
    \return Calculated x coordinate
 
@@ -297,5 +297,5 @@
         d_interval : d_intervalOfInterest;
 
-    if ( !interval.isValid() ) 
+    if ( !interval.isValid() )
         return 0.0;
 
Index: trunk/BNC/qwt/qwt_point_data.h
===================================================================
--- trunk/BNC/qwt/qwt_point_data.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_point_data.h	(revision 9383)
@@ -26,5 +26,5 @@
 
     virtual size_t size() const;
-    virtual QPointF sample( size_t i ) const;
+    virtual QPointF sample( size_t index ) const;
 
     const QVector<double> &xData() const;
@@ -46,5 +46,5 @@
     virtual QRectF boundingRect() const;
     virtual size_t size() const;
-    virtual QPointF sample( size_t i ) const;
+    virtual QPointF sample( size_t index ) const;
 
     const double *xData() const;
@@ -123,5 +123,5 @@
 
     virtual QRectF boundingRect() const;
-    virtual QPointF sample( size_t i ) const;
+    virtual QPointF sample( size_t index ) const;
 
     /*!
Index: trunk/BNC/qwt/qwt_point_mapper.cpp
===================================================================
--- trunk/BNC/qwt/qwt_point_mapper.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_point_mapper.cpp	(revision 9383)
@@ -23,5 +23,5 @@
 
 #if !defined(QT_NO_QFUTURE)
-#define QWT_USE_THREADS 0
+#define QWT_USE_THREADS 1
 #endif
 
@@ -43,5 +43,5 @@
 static void qwtRenderDots(
     const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-    const QwtDotsCommand command, const QPoint &pos, QImage *image ) 
+    const QwtDotsCommand command, const QPoint &pos, QImage *image )
 {
     const QRgb rgb = command.rgb;
@@ -95,5 +95,5 @@
 
 struct QwtNoRoundF
-{   
+{
     inline double operator()( double value )
     {
@@ -106,8 +106,8 @@
 
 template<class Polygon, class Point, class Round>
-static inline Polygon qwtToPoints( 
+static inline Polygon qwtToPoints(
     const QRectF &boundingRect,
     const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-    const QwtSeriesData<QPointF> *series, 
+    const QwtSeriesData<QPointF> *series,
     int from, int to, Round round )
 {
@@ -169,5 +169,5 @@
     int from, int to )
 {
-    return qwtToPoints<QPolygon, QPoint>( 
+    return qwtToPoints<QPolygon, QPoint>(
         boundingRect, xMap, yMap, series, from, to, QwtRoundI() );
 }
@@ -180,5 +180,5 @@
     int from, int to, Round round )
 {
-    return qwtToPoints<QPolygonF, QPointF>( 
+    return qwtToPoints<QPolygonF, QPointF>(
         boundingRect, xMap, yMap, series, from, to, round );
 }
@@ -188,7 +188,7 @@
 
 template<class Polygon, class Point, class Round>
-static inline Polygon qwtToPolylineFiltered( 
-    const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-    const QwtSeriesData<QPointF> *series, 
+static inline Polygon qwtToPolylineFiltered(
+    const QwtScaleMap &xMap, const QwtScaleMap &yMap,
+    const QwtSeriesData<QPointF> *series,
     int from, int to, Round round )
 {
@@ -239,5 +239,5 @@
     return qwtToPolylineFiltered<QPolygonF, QPointF>(
         xMap, yMap, series, from, to, round );
-} 
+}
 
 template<class Polygon, class Point>
@@ -283,5 +283,5 @@
     return qwtToPointsFiltered<QPolygon, QPoint>(
         boundingRect, xMap, yMap, series, from, to );
-} 
+}
 
 static inline QPolygonF qwtToPointsFilteredF(
@@ -390,5 +390,5 @@
 
   When the WeedOutPoints flag is enabled consecutive points,
-  that are mapped to the same position will be one point. 
+  that are mapped to the same position will be one point.
 
   When RoundPoints is set all points are rounded to integers
@@ -414,10 +414,10 @@
         if ( d_data->flags & RoundPoints )
         {
-            polyline = qwtToPolylineFilteredF( 
+            polyline = qwtToPolylineFilteredF(
                 xMap, yMap, series, from, to, QwtRoundF() );
         }
         else
         {
-            polyline = qwtToPolylineFilteredF( 
+            polyline = qwtToPolylineFilteredF(
                 xMap, yMap, series, from, to, QwtNoRoundF() );
         }
@@ -427,10 +427,10 @@
         if ( d_data->flags & RoundPoints )
         {
-            polyline = qwtToPointsF( qwtInvalidRect, 
+            polyline = qwtToPointsF( qwtInvalidRect,
                 xMap, yMap, series, from, to, QwtRoundF() );
         }
         else
         {
-            polyline = qwtToPointsF( qwtInvalidRect, 
+            polyline = qwtToPointsF( qwtInvalidRect,
                 xMap, yMap, series, from, to, QwtNoRoundF() );
         }
@@ -444,5 +444,5 @@
 
   When the WeedOutPoints flag is enabled consecutive points,
-  that are mapped to the same position will be one point. 
+  that are mapped to the same position will be one point.
 
   \param xMap x map
@@ -462,10 +462,10 @@
     if ( d_data->flags & WeedOutPoints )
     {
-        polyline = qwtToPolylineFilteredI( 
+        polyline = qwtToPolylineFilteredI(
             xMap, yMap, series, from, to );
     }
     else
     {
-        polyline = qwtToPointsI( 
+        polyline = qwtToPointsI(
             qwtInvalidRect, xMap, yMap, series, from, to );
     }
@@ -478,14 +478,14 @@
 
   - WeedOutPoints & RoundPoints & boundingRect().isValid()
-    All points that are mapped to the same position 
+    All points that are mapped to the same position
     will be one point. Points outside of the bounding
     rectangle are ignored.
- 
+
   - WeedOutPoints & RoundPoints & !boundingRect().isValid()
-    All consecutive points that are mapped to the same position 
+    All consecutive points that are mapped to the same position
     will one point
 
-  - WeedOutPoints & !RoundPoints 
-    All consecutive points that are mapped to the same position 
+  - WeedOutPoints & !RoundPoints
+    All consecutive points that are mapped to the same position
     will one point
 
@@ -516,15 +516,15 @@
         {
             if ( d_data->boundingRect.isValid() )
-            {   
+            {
                 points = qwtToPointsFilteredF( d_data->boundingRect,
                     xMap, yMap, series, from, to );
             }
             else
-            {   
+            {
                 // without a bounding rectangle all we can
                 // do is to filter out duplicates of
                 // consecutive points
 
-                points = qwtToPolylineFilteredF( 
+                points = qwtToPolylineFilteredF(
                     xMap, yMap, series, from, to, QwtRoundF() );
             }
@@ -535,5 +535,5 @@
             // qwtToPointsFilteredF
 
-            points = qwtToPolylineFilteredF( 
+            points = qwtToPolylineFilteredF(
                 xMap, yMap, series, from, to, QwtNoRoundF() );
         }
@@ -560,10 +560,10 @@
 
   - WeedOutPoints & boundingRect().isValid()
-    All points that are mapped to the same position 
+    All points that are mapped to the same position
     will be one point. Points outside of the bounding
     rectangle are ignored.
- 
+
   - WeedOutPoints & !boundingRect().isValid()
-    All consecutive points that are mapped to the same position 
+    All consecutive points that are mapped to the same position
     will one point
 
@@ -597,5 +597,5 @@
             // we can do is to filter out consecutive duplicates
 
-            points = qwtToPolylineFilteredI( 
+            points = qwtToPolylineFilteredI(
                 xMap, yMap, series, from, to );
         }
@@ -603,5 +603,5 @@
     else
     {
-        points = qwtToPointsI( 
+        points = qwtToPointsI(
             d_data->boundingRect, xMap, yMap, series, from, to );
     }
@@ -631,5 +631,5 @@
 QImage QwtPointMapper::toImage(
     const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-    const QwtSeriesData<QPointF> *series, int from, int to, 
+    const QwtSeriesData<QPointF> *series, int from, int to,
     const QPen &pen, bool antialiased, uint numThreads ) const
 {
@@ -681,5 +681,5 @@
                 command.to = index0 + numPoints - 1;
 
-                futures += QtConcurrent::run( &qwtRenderDots, 
+                futures += QtConcurrent::run( &qwtRenderDots,
                     xMap, yMap, command, pos, &image );
             }
Index: trunk/BNC/qwt/qwt_point_mapper.h
===================================================================
--- trunk/BNC/qwt/qwt_point_mapper.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_point_mapper.h	(revision 9383)
@@ -23,6 +23,6 @@
 
   QwtPointMapper is a collection of methods and optimizations
-  for translating a series of points into paint device coordinates. 
-  It is used by QwtPlotCurve but might also be useful for 
+  for translating a series of points into paint device coordinates.
+  It is used by QwtPlotCurve but might also be useful for
   similar plot items displaying a QwtSeriesData<QPointF>.
  */
@@ -30,5 +30,5 @@
 {
 public:
-    /*!  
+    /*!
       \brief Flags affecting the transformation process
       \sa setFlag(), setFlags()
@@ -39,5 +39,5 @@
         RoundPoints = 0x01,
 
-        /*! 
+        /*!
           Try to remove points, that are translated to the
           same position.
@@ -46,5 +46,5 @@
     };
 
-    /*!  
+    /*!
       \brief Flags affecting the transformation process
       \sa setFlag(), setFlags()
@@ -77,5 +77,5 @@
 
     QImage toImage( const QwtScaleMap &xMap, const QwtScaleMap &yMap,
-        const QwtSeriesData<QPointF> *series, int from, int to, 
+        const QwtSeriesData<QPointF> *series, int from, int to,
         const QPen &, bool antialiased, uint numThreads ) const;
 
Index: trunk/BNC/qwt/qwt_point_polar.cpp
===================================================================
--- trunk/BNC/qwt/qwt_point_polar.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_point_polar.cpp	(revision 9383)
@@ -112,5 +112,5 @@
 QDebug operator<<( QDebug debug, const QwtPointPolar &point )
 {
-    debug.nospace() << "QwtPointPolar(" 
+    debug.nospace() << "QwtPointPolar("
         << point.azimuth() << "," << point.radius() << ")";
 
Index: trunk/BNC/qwt/qwt_point_polar.h
===================================================================
--- trunk/BNC/qwt/qwt_point_polar.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_point_polar.h	(revision 9383)
@@ -31,5 +31,4 @@
     QwtPointPolar();
     QwtPointPolar( double azimuth, double radius );
-    QwtPointPolar( const QwtPointPolar & );
     QwtPointPolar( const QPointF & );
 
@@ -80,14 +79,4 @@
     d_azimuth( azimuth ),
     d_radius( radius )
-{
-}
-
-/*!
-    Constructs a point using the values of the point specified.
-    \param other Other point
-*/
-inline QwtPointPolar::QwtPointPolar( const QwtPointPolar &other ):
-    d_azimuth( other.d_azimuth ),
-    d_radius( other.d_radius )
 {
 }
@@ -191,7 +180,7 @@
 inline QPointF qwtFastDegree2Pos( const QPointF &pole,
     double radius, double angle )
-{   
+{
     return qwtFastPolar2Pos( pole, radius, angle / 180.0 * M_PI );
-} 
+}
 
 inline QwtPointPolar qwtFastPos2Polar( const QPointF &pos )
@@ -201,3 +190,3 @@
 }
 
-#endif 
+#endif
Index: trunk/BNC/qwt/qwt_raster_data.cpp
===================================================================
--- trunk/BNC/qwt/qwt_raster_data.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_raster_data.cpp	(revision 9383)
@@ -217,11 +217,11 @@
    \brief Pixel hint
 
-   pixelHint() returns the geometry of a pixel, that can be used 
+   pixelHint() returns the geometry of a pixel, that can be used
    to calculate the resolution and alignment of the plot item, that is
-   representing the data. 
-   
-   Width and height of the hint need to be the horizontal  
-   and vertical distances between 2 neighbored points. 
-   The center of the hint has to be the position of any point 
+   representing the data.
+
+   Width and height of the hint need to be the horizontal
+   and vertical distances between 2 neighbored points.
+   The center of the hint has to be the position of any point
    ( it doesn't matter which one ).
 
@@ -230,5 +230,5 @@
    Limiting the resolution of the image might significantly improve
    the performance and heavily reduce the amount of memory when rendering
-   a QImage from the raster data. 
+   a QImage from the raster data.
 
    The default implementation returns an empty rectangle recommending
@@ -238,10 +238,10 @@
                depend on the requested area.
 
-   \return Bounding rectangle of a pixel 
+   \return Bounding rectangle of a pixel
 */
 QRectF QwtRasterData::pixelHint( const QRectF &area ) const
 {
     Q_UNUSED( area );
-    return QRectF(); 
+    return QRectF();
 }
 
@@ -281,4 +281,9 @@
     QwtRasterData *that = const_cast<QwtRasterData *>( this );
     that->initRaster( rect, raster );
+
+#if __GNUC__ >= 9
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-copy"
+#endif
 
     for ( int y = 0; y < raster.height() - 1; y++ )
@@ -399,4 +404,8 @@
     }
 
+#if __GNUC__ >= 9
+#pragma GCC diagnostic pop
+#endif
+
     that->discardRaster();
 
Index: trunk/BNC/qwt/qwt_round_scale_draw.cpp
===================================================================
--- trunk/BNC/qwt/qwt_round_scale_draw.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_round_scale_draw.cpp	(revision 9383)
@@ -185,5 +185,5 @@
    \param painter Painter
    \param value Value of the tick
-   \param len Lenght of the tick
+   \param len Length of the tick
 
    \sa drawBackbone(), drawLabel()
Index: trunk/BNC/qwt/qwt_round_scale_draw.h
===================================================================
--- trunk/BNC/qwt/qwt_round_scale_draw.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_round_scale_draw.h	(revision 9383)
@@ -46,5 +46,5 @@
 
 protected:
-    virtual void drawTick( QPainter *, double val, double len ) const;
+    virtual void drawTick( QPainter *, double value, double len ) const;
     virtual void drawBackbone( QPainter * ) const;
     virtual void drawLabel( QPainter *, double val ) const;
Index: trunk/BNC/qwt/qwt_sampling_thread.h
===================================================================
--- trunk/BNC/qwt/qwt_sampling_thread.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_sampling_thread.h	(revision 9383)
@@ -1,2 +1,11 @@
+/* -*- mode: C++ ; c-file-style: "stroustrup" -*- *****************************
+ * Qwt Widget Library
+ * Copyright (C) 1997   Josef Wilgen
+ * Copyright (C) 2002   Uwe Rathmann
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the Qwt License, Version 1.0
+ *****************************************************************************/
+
 #ifndef _QWT_SAMPLING_THREAD_H_
 #define _QWT_SAMPLING_THREAD_H_
Index: trunk/BNC/qwt/qwt_scale_div.cpp
===================================================================
--- trunk/BNC/qwt/qwt_scale_div.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_div.cpp	(revision 9383)
@@ -71,5 +71,5 @@
 */
 QwtScaleDiv::QwtScaleDiv( double lowerBound, double upperBound,
-        const QList<double> &minorTicks, 
+        const QList<double> &minorTicks,
         const QList<double> &mediumTicks,
         const QList<double> &majorTicks ):
@@ -133,5 +133,5 @@
 {
     return d_lowerBound;
-}   
+}
 
 /*!
@@ -144,5 +144,5 @@
 {
     d_upperBound = upperBound;
-} 
+}
 
 /*!
@@ -219,5 +219,5 @@
 }
 
-/*! 
+/*!
    Invert the scale division
    \sa inverted()
@@ -239,5 +239,5 @@
 }
 
-/*! 
+/*!
   \return A scale division with inverted boundaries and ticks
   \sa invert()
@@ -251,5 +251,5 @@
 }
 
-/*! 
+/*!
    Return a scale division with an interval [lowerBound, upperBound]
    where all ticks outside this interval are removed
@@ -262,5 +262,5 @@
    \note lowerBound might be greater than upperBound for inverted scales
 */
-QwtScaleDiv QwtScaleDiv::bounded( 
+QwtScaleDiv QwtScaleDiv::bounded(
     double lowerBound, double upperBound ) const
 {
Index: trunk/BNC/qwt/qwt_scale_div.h
===================================================================
--- trunk/BNC/qwt/qwt_scale_div.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_div.h	(revision 9383)
@@ -56,5 +56,5 @@
     };
 
-    explicit QwtScaleDiv( double lowerBound = 0.0, 
+    explicit QwtScaleDiv( double lowerBound = 0.0,
         double upperBound = 0.0 );
 
@@ -64,5 +64,5 @@
         QList<double>[NTickTypes] );
 
-    explicit QwtScaleDiv( double lowerBound, double upperBound, 
+    explicit QwtScaleDiv( double lowerBound, double upperBound,
         const QList<double> &minorTicks, const QList<double> &mediumTicks,
         const QList<double> &majorTicks );
Index: trunk/BNC/qwt/qwt_scale_draw.cpp
===================================================================
--- trunk/BNC/qwt/qwt_scale_draw.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_draw.cpp	(revision 9383)
@@ -118,5 +118,5 @@
   \param end End border distance
 */
-void QwtScaleDraw::getBorderDistHint( 
+void QwtScaleDraw::getBorderDistHint(
     const QFont &font, int &start, int &end ) const
 {
@@ -235,5 +235,5 @@
     }
 
-    double angle = qwtRadians( labelRotation() ); 
+    double angle = qwtRadians( labelRotation() );
     if ( vertical )
         angle += M_PI / 2;
@@ -348,5 +348,5 @@
    Find the position, where to paint a label
 
-   The position has a distance that depends on the length of the ticks 
+   The position has a distance that depends on the length of the ticks
    in direction of the alignment().
 
Index: trunk/BNC/qwt/qwt_scale_draw.h
===================================================================
--- trunk/BNC/qwt/qwt_scale_draw.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_draw.h	(revision 9383)
@@ -36,17 +36,17 @@
         \sa setAlignment(), alignment()
      */
-    enum Alignment 
-    { 
+    enum Alignment
+    {
         //! The scale is below
-        BottomScale, 
+        BottomScale,
 
         //! The scale is above
-        TopScale, 
+        TopScale,
 
         //! The scale is left
-        LeftScale, 
+        LeftScale,
 
         //! The scale is right
-        RightScale 
+        RightScale
     };
 
@@ -81,17 +81,17 @@
     int maxLabelWidth( const QFont & ) const;
 
-    QPointF labelPosition( double val ) const;
+    QPointF labelPosition( double value ) const;
 
-    QRectF labelRect( const QFont &, double val ) const;
-    QSizeF labelSize( const QFont &, double val ) const;
+    QRectF labelRect( const QFont &, double value ) const;
+    QSizeF labelSize( const QFont &, double value ) const;
 
-    QRect boundingLabelRect( const QFont &, double val ) const;
+    QRect boundingLabelRect( const QFont &, double value ) const;
 
 protected:
     QTransform labelTransformation( const QPointF &, const QSizeF & ) const;
 
-    virtual void drawTick( QPainter *, double val, double len ) const;
+    virtual void drawTick( QPainter *, double value, double len ) const;
     virtual void drawBackbone( QPainter * ) const;
-    virtual void drawLabel( QPainter *, double val ) const;
+    virtual void drawLabel( QPainter *, double value ) const;
 
 private:
Index: trunk/BNC/qwt/qwt_scale_engine.cpp
===================================================================
--- trunk/BNC/qwt/qwt_scale_engine.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_engine.cpp	(revision 9383)
@@ -32,5 +32,5 @@
 }
 
-static inline QwtInterval qwtPowInterval( double base, const QwtInterval &interval ) 
+static inline QwtInterval qwtPowInterval( double base, const QwtInterval &interval )
 {
     return QwtInterval( qPow( base, interval.minValue() ),
@@ -52,5 +52,5 @@
 static double qwtStepSize( double intervalSize, int maxSteps, uint base )
 {
-    const double minStep = 
+    const double minStep =
         QwtScaleArithmetic::divideInterval( intervalSize, maxSteps, base );
 
@@ -171,6 +171,6 @@
   \return Calculated step size
  */
-double QwtScaleArithmetic::divideInterval( 
-    double intervalSize, int numSteps, uint base ) 
+double QwtScaleArithmetic::divideInterval(
+    double intervalSize, int numSteps, uint base )
 {
     if ( numSteps <= 0 )
@@ -269,5 +269,5 @@
 
 /*!
-   Create and return a clone of the transformation 
+   Create and return a clone of the transformation
    of the engine. When the engine has no special transformation
    NULL is returned, indicating no transformation.
@@ -340,5 +340,5 @@
     double intervalSize, int numSteps ) const
 {
-    return QwtScaleArithmetic::divideInterval( 
+    return QwtScaleArithmetic::divideInterval(
         intervalSize, numSteps, d_data->base );
 }
@@ -468,5 +468,5 @@
 /*!
   \brief Specify a reference point
-  \param r new reference value
+  \param reference New reference value
 
   The reference point is needed if options IncludeReference or
@@ -475,7 +475,7 @@
   \sa Attribute
 */
-void QwtScaleEngine::setReference( double r )
-{
-    d_data->referenceValue = r;
+void QwtScaleEngine::setReference( double reference )
+{
+    d_data->referenceValue = reference;
 }
 
@@ -502,5 +502,5 @@
  */
 void QwtScaleEngine::setBase( uint base )
-{ 
+{
     d_data->base = qMax( base, 2U );
 }
@@ -559,5 +559,5 @@
         interval = buildInterval( interval.minValue() );
 
-    stepSize = QwtScaleArithmetic::divideInterval( 
+    stepSize = QwtScaleArithmetic::divideInterval(
         interval.width(), qMax( maxNumSteps, 1 ), base() );
 
@@ -607,5 +607,5 @@
             maxMajorSteps = 1;
 
-        stepSize = QwtScaleArithmetic::divideInterval( 
+        stepSize = QwtScaleArithmetic::divideInterval(
             interval.width(), maxMajorSteps, base() );
     }
@@ -757,5 +757,5 @@
     double x2 = interval.maxValue();
 
-    // when there is no rounding beside some effect, when 
+    // when there is no rounding beside some effect, when
     // calculating with doubles, we keep the original value
 
@@ -868,5 +868,5 @@
         interval = buildInterval( interval.minValue() );
 
-    stepSize = divideInterval( qwtLogInterval( logBase, interval ).width(), 
+    stepSize = divideInterval( qwtLogInterval( logBase, interval ).width(),
         qMax( maxNumSteps, 1 ) );
     if ( stepSize < 1.0 )
@@ -928,5 +928,5 @@
             maxMajorSteps = 1;
 
-        stepSize = divideInterval( 
+        stepSize = divideInterval(
             qwtLogInterval( logBase, interval ).width(), maxMajorSteps );
         if ( stepSize < 1.0 )
@@ -1033,6 +1033,6 @@
         if ( minStep == 0.0 )
             return;
-        
-        const int numSteps = qRound( stepSize / minStep ); 
+
+        const int numSteps = qRound( stepSize / minStep );
 
         int mediumTickIndex = -1;
@@ -1088,5 +1088,5 @@
 
         if ( numTicks < 1 )
-            return; 
+            return;
 
         int mediumTickIndex = -1;
Index: trunk/BNC/qwt/qwt_scale_engine.h
===================================================================
--- trunk/BNC/qwt/qwt_scale_engine.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_engine.h	(revision 9383)
@@ -26,7 +26,7 @@
     static double floorEps( double value, double intervalSize );
 
-    static double divideEps( double interval, double steps );
-
-    static double divideInterval( double interval, 
+    static double divideEps( double intervalSize, double numSteps );
+
+    static double divideInterval( double intervalSize,
         int numSteps, uint base );
 };
@@ -40,5 +40,5 @@
   The layout of the scale can be varied with setAttribute().
 
-  Qwt offers implementations for logarithmic and linear scales. 
+  Qwt offers implementations for logarithmic and linear scales.
 */
 
@@ -46,5 +46,5 @@
 {
 public:
-    /*! 
+    /*!
        Layout attributes
        \sa setAttribute(), testAttribute(), reference(),
@@ -65,5 +65,5 @@
         /*!
            The endpoints of the scale are supposed to be equal the
-           outmost included values plus the specified margins 
+           outmost included values plus the specified margins
            (see setMargins()).
            If this attribute is *not* set, the endpoints of the scale will
@@ -91,5 +91,5 @@
     Attributes attributes() const;
 
-    void setReference( double reference );
+    void setReference( double );
     double reference() const;
 
@@ -129,10 +129,10 @@
 
 protected:
-    bool contains( const QwtInterval &, double val ) const;
+    bool contains( const QwtInterval &, double value ) const;
     QList<double> strip( const QList<double>&, const QwtInterval & ) const;
 
-    double divideInterval( double interval, int numSteps ) const;
-
-    QwtInterval buildInterval( double v ) const;
+    double divideInterval( double intervalSize, int numSteps ) const;
+
+    QwtInterval buildInterval( double value ) const;
 
 private:
@@ -154,10 +154,10 @@
     virtual ~QwtLinearScaleEngine();
 
-    virtual void autoScale( int maxSteps,
+    virtual void autoScale( int maxNumSteps,
         double &x1, double &x2, double &stepSize ) const;
 
     virtual QwtScaleDiv divideScale( double x1, double x2,
-        int numMajorSteps, int numMinorSteps,
-                                     double stepSize = 0.0 ) const;
+        int maxMajorSteps, int maxMinorSteps,
+        double stepSize = 0.0 ) const;
 
 
@@ -166,5 +166,5 @@
 
     void buildTicks(
-        const QwtInterval &, double stepSize, int maxMinSteps,
+        const QwtInterval &, double stepSize, int maxMinorSteps,
         QList<double> ticks[QwtScaleDiv::NTickTypes] ) const;
 
@@ -194,9 +194,9 @@
     virtual ~QwtLogScaleEngine();
 
-    virtual void autoScale( int maxSteps,
+    virtual void autoScale( int maxNumSteps,
         double &x1, double &x2, double &stepSize ) const;
 
     virtual QwtScaleDiv divideScale( double x1, double x2,
-        int numMajorSteps, int numMinorSteps,
+        int maxMajorSteps, int maxMinorSteps,
         double stepSize = 0.0 ) const;
 
@@ -205,5 +205,5 @@
 
     void buildTicks(
-        const QwtInterval &, double stepSize, int maxMinSteps,
+        const QwtInterval &, double stepSize, int maxMinorSteps,
         QList<double> ticks[QwtScaleDiv::NTickTypes] ) const;
 
Index: trunk/BNC/qwt/qwt_scale_map.cpp
===================================================================
--- trunk/BNC/qwt/qwt_scale_map.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_map.cpp	(revision 9383)
@@ -94,5 +94,5 @@
   \param s1 first border
   \param s2 second border
-  \warning scales might be aligned to 
+  \warning scales might be aligned to
            transformation depending boundaries
 */
@@ -187,7 +187,7 @@
     const QwtScaleMap &yMap, const QPointF &pos )
 {
-    return QPointF( 
-        xMap.invTransform( pos.x() ), 
-        yMap.invTransform( pos.y() ) 
+    return QPointF(
+        xMap.invTransform( pos.x() ),
+        yMap.invTransform( pos.y() )
     );
 }
@@ -206,6 +206,6 @@
     const QwtScaleMap &yMap, const QPointF &pos )
 {
-    return QPointF( 
-        xMap.transform( pos.x() ), 
+    return QPointF(
+        xMap.transform( pos.x() ),
         yMap.transform( pos.y() )
     );
Index: trunk/BNC/qwt/qwt_scale_map.h
===================================================================
--- trunk/BNC/qwt/qwt_scale_map.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_map.h	(revision 9383)
@@ -25,5 +25,5 @@
 
    QwtScaleMap offers transformations from the coordinate system
-   of a scale into the linear coordinate system of a paint device 
+   of a scale into the linear coordinate system of a paint device
    and vice versa.
 */
Index: trunk/BNC/qwt/qwt_scale_widget.cpp
===================================================================
--- trunk/BNC/qwt/qwt_scale_widget.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_widget.cpp	(revision 9383)
@@ -21,4 +21,5 @@
 #include <qstyle.h>
 #include <qstyleoption.h>
+#include <qapplication.h>
 
 class QwtScaleWidget::PrivateData
@@ -146,4 +147,6 @@
         else
             d_data->layoutFlags &= ~flag;
+
+        update();
     }
 }
@@ -574,4 +577,21 @@
     {
         updateGeometry();
+
+#if 1
+        /*
+            for some reason updateGeometry does not send a LayoutRequest event
+            when the parent is not visible and has no layout
+         */
+
+        if ( QWidget* w = parentWidget() )
+        {
+            if ( !w->isVisible() && w->layout() == NULL )
+            {
+                if ( w->testAttribute( Qt::WA_WState_Polished ) )
+                    QApplication::postEvent( w, new QEvent( QEvent::LayoutRequest ) );
+            }
+        }
+#endif
+
         update();
     }
@@ -768,7 +788,7 @@
   is returned.
 
-  \param start Return parameter for the border width at 
+  \param start Return parameter for the border width at
                the beginning of the scale
-  \param end Return parameter for the border width at the 
+  \param end Return parameter for the border width at the
              end of the scale
 
@@ -808,7 +828,7 @@
   the widget borders.
 
-  \param start Return parameter for the border width at 
+  \param start Return parameter for the border width at
                the beginning of the scale
-  \param end Return parameter for the border width at the 
+  \param end Return parameter for the border width at the
              end of the scale
 
Index: trunk/BNC/qwt/qwt_scale_widget.h
===================================================================
--- trunk/BNC/qwt/qwt_scale_widget.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_scale_widget.h	(revision 9383)
@@ -40,5 +40,5 @@
     {
         /*!
-          The title of vertical scales is painted from top to bottom. 
+          The title of vertical scales is painted from top to bottom.
           Otherwise it is painted from bottom to top.
          */
@@ -65,5 +65,5 @@
     bool testLayoutFlag( LayoutFlag ) const;
 
-    void setBorderDist( int start, int end );
+    void setBorderDist( int dist1, int dist2 );
     int startBorderDist() const;
     int endBorderDist() const;
@@ -77,8 +77,8 @@
     int margin() const;
 
-    void setSpacing( int td );
+    void setSpacing( int );
     int spacing() const;
 
-    void setScaleDiv( const QwtScaleDiv &sd );
+    void setScaleDiv( const QwtScaleDiv & );
     void setTransformation( QwtTransform * );
 
@@ -120,8 +120,8 @@
     virtual void resizeEvent( QResizeEvent * );
 
-    void draw( QPainter *p ) const;
+    void draw( QPainter * ) const;
 
     void scaleChange();
-    void layoutScale( bool update = true );
+    void layoutScale( bool update_geometry = true );
 
 private:
Index: trunk/BNC/qwt/qwt_series_data.cpp
===================================================================
--- trunk/BNC/qwt/qwt_series_data.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_series_data.cpp	(revision 9383)
@@ -34,4 +34,7 @@
 static inline QRectF qwtBoundingRect( const QwtSetSample &sample )
 {
+    if ( sample.set.empty() )
+        return QRectF( sample.value, 0.0, 0.0, -1.0 );
+
     double minY = sample.set[0];
     double maxY = sample.set[0];
@@ -41,12 +44,10 @@
         if ( sample.set[i] < minY )
             minY = sample.set[i];
+
         if ( sample.set[i] > maxY )
             maxY = sample.set[i];
     }
 
-    double minX = sample.value;
-    double maxX = sample.value;
-
-    return QRectF( minX, minY, maxX - minX, maxY - minY );
+    return QRectF( sample.value, minY, 0.0, maxY - minY );
 }
 
Index: trunk/BNC/qwt/qwt_series_data.h
===================================================================
--- trunk/BNC/qwt/qwt_series_data.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_series_data.h	(revision 9383)
@@ -26,7 +26,7 @@
    to implement an individual data access.
 
-   A subclass of QwtSeriesData<QPointF> must implement: 
-
-   - size()\n 
+   A subclass of QwtSeriesData<QPointF> must implement:
+
+   - size()\n
      Should return number of data points.
 
@@ -35,12 +35,12 @@
      as QPointF object.
 
-   - boundingRect()\n 
+   - boundingRect()\n
      Should return the bounding rectangle of the data series.
      It is used for autoscaling and might help certain algorithms for displaying
      the data. You can use qwtBoundingRect() for an implementation
-     but often it is possible to implement a more efficient algorithm 
+     but often it is possible to implement a more efficient algorithm
      depending on the characteristics of the series.
      The member d_boundingRect is intended for caching the calculated rectangle.
-    
+
 */
 template <typename T>
@@ -53,4 +53,6 @@
     //! Destructor
     virtual ~QwtSeriesData();
+
+#ifndef QWT_PYTHON_WRAPPER
 
     //! \return Number of samples
@@ -78,4 +80,11 @@
     virtual QRectF boundingRect() const = 0;
 
+#else
+    // Needed for generating the python bindings, but not for using them !
+    virtual size_t size() const { return 0; }
+    virtual T sample( size_t i ) const { return T(); }
+    virtual QRectF boundingRect() const { return d_boundingRect; }
+#endif
+
     /*!
        Set a the "rect of interest"
@@ -86,5 +95,5 @@
 
        The default implementation does nothing.
-   
+
        \param rect Rectangle of interest
     */
@@ -275,54 +284,51 @@
     The following example shows finds a point of curve from an x
     coordinate
-
-  \verbatim
-#include <qwt_series_data.h>
-#include <qwt_plot_curve.h>
-
-struct compareX
-{
-    inline bool operator()( const double x, const QPointF &pos ) const
-    {
-        return ( x < pos.x() );
-    }
-};
-
-QLineF curveLineAt( const QwtPlotCurve *curve, double x )
-{
-    int index = qwtUpperSampleIndex<QPointF>( 
-        *curve->data(), x, compareX() );
-            
-    if ( index == -1 && 
-        x == curve->sample( curve->dataSize() - 1 ).x() )
-    {   
-        // the last sample is excluded from qwtUpperSampleIndex
-        index = curve->dataSize() - 1;
-    }
-
-    QLineF line; // invalid
-    if ( index > 0 )
-    {
-        line.setP1( curve->sample( index - 1 ) );
-        line.setP2( curve->sample( index ) );
-    }
-
-    return line;
-}
-
-\endverbatim
-
-
-    \param series Series of samples
-    \param value Value
-    \param lessThan Compare operation
-
-    \note The samples must be sorted according to the order specified 
-          by the lessThan object
-
-of the range [begin, end) and returns the position of the one-past-the-last occurrence of value. If no such item is found, returns the position where the item should be inserted.
+    \code
+      #include <qwt_series_data.h>
+      #include <qwt_plot_curve.h>
+
+      struct compareX
+      {
+          inline bool operator()( const double x, const QPointF &pos ) const
+          {
+              return ( x < pos.x() );
+          }
+      };
+
+      QLineF curveLineAt( const QwtPlotCurve *curve, double x )
+      {
+          int index = qwtUpperSampleIndex<QPointF>(
+              *curve->data(), x, compareX() );
+
+          if ( index == -1 &&
+              x == curve->sample( curve->dataSize() - 1 ).x() )
+          {
+              // the last sample is excluded from qwtUpperSampleIndex
+              index = curve->dataSize() - 1;
+          }
+
+          QLineF line; // invalid
+          if ( index > 0 )
+          {
+              line.setP1( curve->sample( index - 1 ) );
+              line.setP2( curve->sample( index ) );
+          }
+
+          return line;
+      }
+
+    \endcode
+  \endpar
+
+  \param series Series of samples
+  \param value Value
+  \param lessThan Compare operation
+
+  \note The samples must be sorted according to the order specified
+        by the lessThan object
  */
 template <typename T, typename LessThan>
 inline int qwtUpperSampleIndex( const QwtSeriesData<T> &series,
-    double value, LessThan lessThan  ) 
+    double value, LessThan lessThan  )
 {
     const int indexMax = series.size() - 1;
Index: trunk/BNC/qwt/qwt_series_store.h
===================================================================
--- trunk/BNC/qwt/qwt_series_store.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_series_store.h	(revision 9383)
@@ -28,4 +28,5 @@
     virtual ~QwtAbstractSeriesStore() {}
 
+#ifndef QWT_PYTHON_WRAPPER
     //! dataChanged() indicates, that the series has been changed.
     virtual void dataChanged() = 0;
@@ -42,4 +43,11 @@
     //! \return Number of samples
     virtual size_t dataSize() const = 0;
+#else
+    // Needed for generating the python bindings, but not for using them !
+    virtual void dataChanged() {}
+    virtual void setRectOfInterest( const QRectF & ) {}
+    virtual QRectF dataRect() const { return  QRectF( 0.0, 0.0, -1.0, -1.0 ); }
+    virtual size_t dataSize() const { return 0; }
+#endif
 };
 
Index: trunk/BNC/qwt/qwt_slider.cpp
===================================================================
--- trunk/BNC/qwt/qwt_slider.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_slider.cpp	(revision 9383)
@@ -21,5 +21,5 @@
 #include <qapplication.h>
 
-static QSize qwtHandleSize( const QSize &size, 
+static QSize qwtHandleSize( const QSize &size,
     Qt::Orientation orientation, bool hasTrough )
 {
@@ -42,5 +42,5 @@
 }
 
-static QwtScaleDraw::Alignment qwtScaleDrawAlignment( 
+static QwtScaleDraw::Alignment qwtScaleDrawAlignment(
     Qt::Orientation orientation, QwtSlider::ScalePosition scalePos )
 {
@@ -108,5 +108,5 @@
 /*!
   Construct vertical slider in QwtSlider::Trough style
-  with a scale to the left. 
+  with a scale to the left.
 
   The scale is initialized to [0.0, 100.0] and the value set to 0.0.
@@ -131,5 +131,5 @@
 
   \param parent Parent widget
-  \param orientation Orientation of the slider. 
+  \param orientation Orientation of the slider.
 */
 QwtSlider::QwtSlider( Qt::Orientation orientation, QWidget *parent ):
@@ -158,5 +158,5 @@
     d_data->orientation = orientation;
 
-    scaleDraw()->setAlignment( 
+    scaleDraw()->setAlignment(
         qwtScaleDrawAlignment( orientation, d_data->scalePosition ) );
     scaleDraw()->setLength( 100 );
@@ -179,5 +179,5 @@
     d_data->orientation = orientation;
 
-    scaleDraw()->setAlignment( 
+    scaleDraw()->setAlignment(
         qwtScaleDrawAlignment( orientation, d_data->scalePosition ) );
 
@@ -216,5 +216,5 @@
 
     d_data->scalePosition = scalePosition;
-    scaleDraw()->setAlignment( 
+    scaleDraw()->setAlignment(
         qwtScaleDrawAlignment( d_data->orientation, scalePosition ) );
 
@@ -223,5 +223,5 @@
 }
 
-/*! 
+/*!
   \return Position of the scale
   \sa setScalePosition()
@@ -412,5 +412,5 @@
    \param sliderRect Bounding rectangle of the slider
 */
-void QwtSlider::drawSlider( 
+void QwtSlider::drawSlider(
     QPainter *painter, const QRect &sliderRect ) const
 {
@@ -434,5 +434,5 @@
         const int slotMargin = 4;
 
-        QRect slotRect; 
+        QRect slotRect;
         if ( orientation() == Qt::Horizontal )
         {
@@ -470,10 +470,10 @@
   \param pos Position of the handle marker in widget coordinates
 */
-void QwtSlider::drawHandle( QPainter *painter, 
+void QwtSlider::drawHandle( QPainter *painter,
     const QRect &handleRect, int pos ) const
 {
     const int bw = d_data->borderWidth;
 
-    qDrawShadePanel( painter, 
+    qDrawShadePanel( painter,
         handleRect, palette(), false, bw,
         &palette().brush( QPalette::Button ) );
@@ -497,5 +497,5 @@
   \param pos Mouse position
 
-  \retval True, when handleRect() contains pos 
+  \retval True, when handleRect() contains pos
   \sa scrolledTo()
 */
@@ -504,5 +504,5 @@
     if ( handleRect().contains( pos ) )
     {
-        const double v = ( orientation() == Qt::Horizontal ) 
+        const double v = ( orientation() == Qt::Horizontal )
             ? pos.x() : pos.y();
 
@@ -525,5 +525,5 @@
 double QwtSlider::scrolledTo( const QPoint &pos ) const
 {
-    int p = ( orientation() == Qt::Horizontal ) 
+    int p = ( orientation() == Qt::Horizontal )
         ? pos.x() : pos.y();
 
@@ -629,5 +629,5 @@
 
    \param event Mouse event
-*/  
+*/
 void QwtSlider::timerEvent( QTimerEvent *event )
 {
@@ -663,7 +663,7 @@
         killTimer( d_data->repeatTimerId );
         d_data->repeatTimerId = startTimer( updateInterval() );
-        
+
         d_data->timerTick = true;
-    }   
+    }
 }
 
@@ -710,5 +710,5 @@
 void QwtSlider::changeEvent( QEvent *event )
 {
-    if ( event->type() == QEvent::StyleChange || 
+    if ( event->type() == QEvent::StyleChange ||
         event->type() == QEvent::FontChange )
     {
@@ -740,5 +740,5 @@
     /*
        The marker line of the handle needs to be aligned to
-       the scale. But the marker is in the center 
+       the scale. But the marker is in the center
        and we need space enough to display the rest of the handle.
 
@@ -878,5 +878,5 @@
     {
         d_data->hasGroove = on;
-        
+
         if ( testAttribute( Qt::WA_WState_Polished ) )
             layoutSlider( true );
@@ -891,5 +891,5 @@
 {
     return d_data->hasGroove;
-} 
+}
 
 /*!
@@ -918,5 +918,5 @@
         bw = d_data->borderWidth;
 
-    int sliderLength = 0; 
+    int sliderLength = 0;
     int scaleExtent = 0;
 
Index: trunk/BNC/qwt/qwt_slider.h
===================================================================
--- trunk/BNC/qwt/qwt_slider.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_slider.h	(revision 9383)
@@ -84,5 +84,5 @@
     QSize handleSize() const;
 
-    void setBorderWidth( int bw );
+    void setBorderWidth( int );
     int borderWidth() const;
 
Index: trunk/BNC/qwt/qwt_symbol.cpp
===================================================================
--- trunk/BNC/qwt/qwt_symbol.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_symbol.cpp	(revision 9383)
@@ -32,5 +32,5 @@
 }
 
-static QwtGraphic qwtPathGraphic( const QPainterPath &path, 
+static QwtGraphic qwtPathGraphic( const QPainterPath &path,
     const QPen &pen, const QBrush& brush )
 {
@@ -47,5 +47,5 @@
 }
 
-static inline QRectF qwtScaledBoundingRect( 
+static inline QRectF qwtScaledBoundingRect(
     const QwtGraphic &graphic, const QSizeF size )
 {
@@ -53,5 +53,5 @@
     if ( scaledSize.isEmpty() )
         scaledSize = graphic.defaultSize();
-        
+
     const QSizeF sz = graphic.controlPointRect().size();
 
@@ -59,5 +59,5 @@
     if ( sz.width() > 0.0 )
         sx = scaledSize.width() / sz.width();
-    
+
     double sy = 1.0;
     if ( sz.height() > 0.0 )
@@ -84,5 +84,5 @@
     if ( pm.size() != size )
         pm = pm.scaled( size );
-    
+
     QPointF pinPoint( 0.5 * size.width(), 0.5 * size.height() );
     if ( symbol.isPinPointEnabled() )
@@ -95,5 +95,5 @@
         const QPointF pos = transform.map( points[i] ) - pinPoint;
 
-        QwtPainter::drawPixmap( painter, 
+        QwtPainter::drawPixmap( painter,
             QRect( pos.toPoint(), pm.size() ), pm );
     }
@@ -102,6 +102,6 @@
 #ifndef QWT_NO_SVG
 
-static inline void qwtDrawSvgSymbols( QPainter *painter, 
-    const QPointF *points, int numPoints, 
+static inline void qwtDrawSvgSymbols( QPainter *painter,
+    const QPointF *points, int numPoints,
     QSvgRenderer *renderer, const QwtSymbol &symbol )
 {
@@ -132,5 +132,5 @@
         const double y = points[i].y() - dy;
 
-        renderer->render( painter, 
+        renderer->render( painter,
             QRectF( x, y, sz.width(), sz.height() ) );
     }
@@ -139,5 +139,5 @@
 #endif
 
-static inline void qwtDrawGraphicSymbols( QPainter *painter, 
+static inline void qwtDrawGraphicSymbols( QPainter *painter,
     const QPointF *points, int numPoints, const QwtGraphic &graphic,
     const QwtSymbol &symbol )
@@ -876,5 +876,5 @@
 */
 
-QwtSymbol::QwtSymbol( const QPainterPath &path, 
+QwtSymbol::QwtSymbol( const QPainterPath &path,
     const QBrush &brush, const QPen &pen )
 {
@@ -919,5 +919,5 @@
   \brief Set a painter path as symbol
 
-  The symbol is represented by a painter path, where the 
+  The symbol is represented by a painter path, where the
   origin ( 0, 0 ) of the path coordinate system is mapped to
   the position of the symbol.
@@ -927,34 +927,36 @@
   the bounding rectangle of the path.
 
-  The following code defines a symbol drawing an arrow:
-
-  \verbatim
-#include <qwt_symbol.h>
-
-QwtSymbol *symbol = new QwtSymbol();
-
-QPen pen( Qt::black, 2 );
-pen.setJoinStyle( Qt::MiterJoin );
-
-symbol->setPen( pen );
-symbol->setBrush( Qt::red );
-
-QPainterPath path;
-path.moveTo( 0, 8 );
-path.lineTo( 0, 5 );
-path.lineTo( -3, 5 );
-path.lineTo( 0, 0 );
-path.lineTo( 3, 5 );
-path.lineTo( 0, 5 );
-
-QTransform transform;
-transform.rotate( -30.0 );
-path = transform.map( path );
-
-symbol->setPath( path );
-symbol->setPinPoint( QPointF( 0.0, 0.0 ) );
-
-setSize( 10, 14 );
-\endverbatim
+  \par Example
+    The following code defines a symbol drawing an arrow:
+
+    \code
+      #include <qwt_symbol.h>
+
+      QwtSymbol *symbol = new QwtSymbol();
+
+      QPen pen( Qt::black, 2 );
+      pen.setJoinStyle( Qt::MiterJoin );
+
+      symbol->setPen( pen );
+      symbol->setBrush( Qt::red );
+
+      QPainterPath path;
+      path.moveTo( 0, 8 );
+      path.lineTo( 0, 5 );
+      path.lineTo( -3, 5 );
+      path.lineTo( 0, 0 );
+      path.lineTo( 3, 5 );
+      path.lineTo( 0, 5 );
+
+      QTransform transform;
+      transform.rotate( -30.0 );
+      path = transform.map( path );
+
+      symbol->setPath( path );
+      symbol->setPinPoint( QPointF( 0.0, 0.0 ) );
+
+      setSize( 10, 14 );
+    \endcode
+  \endpar
 
   \param path Painter path
@@ -1237,8 +1239,8 @@
   The position of a complex symbol is not always aligned to its center
   ( f.e an arrow, where the peak points to a position ). The pin point
-  defines the position inside of a Pixmap, Graphic, SvgDocument 
+  defines the position inside of a Pixmap, Graphic, SvgDocument
   or PainterPath symbol where the represented point has to
   be aligned to.
-  
+
   \param pos Position
   \param enable En/Disable the pin point alignment
@@ -1341,10 +1343,10 @@
                     {
                         if ( !d_data->size.isEmpty() &&
-                            d_data->size != d_data->pixmap.pixmap.size() ) 
+                            d_data->size != d_data->pixmap.pixmap.size() )
                         {
                             useCache = true;
                         }
                         break;
-                    }                       
+                    }
                     default:
                         useCache = true;
@@ -1358,6 +1360,4 @@
         const QRect br = boundingRect();
 
-        const QRect rect( 0, 0, br.width(), br.height() );
-        
         if ( d_data->cache.pixmap.isNull() )
         {
@@ -1402,5 +1402,5 @@
 
   \param painter Painter
-  \param rect Target rectangle for the symbol 
+  \param rect Target rectangle for the symbol
 */
 void QwtSymbol::drawSymbol( QPainter *painter, const QRectF &rect ) const
@@ -1411,5 +1411,5 @@
     if ( d_data->style == QwtSymbol::Graphic )
     {
-        d_data->graphic.graphic.render( 
+        d_data->graphic.graphic.render(
             painter, rect, Qt::KeepAspectRatio );
     }
@@ -1418,9 +1418,9 @@
         if ( d_data->path.graphic.isNull() )
         {
-            d_data->path.graphic = qwtPathGraphic( 
+            d_data->path.graphic = qwtPathGraphic(
                 d_data->path.path, d_data->pen, d_data->brush );
         }
 
-        d_data->path.graphic.render( 
+        d_data->path.graphic.render(
             painter, rect, Qt::KeepAspectRatio );
         return;
@@ -1445,5 +1445,5 @@
             }
 
-            d_data->svg.renderer->render( 
+            d_data->svg.renderer->render(
                 painter, scaledRect );
         }
@@ -1456,5 +1456,5 @@
         // scale the symbol size to fit into rect.
 
-        const double ratio = qMin( rect.width() / br.width(), 
+        const double ratio = qMin( rect.width() / br.width(),
             rect.height() / br.height() );
 
@@ -1469,5 +1469,5 @@
         const QPointF pos;
         renderSymbols( painter, &pos, 1 );
-    
+
         d_data->isPinPointEnabled = isPinPointEnabled;
 
@@ -1570,9 +1570,9 @@
             if ( d_data->path.graphic.isNull() )
             {
-                d_data->path.graphic = qwtPathGraphic( d_data->path.path, 
+                d_data->path.graphic = qwtPathGraphic( d_data->path.path,
                     d_data->pen, d_data->brush );
             }
 
-            qwtDrawGraphicSymbols( painter, points, numPoints, 
+            qwtDrawGraphicSymbols( painter, points, numPoints,
                 d_data->path.graphic, *this );
             break;
@@ -1585,5 +1585,5 @@
         case QwtSymbol::Graphic:
         {
-            qwtDrawGraphicSymbols( painter, points, numPoints, 
+            qwtDrawGraphicSymbols( painter, points, numPoints,
                 d_data->graphic.graphic, *this );
             break;
@@ -1592,5 +1592,5 @@
         {
 #ifndef QWT_NO_SVG
-            qwtDrawSvgSymbols( painter, points, numPoints, 
+            qwtDrawSvgSymbols( painter, points, numPoints,
                 d_data->svg.renderer, *this );
 #endif
@@ -1654,5 +1654,5 @@
             }
 
-            rect = qwtScaledBoundingRect( 
+            rect = qwtScaledBoundingRect(
                 d_data->path.graphic, d_data->size );
             pinPointTranslation = true;
@@ -1666,5 +1666,5 @@
             else
                 rect.setSize( d_data->size );
-            
+
             pinPointTranslation = true;
 
@@ -1673,5 +1673,5 @@
         case QwtSymbol::Graphic:
         {
-            rect = qwtScaledBoundingRect( 
+            rect = qwtScaledBoundingRect(
                 d_data->graphic.graphic, d_data->size );
             pinPointTranslation = true;
Index: trunk/BNC/qwt/qwt_symbol.h
===================================================================
--- trunk/BNC/qwt/qwt_symbol.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_symbol.h	(revision 9383)
@@ -86,5 +86,5 @@
 
         /*!
-          The symbol is represented by a painter path, where the 
+          The symbol is represented by a painter path, where the
           origin ( 0, 0 ) of the path coordinate system is mapped to
           the position of the symbol.
@@ -132,5 +132,5 @@
 
       F.e. the raster paint engine is a pure software renderer
-      where in cache mode a draw operation usually ends in 
+      where in cache mode a draw operation usually ends in
       raster operation with the the backing store, that are usually
       faster, than the algorithms for rendering polygons.
@@ -142,5 +142,5 @@
       \sa setCachePolicy(), cachePolicy()
 
-      \note The policy has no effect, when the symbol is painted 
+      \note The policy has no effect, when the symbol is painted
             to a vector graphics format ( PDF, SVG ).
       \warning Since Qt 4.8 raster is the default backend on X11
@@ -155,8 +155,8 @@
         Cache,
 
-        /*! 
+        /*!
            Use a cache when one of the following conditions is true:
 
-           - The symbol is rendered with the software 
+           - The symbol is rendered with the software
              renderer ( QPaintEngine::Raster )
          */
@@ -176,5 +176,5 @@
     void setSize( const QSize & );
     void setSize( int width, int height = -1 );
-    const QSize& size() const;
+    const QSize &size() const;
 
     void setPinPoint( const QPointF &pos, bool enable = true );
@@ -186,10 +186,10 @@
     virtual void setColor( const QColor & );
 
-    void setBrush( const QBrush& b );
-    const QBrush& brush() const;
+    void setBrush( const QBrush & );
+    const QBrush &brush() const;
 
     void setPen( const QColor &, qreal width = 0.0, Qt::PenStyle = Qt::SolidLine );
     void setPen( const QPen & );
-    const QPen& pen() const;
+    const QPen &pen() const;
 
     void setStyle( Style );
Index: trunk/BNC/qwt/qwt_system_clock.cpp
===================================================================
--- trunk/BNC/qwt/qwt_system_clock.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_system_clock.cpp	(revision 9383)
@@ -33,10 +33,10 @@
     delete d_data;
 }
-    
+
 bool QwtSystemClock::isNull() const
 {
     return d_data->timer.isValid();
 }
-        
+
 void QwtSystemClock::start()
 {
@@ -55,5 +55,5 @@
     return nsecs / 1e6;
 }
-    
+
 #else // !USE_ELAPSED_TIMER
 
@@ -357,5 +357,5 @@
 
 /*!
-  Set the start time to the current time 
+  Set the start time to the current time
   \return Time, that is elapsed since the previous start time.
 */
Index: trunk/BNC/qwt/qwt_system_clock.h
===================================================================
--- trunk/BNC/qwt/qwt_system_clock.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_system_clock.h	(revision 9383)
@@ -23,6 +23,9 @@
   Precision and time intervals are multiples of milliseconds (ms).
 
+  ( QwtSystemClock is obsolete since Qt 4.8 as QElapsedTimer offers the same
+    precision )
+
   \note The implementation uses high-resolution performance counter on Windows,
-        mach_absolute_time() on the Mac or POSIX timers on other systems. 
+        mach_absolute_time() on the Mac or POSIX timers on other systems.
         If none is available it falls back on QTimer.
 */
Index: trunk/BNC/qwt/qwt_text.cpp
===================================================================
--- trunk/BNC/qwt/qwt_text.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_text.cpp	(revision 9383)
@@ -62,6 +62,6 @@
 QwtTextEngineDict::~QwtTextEngineDict()
 {
-    for ( EngineMap::const_iterator it = d_map.begin();
-        it != d_map.end(); ++it )
+    for ( EngineMap::const_iterator it = d_map.constBegin();
+        it != d_map.constEnd(); ++it )
     {
         const QwtTextEngine *textEngine = engine( it );
@@ -108,11 +108,8 @@
         return;
 
-    EngineMap::const_iterator it = d_map.find( format );
-    if ( it != d_map.end() )
-    {
-        const QwtTextEngine *e = this->engine( it );
-        if ( e )
-            delete e;
-
+    EngineMap::const_iterator it = d_map.constFind( format );
+    if ( it != d_map.constEnd() )
+    {
+        delete this->engine( it );
         d_map.remove( format );
     }
Index: trunk/BNC/qwt/qwt_text.h
===================================================================
--- trunk/BNC/qwt/qwt_text.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_text.h	(revision 9383)
@@ -81,8 +81,11 @@
           Use a MathML (http://en.wikipedia.org/wiki/MathML) render engine
           to display the text. The Qwt MathML extension offers such an engine
-          based on the MathML renderer of the Qt solutions package. 
+          based on the MathML renderer of the former Qt solutions package.
           To enable MathML support the following code needs to be added to the
           application:
-\verbatim QwtText::setTextEngine(QwtText::MathMLText, new QwtMathMLTextEngine()); \endverbatim
+
+          \code
+            QwtText::setTextEngine( QwtText::MathMLText, new QwtMathMLTextEngine() );
+          \endcode
          */
         MathMLText,
@@ -140,5 +143,5 @@
     typedef QFlags<LayoutAttribute> LayoutAttributes;
 
-    QwtText( const QString & = QString::null,
+    QwtText( const QString & = QString(),
              TextFormat textFormat = AutoText );
     QwtText( const QwtText & );
@@ -162,5 +165,5 @@
     QFont usedFont( const QFont & ) const;
 
-    void setRenderFlags( int flags );
+    void setRenderFlags( int );
     int renderFlags() const;
 
@@ -190,5 +193,5 @@
     void draw( QPainter *painter, const QRectF &rect ) const;
 
-    static const QwtTextEngine *textEngine( 
+    static const QwtTextEngine *textEngine(
         const QString &text, QwtText::TextFormat = AutoText );
 
Index: trunk/BNC/qwt/qwt_text_engine.cpp
===================================================================
--- trunk/BNC/qwt/qwt_text_engine.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_text_engine.cpp	(revision 9383)
@@ -86,12 +86,13 @@
 
         QMap<QString, int>::const_iterator it =
-            d_ascentCache.find( fontKey );
-        if ( it == d_ascentCache.end() )
-        {
-            int ascent = findAscent( font );
-            it = d_ascentCache.insert( fontKey, ascent );
-        }
-
-        return ( *it );
+            d_ascentCache.constFind( fontKey );
+
+        if ( it != d_ascentCache.constEnd() )
+            return *it;
+
+        const int ascent = findAscent( font );
+        d_ascentCache.insert( fontKey, ascent );
+
+        return ascent;
     }
 
@@ -116,5 +117,5 @@
         for ( row = 0; row < img.height(); row++ )
         {
-            const QRgb *line = reinterpret_cast<const QRgb *>( 
+            const QRgb *line = reinterpret_cast<const QRgb *>(
                 img.scanLine( row ) );
 
Index: trunk/BNC/qwt/qwt_text_engine.h
===================================================================
--- trunk/BNC/qwt/qwt_text_engine.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_text_engine.h	(revision 9383)
@@ -26,8 +26,8 @@
 
   QwtPlainTextEngine and QwtRichTextEngine are part of the Qwt library.
-  The implementation of QwtMathMLTextEngine uses code from the 
+  The implementation of QwtMathMLTextEngine uses code from the
   Qt solution package. Because of license implications it is built into
   a separate library.
- 
+
   \sa QwtText::setTextEngine()
 */
Index: trunk/BNC/qwt/qwt_text_label.cpp
===================================================================
--- trunk/BNC/qwt/qwt_text_label.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_text_label.cpp	(revision 9383)
@@ -90,5 +90,5 @@
   \sa QwtText
 */
-void QwtTextLabel::setText( const QString &text, 
+void QwtTextLabel::setText( const QString &text,
     QwtText::TextFormat textFormat )
 {
Index: trunk/BNC/qwt/qwt_text_label.h
===================================================================
--- trunk/BNC/qwt/qwt_text_label.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_text_label.h	(revision 9383)
@@ -64,5 +64,5 @@
 
 protected:
-    virtual void paintEvent( QPaintEvent *e );
+    virtual void paintEvent( QPaintEvent * );
     virtual void drawContents( QPainter * );
 
Index: trunk/BNC/qwt/qwt_thermo.cpp
===================================================================
--- trunk/BNC/qwt/qwt_thermo.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_thermo.cpp	(revision 9383)
@@ -20,5 +20,5 @@
 #include <qmath.h>
 
-static inline void qwtDrawLine( QPainter *painter, int pos, 
+static inline void qwtDrawLine( QPainter *painter, int pos,
     const QColor &color, const QRect &pipeRect, const QRect &liquidRect,
     Qt::Orientation orientation )
@@ -59,9 +59,9 @@
             if ( v > lowerLimit && v < upperLimit )
                 values += v;
-        }       
-    }   
+        }
+    }
 
     values += upperLimit;
-    
+
     return values;
 }
@@ -249,7 +249,7 @@
 
     const QBrush brush = palette().brush( QPalette::Base );
-    qDrawShadePanel( &painter, 
+    qDrawShadePanel( &painter,
         tRect.adjusted( -bw, -bw, bw, bw ),
-        palette(), true, bw, 
+        palette(), true, bw,
         d_data->autoFillPipe ? &brush : NULL );
 
@@ -257,5 +257,5 @@
 }
 
-/*! 
+/*!
   Resize event handler
   \param event Resize event
@@ -267,5 +267,5 @@
 }
 
-/*! 
+/*!
   Qt change event handler
   \param event Event
@@ -411,5 +411,5 @@
         if ( d_data->scalePosition == QwtThermo::LeadingScale )
             pipeRect.setLeft( bw );
-        else 
+        else
             pipeRect.setLeft( cr.left() + cr.width() - bw - d_data->pipeWidth );
 
@@ -540,5 +540,5 @@
    \param pipeRect Bounding rectangle of the pipe without borders
 */
-void QwtThermo::drawLiquid( 
+void QwtThermo::drawLiquid(
     QPainter *painter, const QRect &pipeRect ) const
 {
@@ -582,5 +582,5 @@
                 const double v = scaleMap.invTransform( pos );
 
-                qwtDrawLine( painter, pos, 
+                qwtDrawLine( painter, pos,
                     d_data->colorMap->color( interval, v ),
                     pipeRect, liquidRect, d_data->orientation );
@@ -708,8 +708,8 @@
 /*!
   \brief Change the brush of the liquid.
- 
+
   Changes the QPalette::ButtonText brush of the palette.
 
-  \param brush New brush. 
+  \param brush New brush.
   \sa fillBrush(), QWidget::setPalette()
 */
@@ -722,5 +722,5 @@
 
 /*!
-  \return Liquid ( QPalette::ButtonText ) brush. 
+  \return Liquid ( QPalette::ButtonText ) brush.
   \sa setFillBrush(), QWidget::palette()
 */
@@ -735,5 +735,5 @@
   Changes the QPalette::Highlight brush of the palette.
 
-  \param brush New brush. 
+  \param brush New brush.
   \sa alarmBrush(), QWidget::setPalette()
 
@@ -825,5 +825,5 @@
 }
 
-/*! 
+/*!
   \return True, when the alarm threshold is enabled.
 
@@ -894,5 +894,5 @@
 QRect QwtThermo::fillRect( const QRect &pipeRect ) const
 {
-    double origin;        
+    double origin;
     if ( d_data->originMode == OriginMinimum )
     {
@@ -915,5 +915,5 @@
     if ( to < from )
         qSwap( from, to );
-    
+
     QRect fillRect = pipeRect;
     if ( d_data->orientation == Qt::Horizontal )
@@ -947,5 +947,5 @@
 
     const bool inverted = ( upperBound() < lowerBound() );
-    
+
     bool increasing;
     if ( d_data->originMode == OriginCustom )
@@ -961,5 +961,5 @@
     const int alarmPos = qRound( map.transform( d_data->alarmLevel ) );
     const int valuePos = qRound( map.transform( d_data->value ) );
-    
+
     if ( d_data->orientation == Qt::Horizontal )
     {
@@ -1003,3 +1003,3 @@
 
     return alarmRect;
-} 
+}
Index: trunk/BNC/qwt/qwt_thermo.h
===================================================================
--- trunk/BNC/qwt/qwt_thermo.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_thermo.h	(revision 9383)
@@ -30,5 +30,5 @@
 
   The fill colors might be calculated from an optional color map
-  If no color map has been assigned QwtThermo uses the 
+  If no color map has been assigned QwtThermo uses the
   following colors/brushes from the widget palette:
 
@@ -53,5 +53,5 @@
     Q_PROPERTY( Qt::Orientation orientation
         READ orientation WRITE setOrientation )
-    Q_PROPERTY( ScalePosition scalePosition 
+    Q_PROPERTY( ScalePosition scalePosition
         READ scalePosition WRITE setScalePosition )
     Q_PROPERTY( OriginMode originMode READ originMode WRITE setOriginMode )
@@ -113,5 +113,5 @@
     int spacing() const;
 
-    void setBorderWidth( int w );
+    void setBorderWidth( int );
     int borderWidth() const;
 
@@ -122,14 +122,14 @@
     double origin() const;
 
-    void setFillBrush( const QBrush &b );
+    void setFillBrush( const QBrush & );
     QBrush fillBrush() const;
 
-    void setAlarmBrush( const QBrush &b );
+    void setAlarmBrush( const QBrush & );
     QBrush alarmBrush() const;
 
-    void setAlarmLevel( double v );
+    void setAlarmLevel( double );
     double alarmLevel() const;
 
-    void setAlarmEnabled( bool tf );
+    void setAlarmEnabled( bool );
     bool alarmEnabled() const;
 
@@ -138,5 +138,5 @@
     const QwtColorMap *colorMap() const;
 
-    void setPipeWidth( int w );
+    void setPipeWidth( int );
     int pipeWidth() const;
 
@@ -153,5 +153,5 @@
 
 public Q_SLOTS:
-    virtual void setValue( double val );
+    virtual void setValue( double );
 
 protected:
Index: trunk/BNC/qwt/qwt_transform.cpp
===================================================================
--- trunk/BNC/qwt/qwt_transform.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_transform.cpp	(revision 9383)
@@ -19,5 +19,5 @@
 //! Smallest allowed value for logarithmic scales: 1.0e-150
 const double QwtLogTransform::LogMin = 1.0e-150;
-    
+
 //! Largest allowed value for logarithmic scales: 1.0e150
 const double QwtLogTransform::LogMax = 1.0e150;
@@ -43,5 +43,5 @@
 }
 
-/*! 
+/*!
   \param value Value to be bounded
   \return value unmodified
@@ -63,5 +63,5 @@
 }
 
-/*! 
+/*!
   \param value Value to be transformed
   \return value unmodified
@@ -72,5 +72,5 @@
 }
 
-/*! 
+/*!
   \param value Value to be transformed
   \return value unmodified
@@ -98,5 +98,5 @@
 }
 
-/*! 
+/*!
   \param value Value to be transformed
   \return log( value )
@@ -107,5 +107,5 @@
 }
 
-/*! 
+/*!
   \param value Value to be transformed
   \return exp( value )
@@ -116,5 +116,5 @@
 }
 
-/*! 
+/*!
   \param value Value to be bounded
   \return qBound( LogMin, value, LogMax )
@@ -146,5 +146,5 @@
 }
 
-/*! 
+/*!
   \param value Value to be transformed
   \return Exponentiation preserving the sign
@@ -156,8 +156,8 @@
     else
         return qPow( value, 1.0 / d_exponent );
-    
+
 }
 
-/*! 
+/*!
   \param value Value to be transformed
   \return Inverse exponentiation preserving the sign
Index: trunk/BNC/qwt/qwt_transform.h
===================================================================
--- trunk/BNC/qwt/qwt_transform.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_transform.h	(revision 9383)
@@ -73,5 +73,5 @@
 
    QwtNullTransform returns the values unmodified.
-   
+
  */
 class QWT_EXPORT QwtNullTransform: public QwtTransform
@@ -92,13 +92,13 @@
 
    \note In the calculations of QwtScaleMap the base of the log function
-         has no effect on the mapping. So QwtLogTransform can be used 
+         has no effect on the mapping. So QwtLogTransform can be used
          for log2(), log10() or any other logarithmic scale.
  */
 class QWT_EXPORT QwtLogTransform: public QwtTransform
-{   
+{
 public:
     QwtLogTransform();
     virtual ~QwtLogTransform();
-    
+
     virtual double transform( double value ) const;
     virtual double invTransform( double value ) const;
@@ -120,5 +120,5 @@
    \brief A transformation using pow()
 
-   QwtPowerTransform preserves the sign of a value. 
+   QwtPowerTransform preserves the sign of a value.
    F.e. a transformation with a factor of 2
    transforms a value of -3 to -9 and v.v. Thus QwtPowerTransform
Index: trunk/BNC/qwt/qwt_wheel.cpp
===================================================================
--- trunk/BNC/qwt/qwt_wheel.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_wheel.cpp	(revision 9383)
@@ -55,5 +55,5 @@
         wrapping( false )
     {
-    };
+    }
 
     Qt::Orientation orientation;
@@ -114,6 +114,6 @@
   \brief En/Disable tracking
 
-  If tracking is enabled (the default), the wheel emits the valueChanged() 
-  signal while the wheel is moving. If tracking is disabled, the wheel 
+  If tracking is enabled (the default), the wheel emits the valueChanged()
+  signal while the wheel is moving. If tracking is disabled, the wheel
   emits the valueChanged() signal only when the wheel movement is terminated.
 
@@ -162,5 +162,5 @@
    \brief Mouse press event handler
 
-   Start movement of the wheel. 
+   Start movement of the wheel.
 
    \param event Mouse event
@@ -209,11 +209,11 @@
         d_data->speed = ( mouseValue - d_data->mouseValue ) / ms;
     }
-    
-    d_data->mouseValue = mouseValue; 
+
+    d_data->mouseValue = mouseValue;
 
     double value = boundedValue( mouseValue - d_data->mouseOffset );
     if ( d_data->stepAlignment )
         value = alignedValue( value );
-        
+
     if ( value != d_data->value )
     {
@@ -238,5 +238,5 @@
 
    \param event Mouse event
-*/  
+*/
 
 void QwtWheel::mouseReleaseEvent( QMouseEvent *event )
@@ -260,5 +260,5 @@
     if ( startFlying )
     {
-        d_data->flyingValue = 
+        d_data->flyingValue =
             boundedValue( d_data->mouseValue - d_data->mouseOffset );
 
@@ -281,5 +281,5 @@
 
   The flying wheel effect is implemented using a timer
-   
+
   \param event Timer event
 
@@ -323,5 +323,5 @@
   \brief Handle wheel events
 
-  In/Decrement the value 
+  In/Decrement the value
 
   \param event Wheel event
@@ -342,5 +342,5 @@
     double increment = 0.0;
 
-    if ( ( event->modifiers() & Qt::ControlModifier) || 
+    if ( ( event->modifiers() & Qt::ControlModifier) ||
         ( event->modifiers() & Qt::ShiftModifier ) )
     {
@@ -384,10 +384,10 @@
 
   - Qt::Key_Up\n
-    In case of a horizontal or not inverted vertical wheel the value 
+    In case of a horizontal or not inverted vertical wheel the value
     will be incremented by the step size. For an inverted vertical wheel
     the value will be decremented by the step size.
 
   - Qt::Key_Down\n
-    In case of a horizontal or not inverted vertical wheel the value 
+    In case of a horizontal or not inverted vertical wheel the value
     will be decremented by the step size. For an inverted vertical wheel
     the value will be incremented by the step size.
@@ -482,5 +482,5 @@
     if ( event->isAccepted() )
         stopFlying();
-    
+
     if ( increment != 0.0 )
     {
@@ -552,5 +552,5 @@
 
 /*!
-   \return Wheel border width 
+   \return Wheel border width
    \sa setWheelBorderWidth()
 */
@@ -561,5 +561,5 @@
 
 /*!
-  \brief Set the border width 
+  \brief Set the border width
 
   The border defaults to 2.
@@ -575,5 +575,5 @@
 
 /*!
-   \return Border width 
+   \return Border width
    \sa setBorderWidth()
 */
@@ -683,5 +683,5 @@
 }
 
-/*! 
+/*!
   Determine the value corresponding to a specified point
 
@@ -724,5 +724,5 @@
 }
 
-/*! 
+/*!
    \brief Qt Paint Event
    \param event Paint event
@@ -737,5 +737,5 @@
     style()->drawPrimitive(QStyle::PE_Widget, &opt, &painter, this);
 
-    qDrawShadePanel( &painter, 
+    qDrawShadePanel( &painter,
         contentsRect(), palette(), true, d_data->borderWidth );
 
@@ -753,5 +753,5 @@
    \param rect Geometry for the wheel
 */
-void QwtWheel::drawWheelBackground( 
+void QwtWheel::drawWheelBackground(
     QPainter *painter, const QRectF &rect )
 {
@@ -761,5 +761,5 @@
 
     //  draw shaded background
-    QLinearGradient gradient( rect.topLeft(), 
+    QLinearGradient gradient( rect.topLeft(),
         ( d_data->orientation == Qt::Horizontal ) ? rect.topRight() : rect.bottomLeft() );
     gradient.setColorAt( 0.0, pal.color( QPalette::Button ) );
@@ -772,7 +772,7 @@
     // draw internal border
 
-    const QPen lightPen( palette().color( QPalette::Light ), 
+    const QPen lightPen( palette().color( QPalette::Light ),
         d_data->wheelBorderWidth, Qt::SolidLine, Qt::FlatCap );
-    const QPen darkPen( pal.color( QPalette::Dark ), 
+    const QPen darkPen( pal.color( QPalette::Dark ),
         d_data->wheelBorderWidth, Qt::SolidLine, Qt::FlatCap );
 
@@ -782,9 +782,9 @@
     {
         painter->setPen( lightPen );
-        painter->drawLine( QPointF( rect.left(), rect.top() + bw2 ), 
+        painter->drawLine( QPointF( rect.left(), rect.top() + bw2 ),
             QPointF( rect.right(), rect.top() + bw2 ) );
 
         painter->setPen( darkPen );
-        painter->drawLine( QPointF( rect.left(), rect.bottom() - bw2 ), 
+        painter->drawLine( QPointF( rect.left(), rect.bottom() - bw2 ),
             QPointF( rect.right(), rect.bottom() - bw2 ) );
     }
@@ -792,9 +792,9 @@
     {
         painter->setPen( lightPen );
-        painter->drawLine( QPointF( rect.left() + bw2, rect.top() ), 
+        painter->drawLine( QPointF( rect.left() + bw2, rect.top() ),
             QPointF( rect.left() + bw2, rect.bottom() ) );
 
         painter->setPen( darkPen );
-        painter->drawLine( QPointF( rect.right() - bw2, rect.top() ), 
+        painter->drawLine( QPointF( rect.right() - bw2, rect.top() ),
             QPointF( rect.right() - bw2, rect.bottom() ) );
     }
@@ -818,7 +818,7 @@
     }
 
-    const QPen lightPen( palette().color( QPalette::Light ), 
+    const QPen lightPen( palette().color( QPalette::Light ),
         0, Qt::SolidLine, Qt::FlatCap );
-    const QPen darkPen( palette().color( QPalette::Dark ), 
+    const QPen darkPen( palette().color( QPalette::Dark ),
         0, Qt::SolidLine, Qt::FlatCap );
 
@@ -857,5 +857,5 @@
 
             double tickPos;
-            if ( d_data->inverted ) 
+            if ( d_data->inverted )
                 tickPos = rect.left() + off;
             else
@@ -865,8 +865,8 @@
             {
                 painter->setPen( darkPen );
-                painter->drawLine( QPointF( tickPos - 1 , l1 ), 
+                painter->drawLine( QPointF( tickPos - 1 , l1 ),
                     QPointF( tickPos - 1,  l2 ) );
                 painter->setPen( lightPen );
-                painter->drawLine( QPointF( tickPos, l1 ), 
+                painter->drawLine( QPointF( tickPos, l1 ),
                     QPointF( tickPos, l2 ) );
             }
@@ -907,8 +907,8 @@
             {
                 painter->setPen( darkPen );
-                painter->drawLine( QPointF( l1, tickPos - 1 ), 
+                painter->drawLine( QPointF( l1, tickPos - 1 ),
                     QPointF( l2, tickPos - 1 ) );
                 painter->setPen( lightPen );
-                painter->drawLine( QPointF( l1, tickPos ), 
+                painter->drawLine( QPointF( l1, tickPos ),
                     QPointF( l2, tickPos ) );
             }
@@ -1014,10 +1014,10 @@
 
 /*!
-  \brief Set the page step count  
-    
+  \brief Set the page step count
+
   pageStepCount is a multiplicator for the single step size
   that typically corresponds to the user pressing PageUp or PageDown.
-    
-  A value of 0 disables page stepping. 
+
+  A value of 0 disables page stepping.
 
   The default value is 1.
@@ -1031,5 +1031,5 @@
 }
 
-/*! 
+/*!
   \return Page step count
   \sa setPageStepCount(), singleStep()
@@ -1150,8 +1150,8 @@
   The direction of an inverted horizontal wheel will be from right to left
   an inverted vertical wheel will increase from bottom to top.
-  
+
   \param on En/Disable inverted appearance
   \sa isInverted()
- 
+
  */
 void QwtWheel::setInverted( bool on )
@@ -1176,6 +1176,6 @@
   \brief En/Disable wrapping
 
-  If wrapping is true stepping up from maximum() value will take 
-  you to the minimum() value and vice versa. 
+  If wrapping is true stepping up from maximum() value will take
+  you to the minimum() value and vice versa.
 
   \param on En/Disable wrapping
@@ -1251,5 +1251,5 @@
 {
     const double range = d_data->maximum - d_data->minimum;
-    
+
     if ( d_data->wrapping && range >= 0.0 )
     {
@@ -1257,5 +1257,5 @@
         {
             value += ::ceil( ( d_data->minimum - value ) / range ) * range;
-        }       
+        }
         else if ( value > d_data->maximum )
         {
@@ -1293,5 +1293,5 @@
             }
         }
-    }       
+    }
 
     return value;
Index: trunk/BNC/qwt/qwt_wheel.h
===================================================================
--- trunk/BNC/qwt/qwt_wheel.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_wheel.h	(revision 9383)
@@ -78,8 +78,8 @@
     int borderWidth() const;
 
-    void setInverted( bool tf );
+    void setInverted( bool );
     bool isInverted() const;
 
-    void setWrapping( bool tf );
+    void setWrapping( bool );
     bool wrapping() const;
 
@@ -93,10 +93,10 @@
     bool stepAlignment() const;
 
-    void setRange( double vmin, double vmax );
+    void setRange( double min, double max );
 
-    void setMinimum( double min );
+    void setMinimum( double );
     double minimum() const;
 
-    void setMaximum( double max );
+    void setMaximum( double );
     double maximum() const;
 
@@ -104,5 +104,5 @@
     int updateInterval() const;
 
-    void setTracking( bool enable );
+    void setTracking( bool );
     bool isTracking() const;
 
@@ -121,5 +121,5 @@
 
       When tracking is enabled this signal will be emitted every
-      time the value changes. 
+      time the value changes.
 
       \param value new value
Index: trunk/BNC/qwt/qwt_widget_overlay.cpp
===================================================================
--- trunk/BNC/qwt/qwt_widget_overlay.cpp	(revision 9380)
+++ trunk/BNC/qwt/qwt_widget_overlay.cpp	(revision 9383)
@@ -12,4 +12,5 @@
 #include <qpainter.h>
 #include <qpaintengine.h>
+#include <qpainterpath.h>
 #include <qimage.h>
 #include <qevent.h>
@@ -23,6 +24,6 @@
 }
 
-static QRegion qwtAlphaMask( 
-    const QImage& image, const QVector<QRect> rects )
+static QRegion qwtAlphaMask(
+    const QImage& image, const QVector<QRect> &rects )
 {
     const int w = image.width();
@@ -42,22 +43,22 @@
         y2 = qMin( y2, h - 1 );
 
-        for ( int y = y1; y <= y2; ++y ) 
+        for ( int y = y1; y <= y2; ++y )
         {
             bool inRect = false;
             int rx0 = -1;
 
-            const uint *line = 
+            const uint *line =
                 reinterpret_cast<const uint *> ( image.scanLine( y ) ) + x1;
-            for ( int x = x1; x <= x2; x++ ) 
+            for ( int x = x1; x <= x2; x++ )
             {
                 const bool on = ( ( *line++ >> 24 ) != 0 );
-                if ( on != inRect ) 
+                if ( on != inRect )
                 {
-                    if ( inRect  ) 
+                    if ( inRect  )
                     {
                         rect.setCoords( rx0, y, x - 1, y );
                         region += rect;
-                    } 
-                    else 
+                    }
+                    else
                     {
                         rx0 = x;
@@ -65,8 +66,8 @@
 
                     inRect = on;
-                } 
+                }
             }
 
-            if ( inRect ) 
+            if ( inRect )
             {
                 rect.setCoords( rx0, y, x2, y );
@@ -212,5 +213,5 @@
         d_data->rgbaBuffer = ( uchar* )::calloc( width() * height(), 4 );
 
-        QImage image( d_data->rgbaBuffer, 
+        QImage image( d_data->rgbaBuffer,
             width(), height(), qwtMaskImageFormat() );
 
@@ -249,5 +250,5 @@
 void QwtWidgetOverlay::paintEvent( QPaintEvent* event )
 {
-    const QRegion clipRegion = event->region();
+    const QRegion &clipRegion = event->region();
 
     QPainter painter( this );
@@ -266,5 +267,5 @@
     if ( d_data->rgbaBuffer && useRgbaBuffer )
     {
-        const QImage image( d_data->rgbaBuffer, 
+        const QImage image( d_data->rgbaBuffer,
             width(), height(), qwtMaskImageFormat() );
 
Index: trunk/BNC/qwt/qwt_widget_overlay.h
===================================================================
--- trunk/BNC/qwt/qwt_widget_overlay.h	(revision 9380)
+++ trunk/BNC/qwt/qwt_widget_overlay.h	(revision 9383)
@@ -23,6 +23,6 @@
    heavy repaint operation of the widget below.
 
-   F.e. in combination with the plot canvas an overlay 
-   avoid replots as the content of the canvas can be restored from 
+   F.e. in combination with the plot canvas an overlay
+   avoid replots as the content of the canvas can be restored from
    its backing store.
 
@@ -33,5 +33,5 @@
    - maskHint()
 
-   Internally QwtPlotPicker uses overlays for displaying 
+   Internally QwtPlotPicker uses overlays for displaying
    the rubber band and the tracker text.
 
@@ -47,9 +47,9 @@
        the masked regions of the overlay only. Otherwise
        Qt triggers full repaints. On less powerful hardware
-       ( f.e embedded systems ) - or when using the raster paint 
+       ( f.e embedded systems ) - or when using the raster paint
        engine on a remote desktop - bit blitting is a noticeable
        operation, that needs to be avoided.
-       
-       If and how to mask depends on how expensive the calculation 
+
+       If and how to mask depends on how expensive the calculation
        of the mask is and how many pixels can be excluded by the mask.
 
@@ -66,5 +66,5 @@
            \brief Use maskHint() as mask
 
-           For many situations a fast approximation is good enough 
+           For many situations a fast approximation is good enough
            and it is not necessary to build a more detailed mask
            ( f.e the bounding rectangle of a text ).
@@ -78,5 +78,5 @@
            and the mask needs to be calculated by drawing the overlay
            and testing the result.
-          
+
            When a valid maskHint() is available
            only pixels inside this approximation are checked.
Index: trunk/BNC/qwt/src.pri
===================================================================
--- trunk/BNC/qwt/src.pri	(revision 9380)
+++ trunk/BNC/qwt/src.pri	(revision 9383)
@@ -181,5 +181,23 @@
         qwt_series_data.cpp \
         qwt_point_data.cpp \
-        qwt_scale_widget.cpp 
+        qwt_scale_widget.cpp
+
+    contains(QWT_CONFIG, QwtOpenGL) {
+
+        HEADERS += \
+            qwt_plot_glcanvas.h
+
+        SOURCES += \
+            qwt_plot_glcanvas.cpp
+    }
+
+    contains(QWT_CONFIG, QwtSvg) {
+
+        HEADERS += \
+            qwt_plot_svgitem.h
+
+        SOURCES += \
+            qwt_plot_svgitem.cpp
+    }
 }
 
@@ -192,8 +210,16 @@
 contains(QWT_CONFIG, QwtSvg) {
 
-    QT += svg
-
-    HEADERS += qwt_plot_svgitem.h
-    SOURCES += qwt_plot_svgitem.cpp 
+    greaterThan(QT_MAJOR_VERSION, 4) {
+
+        qtHaveModule(svg) {
+            QT += svg
+        }
+        else {
+            warning("QwtSvg is enabled in qwtconfig.pri, but Qt has not been built with svg support")
+        }
+    }
+    else {
+        QT += svg
+    }
 }
 else {
@@ -205,7 +231,4 @@
 
     QT += opengl
-
-    HEADERS += qwt_plot_glcanvas.h
-    SOURCES += qwt_plot_glcanvas.cpp
 }
 else {
Index: trunk/BNC/qwtpolar/qwt_polar_canvas.cpp
===================================================================
--- trunk/BNC/qwtpolar/qwt_polar_canvas.cpp	(revision 9380)
+++ trunk/BNC/qwtpolar/qwt_polar_canvas.cpp	(revision 9383)
@@ -215,6 +215,6 @@
                     QWidget *bgWidget = qwtBackgroundWidget( plot() );
 
-					QwtPainter::fillPixmap( bgWidget, bs,
-						mapTo( bgWidget, rect().topLeft() ) );
+                    QwtPainter::fillPixmap( bgWidget, bs,
+                        mapTo( bgWidget, rect().topLeft() ) );
 
                     p.begin( &bs );
