Ignore:
Timestamp:
May 10, 2017, 3:20:54 PM (7 years ago)
Author:
stoecker
Message:

update qwt and qwtpolar, many QT5 fixes (unfinished)

File:
1 edited

Legend:

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

    r4271 r8127  
    1919
    2020  Sometimes important layout/rendering geometries are not
    21   available or changable from the public Qt class interface.
     21  available or changeable from the public Qt class interface.
    2222  ( f.e hidden in the style implementation ).
    2323
    2424  QwtNullPaintDevice can be used to manipulate or filter out
    25   these informations by analyzing the stream of paint primitives.
     25  this information by analyzing the stream of paint primitives.
    2626
    2727  F.e. QwtNullPaintDevice is used by QwtPlotCanvas to identify
     
    3232{
    3333public:
    34     QwtNullPaintDevice( QPaintEngine::PaintEngineFeatures );
    35     QwtNullPaintDevice( const QSize &size,
    36         QPaintEngine::PaintEngineFeatures );
     34    /*!
     35      \brief Render mode
    3736
     37      \sa setMode(), mode()
     38     */
     39    enum Mode
     40    {
     41        /*!
     42           All vector graphic primitives are painted by
     43           the corresponding draw methods
     44         */
     45        NormalMode,
     46
     47        /*!
     48           Vector graphic primitives ( beside polygons ) are mapped to a QPainterPath
     49           and are painted by drawPath. In PathMode mode
     50           only a few draw methods are called:
     51
     52           - drawPath()
     53           - drawPixmap()
     54           - drawImage()
     55           - drawPolygon()
     56         */
     57        PolygonPathMode,
     58
     59        /*!
     60           Vector graphic primitives are mapped to a QPainterPath
     61           and are painted by drawPath. In PathMode mode
     62           only a few draw methods are called:
     63
     64           - drawPath()
     65           - drawPixmap()
     66           - drawImage()
     67         */
     68        PathMode
     69    };
     70
     71    QwtNullPaintDevice();
    3872    virtual ~QwtNullPaintDevice();
    3973
    40     void setSize( const QSize &);
    41     QSize size() const;
     74    void setMode( Mode );
     75    Mode mode() const;
    4276
    4377    virtual QPaintEngine *paintEngine() const;
     78
    4479    virtual int metric( PaintDeviceMetric metric ) const;
    4580
     
    77112    virtual void updateState( const QPaintEngineState &state );
    78113
     114protected:
     115    //! \return Size needed to implement metric()
     116    virtual QSize sizeMetrics() const = 0;
     117
    79118private:
    80     void init( QPaintEngine::PaintEngineFeatures );
    81 
    82119    class PaintEngine;
    83120    PaintEngine *d_engine;
Note: See TracChangeset for help on using the changeset viewer.