Hallo everybody,

please have a look:


I subclassed "QAreaSeries" to "myQAreaSeries". No I want to connect a selfdesigned slot to some signal emitted by a chart on mainWindow. Somehow Qt tells me:

Qt Code:
  1. QObject::connect: No such slot QtCharts::QAreaSeries::setTextPosition(QRectF)
To copy to clipboard, switch view to plain text mode 


And here's some wrap up:

Qt Code:
  1. QT_CHARTS_USE_NAMESPACE
  2.  
  3. namespace Ui {
  4. class myQAreaSeries;
  5. }
  6.  
  7. class myQAreaSeries : public QAreaSeries
  8. {
  9.  
  10. public:
  11. // some member
  12.  
  13. private slots:
  14.  
  15. // here it is:
  16. void setTextPosition(QRectF rect);
  17.  
  18.  
  19. private:
  20.  
  21. // some member
  22. };
To copy to clipboard, switch view to plain text mode 

The implementation:

Qt Code:
  1. #include "myqareaseries.h"
  2.  
  3. myQAreaSeries::myQAreaSeries(qreal in, qreal out , int track, QChartView *Chartview){
  4.  
  5.  
  6. // here it even offers me the setTextPosition-SLOT, which it later doesn't find
  7. connect(chartview->chart(), SIGNAL(plotAreaChanged(QRectF)), this, SLOT(setTextPosition(QRectF)));
  8. }
  9.  
  10.  
  11.  
  12. void myQAreaSeries::setTextPosition(QRectF rect){
  13.  
  14. // some action
  15. }
To copy to clipboard, switch view to plain text mode 

Most likely I missed something at school.
Thanks in advance for your replies.

Lars