myCurve1
->setItemAttribute
( QwtPlotItem::AutoScale,
false );
myCurve2
->setItemAttribute
( QwtPlotItem::AutoScale,
true );
plot
->setAxisAutoScale
(QwtPlot::xBottom);
plot
->setAxisAutoScale
(QwtPlot::yLeft);
plot->replot();
myCurve1->setItemAttribute( QwtPlotItem::AutoScale, false );
myCurve2->setItemAttribute( QwtPlotItem::AutoScale, true );
plot->setAxisAutoScale(QwtPlot::xBottom);
plot->setAxisAutoScale(QwtPlot::yLeft);
plot->replot();
To copy to clipboard, switch view to plain text mode
or
QRectF br
= myCurve2
->boundingRect
();
plot
->setAxisAutoScale
(QwtPlot::xBottom, br.
left(), br.
right() );
plot
->setAxisAutoScale
(QwtPlot::yLeft, br.
top(), br.
bottom() );
QRectF br = myCurve2->boundingRect();
plot->setAxisAutoScale(QwtPlot::xBottom, br.left(), br.right() );
plot->setAxisAutoScale(QwtPlot::yLeft, br.top(), br.bottom() );
To copy to clipboard, switch view to plain text mode
Uwe
Bookmarks