Inner shadow on QML Rectangle
问题 How do I implement a Rectangle in QML with an inner shadow? See example in link below: Create inner shadow in UIView UPDATE: Here's a simplified version of what I'm trying to do (which does not show any shadow): import QtQuick 2.0 import QtGraphicalEffects 1.0 Item { width: 400 height: 400 Item { anchors.fill: parent Rectangle { id: myRectangle anchors.centerIn: parent width: 200 height: 200 color: "grey" } } InnerShadow { anchors.fill: myRectangle cached: true visible: true horizontalOffset: