简体   繁体   English

Qt6 中的 DropShadow QML 小部件

[英]DropShadow QML widget in Qt6

I have a problem: I need to use DropShadow effect from QGraphicalEffects (which deleted in qt6) in my app.我有一个问题:我需要在我的应用程序中使用 QGraphicalEffects(在 qt6 中删除)中的DropShadow 效果

How I can do it or replace it?我该怎么做或更换它?

You can still import GraphicalEffects from the Qt5Compat module:您仍然可以从Qt5Compat模块导入GraphicalEffects

import Qt5Compat.GraphicalEffects

However you first have to install the Qt5Compat module from the Qt installer, which long term might not be what you want in new code as it is going to go away eventually.但是,您首先必须从 Qt 安装程序安装Qt5Compat模块,从长远来看,这可能不是您在新代码中想要的,因为它最终会消失。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM