最近要将之前做的QtCharts的柱状图改成用QCustomPlot
要实现之前的功能,结果发现QCustomPlot里面只有这些信号:
而在我们使用的柱子类QCPBars里面却只有三个信号:
直接 做connect也只有这些
粗暴一点直接 connect(bars ,SIGNAL(plottableClick()),this, SLOT());
会提示:没有这个信号...
所以回到这个信号selectionChanged :
This signal is emitted when the selection state of this plottable has changed, either by user interact