How can i draw a single point into a Qwt-Plot?
I tried:
Whats wrong?
QwtPlotCurve *cCos = new QwtPlotCurve("y = cos(x)");
cCos->setRenderHint(QwtPlotItem::RenderAntialiased);
cCos->setLegendAttribute(QwtPlotCurve::LegendShowLine , true);
cCos->setPen(QPen(Qt::green));
QVector<double> xWerte,yWerte;
xWerte[0]=1;
yWerte[0]=0;
QwtSeriesData<QPointF> point;
point=QwtPointArrayData(xWerte,yWerte);
cCos->setData(point);
cCos->attach(ui->qwtPlot);
}
Bookmarks