#include <indicator.h>
Inherits QWidget.
|
| Indicator (const QString &text, QWidget *parent=NULL) |
|
void | setColor (const QColor &color) |
|
Definition at line 25 of file indicator.h.
◆ Indicator()
Indicator::Indicator |
( |
const QString & |
text, |
|
|
QWidget * |
parent = NULL |
|
) |
| |
Definition at line 38 of file indicator.cpp.
43 setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
◆ paintEvent()
void Indicator::paintEvent |
( |
QPaintEvent * |
event | ) |
|
|
protected |
Definition at line 22 of file indicator.cpp.
References m_color, and m_text.
24 QPainter painter(
this);
26 painter.setPen(Qt::black);
29 painter.drawRect(0, 0, 18, 15);
30 painter.drawText(0, 0, 19, 16, Qt::AlignCenter | Qt::AlignHCenter,
m_text);
◆ setColor()
void Indicator::setColor |
( |
const QColor & |
color | ) |
|
◆ sizeHint()
QSize Indicator::sizeHint |
( |
| ) |
const |
|
protected |
◆ m_color
QColor Indicator::m_color |
|
private |
◆ m_text
QString Indicator::m_text |
|
private |
The documentation for this class was generated from the following files: