There are different ways to implement this - one is to use a QGridLayout for plots and legends. Instead of QwtPlot::insertLegend() you would have to do something like this:

Qt Code:
  1. QwtLegend *legend = new QwtLegend;
  2. legend->setMaxColumns( 1 );
  3.  
  4. connect( plot, SIGNAL( legendDataChanged( const QVariant &, const QList<QwtLegendData> & ) ),
  5. legend, SLOT( updateLegend( const QVariant &, const QList<QwtLegendData> & ) ) );
To copy to clipboard, switch view to plain text mode 
Uwe