Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. 3rd Party Software
  4. QWTPlotZoomer zoom in-out signal
Forum Updated to NodeBB v4.3 + New Features

QWTPlotZoomer zoom in-out signal

Scheduled Pinned Locked Moved Solved 3rd Party Software
6 Posts 3 Posters 744 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    horizonQt
    wrote on last edited by
    #1

    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.

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      You could use the zoomed signal to know when things have changed.

      Hope it helps.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      H 1 Reply Last reply
      0
      • SGaistS SGaist

        Hi,

        You could use the zoomed signal to know when things have changed.

        Hope it helps.

        H Offline
        H Offline
        horizonQt
        wrote on last edited by
        #3

        @SGaist no. ı couldnt. can you help me ? pls

        jsulmJ 1 Reply Last reply
        0
        • H horizonQt

          @SGaist no. ı couldnt. can you help me ? pls

          jsulmJ Offline
          jsulmJ Offline
          jsulm
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @horizonQt said in QWTPlotZoomer zoom in-out signal:

          ı couldnt

          Why not? What is the problem?

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          H 1 Reply Last reply
          0
          • jsulmJ jsulm

            @horizonQt said in QWTPlotZoomer zoom in-out signal:

            ı couldnt

            Why not? What is the problem?

            H Offline
            H Offline
            horizonQt
            wrote on last edited by
            #5

            @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?

            H 1 Reply Last reply
            0
            • H horizonQt

              @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?

              H Offline
              H Offline
              horizonQt
              wrote on last edited by
              #6

              @horizonQt I solve it. setAxisAutoScale worked for me

              1 Reply Last reply
              0
              • H horizonQt has marked this topic as solved on

              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved