kwave
18.07.70
|
Public Member Functions | |
PositionWidget (QWidget *parent) | |
virtual | ~PositionWidget () Q_DECL_OVERRIDE |
virtual void | setText (const QString &text, Qt::Alignment alignment) |
Protected Member Functions | |
virtual void | paintEvent (QPaintEvent *) Q_DECL_OVERRIDE |
virtual void | updateMask () |
Private Attributes | |
QLabel * | m_label |
Qt::Alignment | m_alignment |
int | m_radius |
int | m_arrow_length |
Qt::Alignment | m_last_alignment |
QSize | m_last_size |
QPolygon | m_polygon |
Definition at line 355 of file SignalView.h.
|
explicit |
Constructor
Definition at line 686 of file SignalView.cpp.
References m_label.
|
virtual |
|
protectedvirtual |
paint event: draws the text and the arrow
Definition at line 815 of file SignalView.cpp.
References background, and m_polygon.
|
virtual |
set a new label text and alignment
text | the text of the label, can be multiline and rtf/html |
alignment | the alignment of the label and the widget, can be Qt::AlignLeft, Qt::AlignRight or Qt::AlignHCenter |
Definition at line 717 of file SignalView.cpp.
References m_alignment, m_arrow_length, m_label, m_radius, and updateMask().
Referenced by Kwave::SignalView::showPosition().
|
protectedvirtual |
re-creates the mask and the polygon when size/alignment has changed
Definition at line 752 of file SignalView.cpp.
References m_alignment, m_arrow_length, m_last_alignment, m_last_size, and m_polygon.
Referenced by setText().
|
private |
alignment of the label / text
Definition at line 389 of file SignalView.h.
Referenced by setText(), and updateMask().
|
private |
the length of the arrows [pixel]
Definition at line 395 of file SignalView.h.
Referenced by setText(), and updateMask().
|
private |
the label that contains the text
Definition at line 386 of file SignalView.h.
Referenced by PositionWidget(), setText(), and ~PositionWidget().
|
private |
for detecting changes: previous width
Definition at line 398 of file SignalView.h.
Referenced by updateMask().
|
private |
for detecting changes: previous size
Definition at line 401 of file SignalView.h.
Referenced by updateMask().
|
private |
polygon used as widget outline
Definition at line 404 of file SignalView.h.
Referenced by paintEvent(), and updateMask().
|
private |
the radius of the corners [pixel]
Definition at line 392 of file SignalView.h.
Referenced by setText().