The QwtLegend widget is a tabular arrangement of legend items. Legend items might be any type of widget, but in general they will be a QwtLegendItem.
Definition at line 36 of file qwt_legend.h.
Public Types | |
enum | LegendDisplayPolicy { NoIdentifier = 0, FixedIdentifier = 1, AutoIdentifier = 2 } |
enum | LegendItemMode { ReadOnlyItem, ClickableItem, CheckableItem } |
Public Member Functions | |
QwtLegend (QWidget *parent=NULL) | |
virtual | ~QwtLegend () |
void | setDisplayPolicy (LegendDisplayPolicy policy, int mode) |
LegendDisplayPolicy | displayPolicy () const |
void | setItemMode (LegendItemMode) |
LegendItemMode | itemMode () const |
int | identifierMode () const |
QWidget * | contentsWidget () |
const QWidget * | contentsWidget () const |
void | insert (const QwtPlotItem *, QWidget *) |
void | remove (const QwtPlotItem *) |
QWidget * | find (const QwtPlotItem *) const |
QwtPlotItem * | find (const QWidget *) const |
virtual QList< QWidget * > | legendItems () const |
void | clear () |
bool | isEmpty () const |
uint | itemCount () const |
virtual bool | eventFilter (QObject *, QEvent *) |
virtual QSize | sizeHint () const |
virtual int | heightForWidth (int w) const |
QScrollBar * | horizontalScrollBar () const |
QScrollBar * | verticalScrollBar () const |
Protected Member Functions | |
virtual void | resizeEvent (QResizeEvent *) |
virtual void | layoutContents () |
|
Display policy.
Default is AutoIdentifier. Definition at line 62 of file qwt_legend.h. |
|
Interaction mode for the legend items.
Definition at line 70 of file qwt_legend.h. |
|
Definition at line 257 of file qwt_legend.cpp. |
|
Destructor.
Definition at line 282 of file qwt_legend.cpp. |
|
Remove all items.
Definition at line 489 of file qwt_legend.cpp. |
|
The contents widget is the only child of the viewport() and the parent widget of all legend items. Definition at line 374 of file qwt_legend.cpp. |
|
The contents widget is the only child of the viewport() and the parent widget of all legend items. Definition at line 354 of file qwt_legend.cpp. Referenced by insert(), and QwtPlot::printLegend(). |
|
Definition at line 323 of file qwt_legend.cpp. Referenced by QwtPlotCurve::updateLegend(). |
|
Find the widget that represents a plot item
Definition at line 470 of file qwt_legend.cpp. |
|
Find the widget that represents a plot item
Definition at line 459 of file qwt_legend.cpp. Referenced by QwtPlotItem::updateLegend(), and QwtPlotCurve::updateLegend(). |
|
Definition at line 517 of file qwt_legend.cpp. |
|
Definition at line 345 of file qwt_legend.cpp. Referenced by QwtPlotCurve::updateLegend(). |
|
Insert a new item for a plot item
Definition at line 385 of file qwt_legend.cpp. References contentsWidget(). Referenced by QwtPlotItem::updateLegend(). |
|
Return true, if there are no legend items.
Definition at line 616 of file qwt_legend.cpp. Referenced by QwtPlotLayout::activate(). |
|
Return the number of legend items.
Definition at line 622 of file qwt_legend.cpp. |
|
Adjust contents widget and item layout to the size of the viewport(). Definition at line 542 of file qwt_legend.cpp. Referenced by eventFilter(). |
|
Find the corresponding item for a plotItem and remove it from the item list.
Definition at line 481 of file qwt_legend.cpp. |
|
Resize event
Definition at line 653 of file qwt_legend.cpp. |
|
Set the legend display policy to:
Definition at line 295 of file qwt_legend.cpp. References QwtPlotItem::updateLegend(). |
|
Return a size hint.
Definition at line 505 of file qwt_legend.cpp. |