Center of a Shape with SvgPath
Unsolved
QML and Qt Quick
-
Hi all,
I am looking at the recent Shape features in QML.
What i would like to do is to build a shape from an svg path, which was very easy by usingShape { id: demo1 ShapePath { PathSvg { path: "L 150 50 L 100 150 z" } } }
Now the question is:
Q1. How can I get the height, width of this shape from within QML?
They return zero.Q2. I check if a point falls within this Shape from QML?
When calling the following from an appropriate handler,
demo1.contains(Qt.point(100,100))
it returns false. But the point is in the triangular region therefore it should have returned true.
Thanks in advance for any upcoming answers..