Changeset 11158 in ntrip for trunk/BNC/qwt/qwt_panner.h


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

deprecated functions exchanged libs updated

File:
1 edited

Legend:

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

    r9383 r11158  
    1 /* -*- mode: C++ ; c-file-style: "stroustrup" -*- *****************************
     1/******************************************************************************
    22 * Qwt Widget Library
    33 * Copyright (C) 1997   Josef Wilgen
    … …  
    99
    1010#ifndef QWT_PANNER_H
    11 #define QWT_PANNER_H 1
     11#define QWT_PANNER_H
    1212
    1313#include "qwt_global.h"
    1414#include <qwidget.h>
    15 #include <qpixmap.h>
    1615
    1716class QCursor;
     17class QPixmap;
    1818
    1919/*!
    20   \brief QwtPanner provides panning of a widget
     20   \brief QwtPanner provides panning of a widget
    2121
    22   QwtPanner grabs the contents of a widget, that can be dragged
    23   in all directions. The offset between the start and the end position
    24   is emitted by the panned signal.
     22   QwtPanner grabs the contents of a widget, that can be dragged
     23   in all directions. The offset between the start and the end position
     24   is emitted by the panned signal.
    2525
    26   QwtPanner grabs the content of the widget into a pixmap and moves
    27   the pixmap around, without initiating any repaint events for the widget.
    28   Areas, that are not part of content are not painted  while panning.
    29   This makes panning fast enough for widgets, where
    30   repaints are too slow for mouse movements.
     26   QwtPanner grabs the content of the widget into a pixmap and moves
     27   the pixmap around, without initiating any repaint events for the widget.
     28   Areas, that are not part of content are not painted  while panning.
     29   This makes panning fast enough for widgets, where
     30   repaints are too slow for mouse movements.
    3131
    32   For widgets, where repaints are very fast it might be better to
    33   implement panning manually by mapping mouse events into paint events.
    34 */
    35 class QWT_EXPORT QwtPanner: public QWidget
     32   For widgets, where repaints are very fast it might be better to
     33   implement panning manually by mapping mouse events into paint events.
     34 */
     35class QWT_EXPORT QwtPanner : public QWidget
    3636{
    3737    Q_OBJECT
    3838
    39 public:
    40     QwtPanner( QWidget* parent );
     39  public:
     40    explicit QwtPanner( QWidget* parent );
    4141    virtual ~QwtPanner();
    4242
    … …  
    4646    void setMouseButton( Qt::MouseButton,
    4747        Qt::KeyboardModifiers = Qt::NoModifier );
    48     void getMouseButton( Qt::MouseButton &button,
    49         Qt::KeyboardModifiers & ) const;
     48    void getMouseButton( Qt::MouseButton& button,
     49        Qt::KeyboardModifiers& ) const;
    5050
    5151    void setAbortKey( int key, Qt::KeyboardModifiers = Qt::NoModifier );
    52     void getAbortKey( int &key, Qt::KeyboardModifiers & ) const;
     52    void getAbortKey( int& key, Qt::KeyboardModifiers& ) const;
    5353
    54     void setCursor( const QCursor & );
     54    void setCursor( const QCursor& );
    5555    const QCursor cursor() const;
    5656
    … …  
    6060    bool isOrientationEnabled( Qt::Orientation ) const;
    6161
    62     virtual bool eventFilter( QObject *, QEvent * );
     62    virtual bool eventFilter( QObject*, QEvent* ) QWT_OVERRIDE;
    6363
    64 Q_SIGNALS:
     64  Q_SIGNALS:
    6565    /*!
    66       Signal emitted, when panning is done
     66       Signal emitted, when panning is done
    6767
    68       \param dx Offset in horizontal direction
    69       \param dy Offset in vertical direction
    70     */
     68       \param dx Offset in horizontal direction
     69       \param dy Offset in vertical direction
     70     */
    7171    void panned( int dx, int dy );
    7272
    7373    /*!
    74       Signal emitted, while the widget moved, but panning
    75       is not finished.
     74       Signal emitted, while the widget moved, but panning
     75       is not finished.
    7676
    77       \param dx Offset in horizontal direction
    78       \param dy Offset in vertical direction
    79     */
     77       \param dx Offset in horizontal direction
     78       \param dy Offset in vertical direction
     79     */
    8080    void moved( int dx, int dy );
    8181
    82 protected:
    83     virtual void widgetMousePressEvent( QMouseEvent * );
    84     virtual void widgetMouseReleaseEvent( QMouseEvent * );
    85     virtual void widgetMouseMoveEvent( QMouseEvent * );
    86     virtual void widgetKeyPressEvent( QKeyEvent * );
    87     virtual void widgetKeyReleaseEvent( QKeyEvent * );
     82  protected:
     83    virtual void widgetMousePressEvent( QMouseEvent* );
     84    virtual void widgetMouseReleaseEvent( QMouseEvent* );
     85    virtual void widgetMouseMoveEvent( QMouseEvent* );
     86    virtual void widgetKeyPressEvent( QKeyEvent* );
     87    virtual void widgetKeyReleaseEvent( QKeyEvent* );
    8888
    89     virtual void paintEvent( QPaintEvent * );
     89    virtual void paintEvent( QPaintEvent* ) QWT_OVERRIDE;
    9090
    9191    virtual QBitmap contentsMask() const;
    9292    virtual QPixmap grab() const;
    9393
    94 private:
     94  private:
    9595#ifndef QT_NO_CURSOR
    9696    void showCursor( bool );
    … …  
    9898
    9999    class PrivateData;
    100     PrivateData *d_data;
     100    PrivateData* m_data;
    101101};
    102102
Note: See TracChangeset for help on using the changeset viewer.