table of contents
- unstable 3.0.1.1-1+b1
| kdk::KWidget(3) | Library Functions Manual | kdk::KWidget(3) |
NAME¶
kdk::KWidget - 继承自QWidget,支持响应主题背景切换,图标主题切换,标题颜色响应窗口激活状态,内容区域分为side区和base区
SYNOPSIS¶
#include <kwidget.h>
Inherits QWidget, and ThemeController.
Public Member Functions¶
KWidget (QWidget *parent=nullptr)
void setIcon (const QIcon &icon)
设置窗体图标 void setIcon (const
QString &iconName)
设置窗体图标 void setWidgetName
(const QString &widgetName)
设置窗体名称 QWidget * sideBar ()
获取左边栏widget,通过setlayout添加自定义内容
QWidget * baseBar ()
获取主内容区widget,通过setlayout添加自定义内容
KWindowButtonBar * windowButtonBar ()
获取窗口三联组合控件,以控制是否显示最大化、最小化按钮和下拉菜单按钮;也可增加自定义按钮
KIconBar * iconBar ()
获取窗口标题、图标组合控件,以控制相关样式
void setLayoutType (LayoutType type)
设置布局结构类型 void
setWindowFlags (Qt::WindowFlags type)
设置窗口标志 void setWindowFlag
(Qt::WindowType flag, bool on=true)
设置窗口标志 void
setSidebarFollowMode (bool flag)
设置sidebar是否遵循系统更改宽度
bool sidebarFollowMode ()
返回sidebar是否遵循系统更改宽度
Protected Member Functions¶
bool eventFilter (QObject *target, QEvent *event) override
virtual void changeIconStyle ()
virtual void changeTheme ()
Detailed Description¶
继承自QWidget,支持响应主题背景切换,图标主题切换,标题颜色响应窗口激活状态,内容区域分为side区和base区
Since
Examples
testDialog/widget.h, testPushbutton/widget.h,
testWidget/testwidget.h, testbadge/widget.h,
testballontip/widget.h, testinputdialog/widget.cpp,
testinputdialog/widget.h, testnavigationbar/widget.h,
testpasswordedit/widget.h, testprogressbar/widget.h,
testprogressdialog/widget.cpp, testprogressdialog/widget.h,
testsearchlinedit/widget.h, testsecuritylevelbar/widget.h,
testslider/widget.h, testtabbar/widget.h, and
testtoolbutton/widget.h.
Author¶
Generated automatically by Doxygen for LIBKYSDK-APPLICATIONS from the source code.
| Version version:3.0 | LIBKYSDK-APPLICATIONS |