DtkWidget
DTK Widget module
|
DSwitchLineExpand 类提供了一种通过开关按钮来展开/合上显示内容的控件. 更多...
Public 成员函数 | |
DSwitchLineExpand (QWidget *parent=0) | |
DSwitchLineExpand 类的构造函数. | |
void | setTitle (const QString &title) |
DSwitchLineExpand::setTitle 用于设置控件的标题。 title 为所要设置的标题。 | |
void | setExpand (bool value) |
DSwitchLineExpand::setExpand 用于控制控件是否展开。 value 为所要设置的展开状态,true 为展开,false 为合上。 | |
DBaseLine * | header () |
DSwitchLineExpand::header 用来获取标题栏控件。 | |
Public 成员函数 继承自 Dtk::Widget::DDrawer | |
DDrawer (QWidget *parent=nullptr) | |
Get DDRAWER :: DDRAWER example parent As the parent control part of the example | |
void | setHeader (QWidget *header) |
Set the title control The title control will always be displayed in the layout header Title control | |
void | setContent (QWidget *content, Qt::Alignment alignment=Qt::AlignHCenter) |
Set the content control Content control is hidden by default, call ddrawer :: setexpand settings for its visibility content Content controlent control alignment The alignment method of content control in the layout method of content control in the layout method of content control in the layout method of content control in the layout method of content control in the layout method of content control in the layout method of content control in the layout | |
QWidget * | getContent () const |
Get the content control object | |
void | setHeaderHeight (int height) |
Set the height of the title control. | |
bool | expand () const |
Visible to obtain the current content control. | |
void | setAnimationDuration (int duration) |
Set the time for the visibility of the content control when the animation time is changed. | |
void | setAnimationEasingCurve (QEasingCurve curve) |
setTheVisibilityOfTheContentControlWhenTheAnimationStyleIsChangedOfTheContentControlWhenTheAnimationStyleIsChanged curve Specify animation style | |
void | setSeparatorVisible (bool arg) |
Set the segmentation line between the title control and the content control. | |
void | setExpandedSeparatorVisible (bool arg) |
Set the segmentation line under the content control. | |
Public 成员函数 继承自 Dtk::Widget::DFrame | |
DFrame (QWidget *parent=nullptr) | |
用于其他需要边框的控件基类 | |
void | setFrameRounded (bool on) |
设置边框圆角是否开启 | |
void | setBackgroundRole (DGUI_NAMESPACE::DPalette::ColorType type) |
设置边框背景画刷的种类 | |
额外继承的成员函数 | |
信号 继承自 Dtk::Widget::DDrawer | |
void | expandChange (bool e) |
Content control visibility signal e For TRUE, the content control becomes visible, but vice versa | |
void | sizeChanged (QSize s) |
Protected 成员函数 继承自 Dtk::Widget::DDrawer | |
DDrawer (DDrawerPrivate &dd, QWidget *parent=nullptr) | |
void | resizeEvent (QResizeEvent *e) Q_DECL_OVERRIDE |
Protected 成员函数 继承自 Dtk::Widget::DFrame | |
DFrame (DFramePrivate &dd, QWidget *parent=nullptr) | |
void | paintEvent (QPaintEvent *event) override |
DSwitchLineExpand 类提供了一种通过开关按钮来展开/合上显示内容的控件.
\inmodule dtkwidget
控件由标题栏和内容两部分组成,标题栏左侧显示控件标题,右侧显示一个开关控件, 用户通过点击右侧的开关控件,来控制标题栏下面的内容部分展开还是合上。
|
explicit |
DSwitchLineExpand 类的构造函数.
parent 指定了控件的父控件。
DBaseLine * Dtk::Widget::DSwitchLineExpand::header | ( | ) |
DSwitchLineExpand::header 用来获取标题栏控件。
|
virtual |
DSwitchLineExpand::setExpand 用于控制控件是否展开。 value 为所要设置的展开状态,true 为展开,false 为合上。
重载 Dtk::Widget::DDrawer .