Menu

#41 additional LegendAttribute

closed
nobody
None
5
2012-04-05
2012-04-05
No

I am creating the plot in a first step with legend enabled, then in a second step I am attaching a curve.
If the curve has no title, only the line corresponding to the Plot line is showed in the legend, without any text.
I would like in such cases to be able to set the LegendAttribute to something like "LegendNoShowItem", which should be an additional attribute of Legend. Of course the corresponding functionality should also be implemented.

Discussion

  • Anonymous

    Anonymous - 2012-04-05

    Hello Alain,

    Probably you want to use QwtPlotItem::Legend attribute to hide your curve from legend.
    Try using curve->setItemAttribute(QwtPlotItem::Legend, false);
    where curve is pointer to QwtPlotCurve instance

    Regards,
    Sergey P.

     
  • Nobody/Anonymous

    Hello Sergey,

    I thank you for your hint, works fine!

    Regards
    Alain

     
  • Alain Weiler

    Alain Weiler - 2012-04-05
    • status: open --> closed
     

Anonymous
Anonymous

Add attachments
Cancel