Rename QDeclarative symbols to QQuick and QQml
[profile/ivi/qtdeclarative.git] / tests / auto / quick / qquicklistview / data / listview-enforcerange-nohighlight.qml
1 import QtQuick 2.0
2
3 Rectangle {
4     width: 240
5     height: 320
6
7     Component {
8         id: myDelegate
9         Rectangle {
10             id: wrapper
11             objectName: "wrapper"
12             height: 20
13             width: 240
14             color: "transparent"
15             Text {
16                 text: index
17             }
18             Text {
19                 x: 30
20                 id: textName
21                 objectName: "textName"
22                 text: name
23             }
24             Text {
25                 x: 120
26                 id: textNumber
27                 objectName: "textNumber"
28                 text: number
29             }
30             Text {
31                 x: 200
32                 text: wrapper.y
33             }
34         }
35     }
36
37     Rectangle {     // current listview item should be always in this area
38         y: 100
39         height: 20
40         width: 240
41         color: "purple"
42     }
43
44     ListView {
45         id: list
46         objectName: "list"
47         width: 240
48         height: 320
49         model: testModel
50         delegate: myDelegate
51         focus: true
52
53         preferredHighlightBegin: 100
54         preferredHighlightEnd: 100
55         highlightRangeMode: "StrictlyEnforceRange"
56
57         section.property: "number"
58         section.delegate: Rectangle { width: 240; height: 10; color: "lightsteelblue" }
59     }
60 }
61