qwt_legend_label.h
Go to the documentation of this file.
1 /******************************************************************************
2  * Qwt Widget Library
3  * Copyright (C) 1997 Josef Wilgen
4  * Copyright (C) 2002 Uwe Rathmann
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the Qwt License, Version 1.0
8  *****************************************************************************/
9 
10 #ifndef QWT_LEGEND_LABEL_H
11 #define QWT_LEGEND_LABEL_H
12 
13 #include "qwt_global.h"
14 #include "qwt_text_label.h"
15 #include "qwt_legend_data.h"
16 
17 class QwtText;
18 
23 {
24  Q_OBJECT
25  public:
26  explicit QwtLegendLabel( QWidget* parent = 0 );
27  virtual ~QwtLegendLabel();
28 
29  void setData( const QwtLegendData& );
30  const QwtLegendData& data() const;
31 
32  void setItemMode( QwtLegendData::Mode );
33  QwtLegendData::Mode itemMode() const;
34 
35  void setSpacing( int spacing );
36  int spacing() const;
37 
38  virtual void setText( const QwtText& ) QWT_OVERRIDE;
39 
40  void setIcon( const QPixmap& );
41  QPixmap icon() const;
42 
43  virtual QSize sizeHint() const QWT_OVERRIDE;
44 
45  bool isChecked() const;
46 
47  public Q_SLOTS:
48  void setChecked( bool on );
49 
50  Q_SIGNALS:
52  void clicked();
53 
55  void pressed();
56 
58  void released();
59 
61  void checked( bool );
62 
63  protected:
64  void setDown( bool );
65  bool isDown() const;
66 
67  virtual void paintEvent( QPaintEvent* ) QWT_OVERRIDE;
68  virtual void mousePressEvent( QMouseEvent* ) QWT_OVERRIDE;
69  virtual void mouseReleaseEvent( QMouseEvent* ) QWT_OVERRIDE;
70  virtual void keyPressEvent( QKeyEvent* ) QWT_OVERRIDE;
71  virtual void keyReleaseEvent( QKeyEvent* ) QWT_OVERRIDE;
72 
73  private:
74  class PrivateData;
76 };
77 
78 #endif
QwtLegendData
Attributes of an entry on a legend.
Definition: qwt_legend_data.h:36
QwtLegendData::Mode
Mode
Mode defining how a legend entry interacts.
Definition: qwt_legend_data.h:40
qwt_text_label.h
qwt_global.h
qwt_legend_data.h
QwtLegendLabel::m_data
PrivateData * m_data
Definition: qwt_legend_label.h:74
QwtText
A class representing a text.
Definition: qwt_text.h:51
QwtTextLabel
A Widget which displays a QwtText.
Definition: qwt_text_label.h:26
QwtLegendLabel
A widget representing something on a QwtLegend.
Definition: qwt_legend_label.h:22
QwtLegendLabel::PrivateData
Definition: qwt_legend_label.cpp:37
QwtTextLabel::paintEvent
virtual void paintEvent(QPaintEvent *) QWT_OVERRIDE
Definition: qwt_text_label.cpp:236
QwtTextLabel::sizeHint
virtual QSize sizeHint() const QWT_OVERRIDE
Return a size hint.
Definition: qwt_text_label.cpp:172
QWT_OVERRIDE
#define QWT_OVERRIDE
Definition: qwt_global.h:53
QWT_EXPORT
#define QWT_EXPORT
Definition: qwt_global.h:38
mqtt_test.data
dictionary data
Definition: mqtt_test.py:22
QwtTextLabel::setText
void setText(const QString &, QwtText::TextFormat textFormat=QwtText::AutoText)
Definition: qwt_text_label.cpp:96


plotjuggler
Author(s): Davide Faconti
autogenerated on Sun Aug 11 2024 02:24:24