This is the code with the first picture.选区_011.png


OscilloScaleDraw *scaleDraw = new OscilloScaleDraw();
scaleDraw->setLabelAlignment(Qt::AlignCenter);
setAxisScaleDraw(QwtPlot::yLeft, scaleDraw);

QwtScaleDiv ydiv;
m_verticalScaleEngine = new OscilloScaleEngine();
m_verticalScaleEngine->setTransformation(new QwtNullTransform());
setAxisScaleEngine(QwtPlot::yLeft, m_verticalScaleEngine);

ydiv = m_verticalScaleEngine->divideTVDScale(
-1000,
1000,
10

);

QList< double > list ;
list << -1000 << 0 << 1000;

ydiv.setTicks(QwtScaleDiv::MajorTick, list);
setAxisScaleDiv(QwtPlot::yLeft, ydiv);
while the second one , I changed list << -1000 << 0 << 1000 to list << -900 << 0 << 1000. 选区_012.png

What I need is to set the number to -1000 , and there are no space between the two plots, like the second picture . What should I do ?
It seems the plot calculates the rectangle according to the list, I've looked into the Qwt_plot_layout, but still have no idea how to make it happen.