DtkWidget
DTK Widget module
载入中...
搜索中...
未找到
dwindowmaxbutton.h
1// SPDX-FileCopyrightText: 2015 - 2022 UnionTech Software Technology Co., Ltd.
2//
3// SPDX-License-Identifier: LGPL-3.0-or-later
4
5#ifndef DWINDOWMAXBUTTON_H
6#define DWINDOWMAXBUTTON_H
7
8#include <DIconButton>
9
10DWIDGET_BEGIN_NAMESPACE
11
12class DWindowMaxButtonPrivate;
13
14class LIBDTKWIDGETSHARED_EXPORT DWindowMaxButton : public DIconButton
15{
16 Q_OBJECT
17public:
18 DWindowMaxButton(QWidget * parent = 0);
19
20 Q_PROPERTY(bool isMaximized READ isMaximized WRITE setMaximized NOTIFY maximizedChanged)
21
22 bool isMaximized() const;
23 QSize sizeHint() const override;
24
25public Q_SLOTS:
26 void setMaximized(bool isMaximized);
27
28Q_SIGNALS:
29 void maximizedChanged(bool isMaximized);
30
31protected:
32 void initStyleOption(DStyleOptionButton *option) const override;
33
34private:
35 D_DECLARE_PRIVATE(DWindowMaxButton)
36};
37
38DWIDGET_END_NAMESPACE
39
40#endif // DWINDOWMAXBUTTON_H
按钮的图标
Definition diconbutton.h:24
Dtk 样式统一的按钮样式配置.
Definition dstyleoption.h:58
The DWindowMaxButton class is used as the unified window maximize button.
Definition dwindowmaxbutton.h:15
void maximizedChanged(bool isMaximized)
isMaximizedChanged 信号在 isMaximized 属性发生变化时触发.