Important: Please read the Qt Code of Conduct -

QChart's mouse events vs QChartView's mouse events

  • Hi,

    I implemented a custom chart by deriving from QChart. I am currently working on the mouse events of this class. I added the code so that I can add and remove a point on the graph by double clicking, and it worked fine.

    Afterward, I wanted to work on the zooming of the chart. I read a document on the subject: In this example, they implemented a custom QChartView and used its mouse events. I was wondering why use the QChartView's mouse events when it is possible to do it with QChart's mouse events. When should I choose QChartView's mouse events rather than QChart's mouse events?

    Thanks in advance.

Log in to reply