1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58
|
import QtQuick 2.0
Image {
width: 320
height: 480
source: "../shared/winter.png"
Grid {
columns: 2
Item { width: 35; height: 50 }
Row {
id: row_0000
Repeater {
model: 7
Rectangle {
width: 35
height: 50
color: Qt.rgba(index & 1 ? 0.75 : 0.85, 1, 1, 0.75)
Text { font.pointSize: 8; anchors.centerIn: parent; text: "Col " + (index + 1) }
}
}
}
Column {
Repeater {
model: 8
Rectangle {
width: 35
height: 50
color: Qt.rgba(1, 1, index & 1 ? 0.75 : 0.85, 0.75)
Text { font.pointSize: 8; anchors.centerIn: parent; text: "Row " + (index + 1) }
}
}
}
Grid {
id: grid_0001
columns: 7
rows: 8
opacity: 0.5
Repeater {
id: repeater_0001
model: 7 * 8
onActiveFocusChanged: console.debug("changed")
Rectangle {
id: rect_0001
width: 35
height: 50
radius: 10
gradient: Gradient {
GradientStop { position: 0; color: "white" }
GradientStop { position: 1; color: "blue" }
}
border.width: 2
border.color: "black"
}
}
}
}
}
|