The QCommandLinkButton widget provides a Vista style command link button. 更多...
| 頭: | #include <QCommandLinkButton> |
| qmake: | QT += widgets |
| Since: | Qt 4.4 |
| 繼承: | QPushButton |
| QCommandLinkButton (QWidget * parent = Q_NULLPTR) | |
| QCommandLinkButton (const QString & text , QWidget * parent = Q_NULLPTR) | |
| QCommandLinkButton (const QString & text , const QString & 描述 , QWidget * parent = Q_NULLPTR) | |
| ~QCommandLinkButton () | |
| QString | description () const |
| void | setDescription (const QString & 描述 ) |
| virtual bool | event (QEvent * e ) |
| virtual int | heightForWidth (int width ) const |
| virtual QSize | minimumSizeHint () const |
| virtual void | paintEvent ( QPaintEvent * ) |
| virtual QSize | sizeHint () const |
The QCommandLinkButton widget provides a Vista style command link button.
The command link is a new control that was introduced by Windows Vista. It's intended use is similar to that of a radio button in that it is used to choose between a set of mutually exclusive options. Command link buttons should not be used by themselves but rather as an alternative to radio buttons in Wizards and dialogs and makes pressing the "next" button redundant. The appearance is generally similar to that of a flat pushbutton, but it allows for a descriptive text in addition to the normal button text. By default it will also carry an arrow icon, indicating that pressing the control will open another window or page.
另請參閱 QPushButton and QRadioButton .
此特性保持描述性標簽,以補充按鈕文本
設置此特性將在按鈕上設置描述性文本,以補充文本標簽。這通常會以比首要文本更小的字體顯示。
訪問函數:
| QString | 描述 () const |
| void | setDescription (const QString & 描述 ) |
此特性確定按鈕是被顯示為平闆,還是帶邊框。
默認情況下,此特性被設為 false。
訪問函數:
| bool | isFlat () const |
| void | setFlat ( bool ) |
另請參閱 QPushButton::flat .
構造命令鏈接采用無文本和 parent .
構造命令鏈接采用父級 parent 和文本 text .
構造命令鏈接采用 text , 描述 ,和 parent .
析構函數。
[virtual protected]
bool
QCommandLinkButton::
event
(
QEvent
*
e
)
重實現自 QObject::event ().
[virtual protected]
int
QCommandLinkButton::
heightForWidth
(
int
width
) const
重實現自 QWidget::heightForWidth ().
[virtual protected]
QSize
QCommandLinkButton::
minimumSizeHint
() const
重實現自 QWidget::minimumSizeHint ().
[virtual protected]
void
QCommandLinkButton::
paintEvent
(
QPaintEvent *
)
重實現自 QWidget::paintEvent ().
[virtual protected]
QSize
QCommandLinkButton::
sizeHint
() const
重實現自 QWidget::sizeHint ().