Ignore:
Timestamp:
Nov 3, 2026, 10:53:35 AM (3 weeks ago)
Author:
stuerze
Message:

deprecated functions exchanged libs updated

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/qwt/qwt_plot_intervalcurve.h

    r9383 r11158  
    1 /* -*- mode: C++ ; c-file-style: "stroustrup" -*- *****************************
     1/******************************************************************************
    22 * Qwt Widget Library
    33 * Copyright (C) 1997   Josef Wilgen
    … …  
    1313#include "qwt_global.h"
    1414#include "qwt_plot_seriesitem.h"
    15 #include "qwt_series_data.h"
    1615
    1716class QwtIntervalSymbol;
     17template< typename T > class QwtSeriesData;
    1818
    1919/*!
    20   \brief QwtPlotIntervalCurve represents a series of samples, where each value
     20   \brief QwtPlotIntervalCurve represents a series of samples, where each value
    2121         is associated with an interval ( \f$[y1,y2] = f(x)\f$ ).
    2222
    23   The representation depends on the style() and an optional symbol()
    24   that is displayed for each interval. QwtPlotIntervalCurve might be used
    25   to display error bars or the area between 2 curves.
    26 */
    27 class QWT_EXPORT QwtPlotIntervalCurve:
    28     public QwtPlotSeriesItem, public QwtSeriesStore<QwtIntervalSample>
     23   The representation depends on the style() and an optional symbol()
     24   that is displayed for each interval. QwtPlotIntervalCurve might be used
     25   to display error bars or the area between 2 curves.
     26 */
     27class QWT_EXPORT QwtPlotIntervalCurve
     28    : public QwtPlotSeriesItem
     29    , public QwtSeriesStore< QwtIntervalSample >
    2930{
    30 public:
     31  public:
    3132    /*!
    3233        \brief Curve styles.
    … …  
    3435
    3536        \sa setStyle(), style()
    36     */
     37     */
    3738    enum CurveStyle
    3839    {
    … …  
    6061        Attributes to modify the drawing algorithm.
    6162        \sa setPaintAttribute(), testPaintAttribute()
    62     */
     63     */
    6364    enum PaintAttribute
    6465    {
    6566        /*!
    66           Clip polygons before painting them. In situations, where points
    67           are far outside the visible area (f.e when zooming deep) this
    68           might be a substantial improvement for the painting performance.
     67           Clip polygons before painting them. In situations, where points
     68           are far outside the visible area (f.e when zooming deep) this
     69           might be a substantial improvement for the painting performance.
    6970         */
    7071        ClipPolygons = 0x01,
    7172
    7273        //! Check if a symbol is on the plot canvas before painting it.
    73         ClipSymbol   = 0x02
     74        ClipSymbol   = 0x02,
     75
     76        /*!
     77           Fill the tube with horizontal or vertical lines and unite
     78           overlapping border lines. This attribute is useful for large
     79           data sets, where consecutive samples are often mapped to the same
     80           coordinate.
     81
     82           Beside other minor visual differences the filling is always
     83           monochrome - using brush().color().
     84
     85           This algorithm is very fast and effective and can be used inside
     86           a replot cycle. In the worst case the number of lines to be rendered
     87           will be 5 times the ( width/height - depending on the orientation() )
     88           of the plot canvas.
     89
     90           \note Has only an effect, when drawing to a paint device
     91                 in integer coordinates ( f.e. all widgets on screen ).
     92
     93           \sa QwtPlotCurve::FilterPointsAggressive
     94         */
     95        TubeAsLines = 0x10
    7496    };
    7597
    76     //! Paint attributes
    77     typedef QFlags<PaintAttribute> PaintAttributes;
     98    Q_DECLARE_FLAGS( PaintAttributes, PaintAttribute )
    7899
    79     explicit QwtPlotIntervalCurve( const QString &title = QString() );
    80     explicit QwtPlotIntervalCurve( const QwtText &title );
     100    explicit QwtPlotIntervalCurve( const QString& title = QString() );
     101    explicit QwtPlotIntervalCurve( const QwtText& title );
    81102
    82103    virtual ~QwtPlotIntervalCurve();
    83104
    84     virtual int rtti() const;
     105    virtual int rtti() const QWT_OVERRIDE;
    85106
    86107    void setPaintAttribute( PaintAttribute, bool on = true );
    87108    bool testPaintAttribute( PaintAttribute ) const;
    88109
    89     void setSamples( const QVector<QwtIntervalSample> & );
    90     void setSamples( QwtSeriesData<QwtIntervalSample> * );
     110    void setSamples( const QVector< QwtIntervalSample >& );
     111    void setSamples( QwtSeriesData< QwtIntervalSample >* );
    91112
    92     void setPen( const QColor &, qreal width = 0.0, Qt::PenStyle = Qt::SolidLine );
    93     void setPen( const QPen & );
    94     const QPen &pen() const;
     113    void setPen( const QColor&,
     114        qreal width = 0.0, Qt::PenStyle = Qt::SolidLine );
    95115
    96     void setBrush( const QBrush & );
    97     const QBrush &brush() const;
     116    void setPen( const QPen& );
     117    const QPen& pen() const;
     118
     119    void setBrush( const QBrush& );
     120    const QBrush& brush() const;
    98121
    99122    void setStyle( CurveStyle style );
    100123    CurveStyle style() const;
    101124
    102     void setSymbol( const QwtIntervalSymbol * );
    103     const QwtIntervalSymbol *symbol() const;
     125    void setSymbol( const QwtIntervalSymbol* );
     126    const QwtIntervalSymbol* symbol() const;
    104127
    105     virtual void drawSeries( QPainter *,
    106         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
    107         const QRectF &canvasRect, int from, int to ) const;
     128    virtual void drawSeries( QPainter*,
     129        const QwtScaleMap& xMap, const QwtScaleMap& yMap,
     130        const QRectF& canvasRect, int from, int to ) const QWT_OVERRIDE;
    108131
    109     virtual QRectF boundingRect() const;
     132    virtual QRectF boundingRect() const QWT_OVERRIDE;
    110133
    111     virtual QwtGraphic legendIcon( int index, const QSizeF & ) const;
     134    virtual QwtGraphic legendIcon(
     135        int index, const QSizeF& ) const QWT_OVERRIDE;
    112136
    113 protected:
     137  protected:
    114138
    115139    void init();
    116140
    117     virtual void drawTube( QPainter *,
    118         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
    119         const QRectF &canvasRect, int from, int to ) const;
     141    virtual void drawTube( QPainter*,
     142        const QwtScaleMap& xMap, const QwtScaleMap& yMap,
     143        const QRectF& canvasRect, int from, int to ) const;
    120144
    121     virtual void drawSymbols( QPainter *, const QwtIntervalSymbol &,
    122         const QwtScaleMap &xMap, const QwtScaleMap &yMap,
    123         const QRectF &canvasRect, int from, int to ) const;
     145    virtual void drawSymbols( QPainter*, const QwtIntervalSymbol&,
     146        const QwtScaleMap& xMap, const QwtScaleMap& yMap,
     147        const QRectF& canvasRect, int from, int to ) const;
    124148
    125 private:
     149  private:
    126150    class PrivateData;
    127     PrivateData *d_data;
     151    PrivateData* m_data;
    128152};
    129153
Note: See TracChangeset for help on using the changeset viewer.