QWTPlotZoomer zoom in-out signal
-
wrote on 11 Dec 2023, 10:59 last edited by
Can I produce a signal when I zoom in and zoom out? I want to stop the live data flow when the first zoom is applied and to continue the data flow when the zoom is restored. Currently I do this with a button.
-
-
-
wrote on 13 Dec 2023, 05:23 last edited by
@jsulm
connect(zoomer, &QwtPlotZoomer::zoomed, [=](const QRectF& rect){
qDebug() << "Zoomed:" << rect;if (zoomer->zoomRectIndex() ==0 ) { qDebug() << "Max stack depth reached. Resetting to initial state."; // İlk haline geri dön zoomer->setZoomBase(); }
});
The chart auto-scales before zooming in and everything works normally. When setzoombase is used, it zooms out to the setAxisScale values I used when I created the chart. How can I solve this?
-
@jsulm
connect(zoomer, &QwtPlotZoomer::zoomed, [=](const QRectF& rect){
qDebug() << "Zoomed:" << rect;if (zoomer->zoomRectIndex() ==0 ) { qDebug() << "Max stack depth reached. Resetting to initial state."; // İlk haline geri dön zoomer->setZoomBase(); }
});
The chart auto-scales before zooming in and everything works normally. When setzoombase is used, it zooms out to the setAxisScale values I used when I created the chart. How can I solve this?
wrote on 13 Dec 2023, 07:01 last edited by@horizonQt I solve it. setAxisAutoScale worked for me
-
3/6