- qtgui
- qtdbus
- qtwidgets
- qtcore
- dtkcore
- qsettingbackend_zh
- dobject_zh
- abstractappender_zh
- abstractstringappender_zh
- dfilewatcher_zh
- outputdebugappender_zh
- dsettingsbackend_zh
- drecentmanager_zh
- ddesktopentry_zh
- consoleappender_zh
- gsettingsbackend_zh
- dsettingsgroup_zh
- dlogmanager_zh
- fileappender_zh
- dsettings_zh
- dfilesystemwatcher_zh
- dfilewatchermanager_zh
- dbasefilewatcher_zh
- dtkgui
- dtkwidget
- dviewitemaction_zh
- dstandarditem_zh
- dfiledialog_zh
- dclipeffectwidget_zh
- danchors_zh
- dgraphicsclipeffect_zh
- dstyle_zh
- dcoloredprogressbar_zh
- dbuttonboxbutton_zh
- dlabel_zh
- dtiplabel_zh
- darrowlinedrawer_zh
- daboutdialog_zh
- dsettingswidgetfactory_zh
- dsearchcombobox_zh
- dcrumbedit_zh
- dcommandlinkbutton_zh
- dsettingsdialog_zh
- dwindowoptionbutton_zh
- dspinner_zh
- dsimplelistview_zh
- dwaterprogress_zh
- dmainwindow_zh
- dhidpihelper_zh
- dslider_zh
- dpasswordedit_zh
- danchorinfo_zh
- dmpriscontrol_zh
- darrowbutton_zh
- dbackgroundgroup_zh
- dcircleprogress_zh
- dwarningbutton_zh
- dwindowclosebutton_zh
- dvideowidget_zh
- dfilechooseredit_zh
- dblureffectwidget_zh
- darrowrectangle_zh
- dsearchedit_zh
- dfloatingmessage_zh
- dswitchlineexpand_zh
- dtabbar_zh
- dlineedit_zh
- danchorsbase_zh
- dstylediconengine_zh
- dwindowmaxbutton_zh
- dpageindicator_zh
- dsuggestbutton_zh
- dapplicationsettings_zh
- dtooltip_zh
- dwindowminbutton_zh
- ddrawer_zh
- dtitlebar_zh
- dsimplelistitem_zh
- dpicturesequenceview_zh
dgraphicsclipeffect_zh
Class::DGraphicsClipEffect
暂无该属性
Detailed Description
用于裁剪窗口的绘制内容 支持使用 QPainterPath 设置一个区域,位于区域外的窗口内容将被裁剪,可以通过设置 UnknownCommand margins 控制有效的裁剪区域。如下图所示: UnknownCommand
┏━━━━━━━━━━━━━━┯━━━━━━━━━━━━━━┓ ┃ │ ┃ ┃ │ ┃ ┃ A m ┃ ┃ │ ┃ ┃ │ ┃ ┃ ┏┅┅┅┅┅┅┷┅┅┅┅┅┅┓ ┃ ┃ ┋B ╭───────╮ ┋ ┃ ┃ ┋ │ │ ┋ ┃ ┃── m ──┋ │ C │ ┋── m ──┃ ┃ ┋ │ │ ┋ ┃ ┃ ┋ ╰───────╯ ┋ ┃ ┃ ┗┅┅┅┅┅┅┯┅┅┅┅┅┅┛ ┃ ┃ │ ┃ ┃ │ ┃ ┃ m ┃ ┃ │ ┃ ┃ │ ┃ ┗━━━━━━━━━━━━━━┷━━━━━━━━━━━━━━┛UnknownCommand A为被作用的控件区域,B为有效的被裁剪区域,C 为 UnknownCommand clipPath 区域,m为 UnknownCommand margins ,则被裁剪掉的区域为: B - C,裁掉的部分将显示 下层控件内容,如果下层没有其它控件,将显示主窗口背景。
Warning: 以这种方式实现对 QWidget 的剪切在性能上会有较大的影响,一般情况下,我们推荐使用 DClipEffectWidget
See also DClipEffectWidget QWidget::setGraphicsEffect
DGraphicsClipEffect::Q_PROPERTY
int Q_PROPERTY(int )
DGraphicsClipEffect::margins
int margins() const
DGraphicsClipEffect::clipPath
int clipPath() const See also setClipPath()
DGraphicsClipEffect::setClipPath
void setClipPath(const int &clipPath) clipPath
DGraphicsClipEffect::clipPathChanged
void clipPathChanged(int clipPath)
DGraphicsClipEffect::draw
void draw(int *painter) override