kdk::KTag(3) Library Functions Manual kdk::KTag(3)

kdk::KTag - 提供四种样式的标签,响应系统主题色变化

#include <ktag.h>

Inherits QPushButton.


KTag (QWidget *parent=nullptr)
void setClosable (bool)
设置关闭按钮是否可见 bool closable ()
返回关闭按钮是否可见 void setText (const QString &)
设置文本 QString text ()
获取当前文本 void setTagStyle (TagStyle)
设置tag样式 TagStyle tagStyle ()
获取当前tag样式 void setBackgroundColor (QColor color)
设置背景颜色 void setTranslucent (bool flag)
设置半透明 bool translucent ()
获取是否启用半透明


void paintEvent (QPaintEvent *event)
QSize sizeHint () const override

提供四种样式的标签,响应系统主题色变化

Since

1.0.0

返回关闭按钮是否可见

Returns

bool

设置背景颜色

Parameters

flag

Since

2.4.1.0

设置半透明

Parameters

flag

Since

2.4.1.0

TagStyle kdk::KTag::tagStyle ()

获取当前tag样式

Returns

TagStyle

获取当前文本

Returns

QString

获取是否启用半透明

Returns

bool

Since

2.4.1.0

Generated automatically by Doxygen for LIBKYSDK-APPLICATIONS from the source code.

Version version:3.0 LIBKYSDK-APPLICATIONS