title: How to delete QLabel and QwtSlider in a std::vector
body: <p>I have a <code>std::vector</code> filled up with <code>QLabel</code> and <code>QwtSlider</code> pointers and I would like to delete the pointers but not the vector.  </p>
  
  <p>Here my code:</p>
  
  <pre><code>QLabel *sliderSimuVarLabel;
  std::vector&lt;QLabel*&gt;    labelsSimuVarList;
  std::vector&lt;QwtSlider*&gt; slidersSimuVarList;
  
  int num = 3;
  for (int i=0; i&lt;numSimuVars; ++i){
  
     sliderSimuVarLabel = new QLabel("Hello", Widg);  
     sliderSimuVarLabel-&gt;setFont(panelFont2);
  
     labelsSimuVarList.push_back(new QLabelWidg));                                      
     labelsSimuVarList[i]-&gt;setFont(panelFont2);
  
     slidersSimuVarList.push_back(new QwtSlider(Qt::Horizontal,Widg));
  
     layoutSimuPanel-&gt;addWidget(sliderSimuVarLabel,i+7,0);
     layoutSimuPanel-&gt;addWidget(slidersSimuVarList[i],i+7,1,1,5);
     layoutSimuPanel-&gt;addWidget(labelsSimuVarList[i], i+7, 7);
  }
  </code></pre>
  
  <p>I don’t know with which method delete the pointers: <code>clear()</code>? <code>deleteLater()</code>? others?</p>