9 #include "qwt_polar_magnifier.h" 
   10 #include "qwt_polar_plot.h" 
   11 #include "qwt_polar_canvas.h" 
   12 #include "qwt_scale_div.h" 
   13 #include "qwt_point_polar.h" 
   17 class QwtPolarMagnifier::PrivateData
 
   21         : unzoomKey( Qt::Key_Home )
 
   22         , unzoomKeyModifiers( Qt::NoModifier )
 
   27     int unzoomKeyModifiers;
 
   37     m_data = 
new PrivateData();
 
   56     m_data->unzoomKey = key;
 
   57     m_data->unzoomKeyModifiers = modifiers;
 
   69     key = m_data->unzoomKey;
 
   70     modifiers = m_data->unzoomKeyModifiers;
 
   76     return qobject_cast< QwtPolarCanvas* >( parent() );
 
   82     return qobject_cast< QwtPolarCanvas* >( parent() );
 
  112     const int key = 
event->key();
 
  113     const int state = 
event->modifiers();
 
  115     if ( key == m_data->unzoomKey &&
 
  116         state == m_data->unzoomKeyModifiers )
 
  131     factor = qAbs( factor );
 
  132     if ( factor == 1.0 || factor == 0.0 )
 
  140     double newZoomFactor = plt->
zoomFactor() * factor;
 
  142     if ( newZoomFactor >= 1.0 )
 
  150     plt->
zoom( zoomPos, newZoomFactor );
 
  171 #include "moc_qwt_polar_magnifier.cpp" 
QwtMagnifier provides zooming, by magnifying in steps.
virtual void widgetKeyPressEvent(QKeyEvent *)
A point in polar coordinates.
Canvas of a QwtPolarPlot.
virtual void widgetKeyPressEvent(QKeyEvent *) override
void getUnzoomKey(int &key, int &modifiers) const
void unzoom()
Unzoom the plot widget.
void setUnzoomKey(int key, int modifiers)
virtual void rescale(double factor) override
QwtPolarCanvas * canvas()
QwtPolarMagnifier(QwtPolarCanvas *)
virtual ~QwtPolarMagnifier()
Destructor.
A plotting widget, displaying a polar coordinate system.
QwtPointPolar zoomPos() const
virtual void replot()
Redraw the plot.
void zoom(const QwtPointPolar &, double factor)
Translate and in/decrease the zoom factor.
double zoomFactor() const
void setAutoReplot(bool tf=true)
Set or reset the autoReplot option.