Qt 控件添加阴影效果

来源:互联网 发布:程序员团队名称大全 编辑:程序博客网 时间:2024/06/06 03:21


    QGraphicsDropShadowEffect *shadow_effect = new QGraphicsDropShadowEffect(this);    shadow_effect->setOffset(5, 5);    shadow_effect->setColor(QColor(43, 43, 43));    shadow_effect->setBlurRadius(8);        QLabel* pLabel = new QLabel(this);    pLabel->setGraphicsEffect(shadow_effect);

阴影效果如图:












原创粉丝点击