blob: 104e7ba1e9729f3b861b2bf060df530c0cb444bd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
import Test 1.0
MyTypeObject {
property variant copy: rect
property string tostring: rect.toString()
// compare to string
property bool equalsString: (rect == tostring)
// compare rects to various value types
property bool equalsColor: (rect == Qt.rgba(0.2, 0.88, 0.6, 0.34)) // false
property bool equalsVector3d: (rect == Qt.vector3d(1, 2, 3)) // false
property bool equalsSize: (rect == Qt.size(1912, 1913)) // false
property bool equalsPoint: (rect == Qt.point(10, 4)) // false
property bool equalsRect: (rect == Qt.rect(2, 3, 109, 102)) // true
property bool equalsSelf: (rect == rect) // true
property bool equalsOther: (rect == Qt.rect(6, 9, 99, 92)) // false
property bool rectEqualsRectf: (rect == rectfrect) // true
}
|