QwtPolarMagnifier provides zooming, by magnifying in steps. More...
#include <qwt_polar_magnifier.h>
Classes | |
class | PrivateData |
Public Slots | |
virtual void | rescale (double factor) QWT_OVERRIDE |
void | unzoom () |
Unzoom the plot widget. More... | |
Public Member Functions | |
QwtPolarCanvas * | canvas () |
const QwtPolarCanvas * | canvas () const |
void | getUnzoomKey (int &key, int &modifiers) const |
QwtPolarPlot * | plot () |
const QwtPolarPlot * | plot () const |
QwtPolarMagnifier (QwtPolarCanvas *) | |
void | setUnzoomKey (int key, int modifiers) |
virtual | ~QwtPolarMagnifier () |
Destructor. More... | |
Public Member Functions inherited from QwtMagnifier | |
virtual bool | eventFilter (QObject *, QEvent *) QWT_OVERRIDE |
Event filter. More... | |
void | getMouseButton (Qt::MouseButton &, Qt::KeyboardModifiers &) const |
void | getZoomInKey (int &key, Qt::KeyboardModifiers &) const |
Retrieve the settings of the zoom in key. More... | |
void | getZoomOutKey (int &key, Qt::KeyboardModifiers &) const |
Retrieve the settings of the zoom out key. More... | |
bool | isEnabled () const |
double | keyFactor () const |
double | mouseFactor () const |
QWidget * | parentWidget () |
const QWidget * | parentWidget () const |
QwtMagnifier (QWidget *) | |
void | setEnabled (bool) |
En/disable the magnifier. More... | |
void | setKeyFactor (double) |
Change the key factor. More... | |
void | setMouseButton (Qt::MouseButton, Qt::KeyboardModifiers=Qt::NoModifier) |
void | setMouseFactor (double) |
Change the mouse factor. More... | |
void | setWheelFactor (double) |
Change the wheel factor. More... | |
void | setWheelModifiers (Qt::KeyboardModifiers) |
void | setZoomInKey (int key, Qt::KeyboardModifiers=Qt::NoModifier) |
void | setZoomOutKey (int key, Qt::KeyboardModifiers=Qt::NoModifier) |
double | wheelFactor () const |
Qt::KeyboardModifiers | wheelModifiers () const |
virtual | ~QwtMagnifier () |
Destructor. More... | |
Protected Member Functions | |
virtual void | widgetKeyPressEvent (QKeyEvent *) QWT_OVERRIDE |
Protected Member Functions inherited from QwtMagnifier | |
virtual void | rescale (double factor)=0 |
virtual void | widgetKeyReleaseEvent (QKeyEvent *) |
virtual void | widgetMouseMoveEvent (QMouseEvent *) |
virtual void | widgetMousePressEvent (QMouseEvent *) |
virtual void | widgetMouseReleaseEvent (QMouseEvent *) |
virtual void | widgetWheelEvent (QWheelEvent *) |
Private Attributes | |
PrivateData * | m_data |
QwtPolarMagnifier provides zooming, by magnifying in steps.
Using QwtPlotMagnifier a plot can be zoomed in/out in steps using keys, the mouse wheel or moving a mouse button in vertical direction.
Together with QwtPolarPanner it is possible to implement an individual navigation of the plot canvas.
Definition at line 30 of file qwt_polar_magnifier.h.
|
explicit |
Constructor
canvas | Plot canvas to be magnified |
Definition at line 34 of file qwt_polar_magnifier.cpp.
|
virtual |
Destructor.
Definition at line 41 of file qwt_polar_magnifier.cpp.
const QwtPolarCanvas * QwtPolarMagnifier::canvas | ( | ) |
Definition at line 74 of file qwt_polar_magnifier.cpp.
const QwtPolarCanvas* QwtPolarMagnifier::canvas | ( | ) | const |
void QwtPolarMagnifier::getUnzoomKey | ( | int & | key, |
int & | modifiers | ||
) | const |
key | Key code |
modifiers | Modifiers |
Definition at line 67 of file qwt_polar_magnifier.cpp.
const QwtPolarPlot * QwtPolarMagnifier::plot | ( | ) |
Definition at line 86 of file qwt_polar_magnifier.cpp.
const QwtPolarPlot* QwtPolarMagnifier::plot | ( | ) | const |
|
virtualslot |
Zoom in/out the zoomed area
factor | A value < 1.0 zooms in, a value > 1.0 zooms out. |
Definition at line 129 of file qwt_polar_magnifier.cpp.
void QwtPolarMagnifier::setUnzoomKey | ( | int | key, |
int | modifiers | ||
) |
Assign key and modifiers, that are used for unzooming The default combination is Qt::Key_Home + Qt::NoModifier.
key | Key code |
modifiers | Modifiers |
Definition at line 54 of file qwt_polar_magnifier.cpp.
|
slot |
Unzoom the plot widget.
Definition at line 157 of file qwt_polar_magnifier.cpp.
|
protectedvirtual |
Handle a key press event for the observed widget.
event | Key event |
Reimplemented from QwtMagnifier.
Definition at line 110 of file qwt_polar_magnifier.cpp.
|
private |
Definition at line 55 of file qwt_polar_magnifier.h.