The legend is a container widget around a scrollview, that contains another containter widget (QwtLegend::contentsWidget()), with the legend item widgets inside.
If you want to find the legend item widget, that corresponds to a specific plot item ( f.e for assigning the color of the curve to its palette ) you can use QwtLegend::find ( QwtPlotItem is derived from QwtLegendItemManager ). Overloading QwtPlotItem::updateLegend() is the place to do this.
If you want to have your own type of widget (instead of QwtLegendItem) to be displayed on the legend, implement YourCurve::legendItem() and YourCurve::updateLegend().
Uwe
PS: Qwt is open source - why not looking into the code to identify the internal widget trees.
Bookmarks