[Interest] QML innershadow
Federico Buti
bacarozzo at gmail.com
Wed Dec 17 14:05:14 CET 2014
Hi all,
last day we come up with a strage behaviour, or at least, what it seems a
strange behaviour to us. Following the documentation for InnerShadow QML
type it is stated that:
"Note: It is not supported to let the effect include itself, for instance
by setting source to the effect's parent."
However, the only way to obtain an homogenous internal shadow such as this
one <http://i.stack.imgur.com/XIbGq.png> (i.e. with offsets set to zero)
seems to break the documentation rule:
import QtQuick 2.0
import QtGraphicalEffects 1.0
Item {
id: root
width: 300
height: 300
Rectangle {
id: myRectangle
anchors.centerIn: parent
width: 100
height: 100
color: "grey"
}
InnerShadow {
anchors.fill: root
cached: true
horizontalOffset: 0
verticalOffset: 0
radius: 16
samples: 32
color: "#b0000000"
smooth: true
source: root // <--- source include the effect!
}
}
Is it intended behaviour or a bug? Is there another way to achieve an
overall shadow like the one in picture?
Thanks in advance,
F.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20141217/74620a29/attachment.html>
More information about the Interest
mailing list