qtqmlqwidgetqqmlcomponentqt6

DropShadow QML widget in Qt6


I have a problem: I need to use DropShadow effect from QGraphicalEffects (which deleted in qt6) in my app.

How I can do it or replace it?


Solution

  • You can still import GraphicalEffects from the Qt5Compat module:

    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.