问题
I have a QCustomPlot
widget in my ui as follows:
ui->plot_widget
also I have another QCustomPlot
object in my cpp file as follows:
QCustomPlot *plot=new QCustomPlot();
I want to add plot
data into ui->plot_widget
data.
If I use ui->plot_widget=plot
the widget parent of ui->plot_widget
will be destroyed and my ui does not update ui->plot_widget
.
How can I add plot
data into ui->plot_widget
data?
来源:https://stackoverflow.com/questions/48345789/qt-qcustomplot-parent