Home · Modules · Classes · Namespaces · Functions

QxtLabel Class Reference
[QxtGui module]

The QxtLabel widget is a label which is able to show elided and rotated plain text. More...

    #include <QxtLabel>

Inherits QFrame.

Properties

Public Functions

Public Slots

Signals

Additional Inherited Members


Detailed Description

The QxtLabel widget is a label which is able to show elided and rotated plain text.

QxtLabel is a label which is able to show elided and rotated plain text. In addition, QxtLabel provides a signal for clicking.

"QxtLabel in action."

Usage:

    QxtLabel* label = new QxtLabel(tr("Hello, World!"), this);
    label->setAlignment(Qt::AlignLeft | Qt::AlignVCenter);
    label->setElideMode(Qt::ElideRight);
    label->setRotation(Qxt::CounterClockwise);
    connect(label, SIGNAL(clicked()), this, SLOT(labelClicked()));

See also QLabel.


Property Documentation

alignment : Qt::Alignment

This property holds the alignment of the text.

The text is aligned according to this property. The default value is Qt::AlignCenter.

Access functions:

See also text and Qt::Alignment.

elideMode : Qt::TextElideMode

This property holds the elide mode of the text.

The text is elided according to this property. The default value is Qt::ElideMiddle.

Access functions:

See also text and Qt::TextElideMode.

rotation : Qxt::Rotation

This property holds the rotation of the label.

The label is rotated according to this property. The default value is Qxt::NoRotation.

Access functions:

See also Qxt::Rotation.

text : QString

This property holds the text of the label.

Access functions:


Member Function Documentation

QxtLabel::QxtLabel ( QWidget * parent = 0, Qt::WindowFlags flags = 0 )

Constructs a new QxtLabel with parent and flags.

QxtLabel::QxtLabel ( const QString & text, QWidget * parent = 0, Qt::WindowFlags flags = 0 )

Constructs a new QxtLabel with text, parent and flags.

QxtLabel::~QxtLabel ()   [virtual]

Destructs the label.

void QxtLabel::clicked ()   [signal]

This signal is emitted whenever the label has been clicked.

Note: A combination of mouse button press and release in shorter time than QApplication::doubleClickInterval is considered as a click.

See also QApplication::doubleClickInterval.

void QxtLabel::textChanged ( const QString & text )   [signal]

This signal is emitted whenever the text has changed.


Copyright © 2007-2010 Qxt Foundation
Qxt 0.6.1