DtkWidget 5.6.0.2
DTK Widget module
|
DButtonBox 类似于 QButtonGroup 的类. 更多...
信号 | |
void | buttonClicked (QAbstractButton *) |
void | buttonPressed (QAbstractButton *) |
void | buttonReleased (QAbstractButton *) |
void | buttonToggled (QAbstractButton *, bool) |
Public 成员函数 | |
DButtonBox (QWidget *parent=nullptr) | |
DButtonBox::DButtonBox 构造函数. 更多... | |
Qt::Orientation | orientation () const |
DButtonBox::orientation 返回布局方向. 更多... | |
void | setOrientation (Qt::Orientation orientation) |
DButtonBox::setOrientation 设置布局方向. 更多... | |
void | setButtonList (const QList< DButtonBoxButton * > &list, bool checkable) |
DButtonBox::setButtonList将按钮进添加到组中. 更多... | |
QList< QAbstractButton * > | buttonList () const |
DButtonBox::buttonList. 更多... | |
QAbstractButton * | checkedButton () const |
DButtonBox::checkedButton. 更多... | |
QAbstractButton * | button (int id) const |
DButtonBox::button 更多... | |
void | setId (QAbstractButton *button, int id) |
设置按钮 id . 更多... | |
int | id (QAbstractButton *button) const |
返回按钮 id . 更多... | |
int | checkedId () const |
返回已选中按钮 id . 更多... | |
友元 | |
class | DButtonBoxButton |
DButtonBox 类似于 QButtonGroup 的类.
\inmodule dtkwidget
DButtonBox 提供了对按钮的布局方向
|
explicit |
DButtonBox::DButtonBox 构造函数.
parent 参数被发送到 QWidget 构造函数
QAbstractButton * Dtk::Widget::DButtonBox::button | ( | int | id | ) | const |
QList< QAbstractButton * > Dtk::Widget::DButtonBox::buttonList | ( | ) | const |
QAbstractButton * Dtk::Widget::DButtonBox::checkedButton | ( | ) | const |
int Dtk::Widget::DButtonBox::checkedId | ( | ) | const |
返回已选中按钮 id .
int Dtk::Widget::DButtonBox::id | ( | QAbstractButton * | button | ) | const |
返回按钮 id .
button 对应的按钮.
Qt::Orientation Dtk::Widget::DButtonBox::orientation | ( | ) | const |
DButtonBox::orientation 返回布局方向.
void Dtk::Widget::DButtonBox::setButtonList | ( | const QList< DButtonBoxButton * > & | list, |
bool | checkable | ||
) |
DButtonBox::setButtonList将按钮进添加到组中.
list 存储按钮的 QList 列表 checkable 按钮是否可选中
void Dtk::Widget::DButtonBox::setId | ( | QAbstractButton * | button, |
int | id | ||
) |
设置按钮 id .
button 用于设置 id 的按钮。
void Dtk::Widget::DButtonBox::setOrientation | ( | Qt::Orientation | orientation | ) |