title: Customizing QwtPlot's scale and grid lines
body: <p>I'm confused with using <strong>QwtPlot</strong> class to draw a customized coordinate system.
  My goal is to draw a coordinate system with customized scale, and draw grid line on these customized scales. Here are the values of the scales:</p>
  
  <p><strong>x-axis and y-axis scale:</strong></p>
  
  <pre><code>x1=-0.642455
  x2=0
  x3=0.642455
  y1=-0.642455
  y2=0
  y3=0.642455
  </code></pre>
  
  <p>I read the user's guide of <a href="http://qwt.sourceforge.net/class_qwt_plot.html" rel="nofollow"><strong>QwtPlot</strong> class</a> and <a href="http://qwt.sourceforge.net/class_qwt_plot_grid.html" rel="nofollow"><strong>QwtPlotGrid</strong> class</a>. I found a function in <strong>QwtPlotGrid</strong> class called <strong>setxDiv</strong> and seemed that it could help, So I wrote the following code:</p>
  
  <pre><code>QList&lt;double&gt; doubleListmin;//min scale
  QList&lt;double&gt; doubleListmed;//medium scale
  QList&lt;double&gt; doubleListmaj;//major scale
  doubleListmin.append(0.1);
  doubleListmed.append(0.3);
  doubleListmaj.append(0.642455);
  QList&lt;double&gt; doubleList[3];
  doubleList[0] = doubleListmin;
  doubleList[1] = doubleListmed;
  doubleList[2] = doubleListmaj;
  QwtScaleDiv *xDiv = new QwtScaleDiv(-0.642455, 0.642455, doubleList);
  //lowerbound is -0.642455, upperbound is 0.642455, doubleList customizes the scale
  
  QwtPlotGrid *grid = new QwtPlotGrid();
  grid-&gt;setXDiv(*xDiv);
  //grid-&gt;updateScaleDiv(*xDiv, *xDiv);
  grid-&gt;attach(this);
  </code></pre>
  
  <p>But it turned out to have no influence on the new QwtPlotGrid, it doesn't change its scale system.</p>
  
  <p>I think there's another way: draw a several lines in the QwtPlot. But I don't know how to do it.</p>
  
  <p>Somebody help me please!!!
  Thank you in advance~</p>