diff options
Diffstat (limited to 'examples/declarative/tutorials/t2/tutorial2.qml')
-rw-r--r-- | examples/declarative/tutorials/t2/tutorial2.qml | 52 |
1 files changed, 41 insertions, 11 deletions
diff --git a/examples/declarative/tutorials/t2/tutorial2.qml b/examples/declarative/tutorials/t2/tutorial2.qml index 1e3af16..08ea9eb 100644 --- a/examples/declarative/tutorials/t2/tutorial2.qml +++ b/examples/declarative/tutorials/t2/tutorial2.qml @@ -1,11 +1,41 @@ -<Rect id="Page" width="480" height="200" color="white"> - <Text id="HelloText" text="Hello world!" font.size="24" font.bold="true" y="30" anchors.horizontalCenter="{Page.horizontalCenter}"/> - <GridLayout id="ColorPicker" x="0" anchors.bottom="{Page.bottom}" width="120" height="50" columns="3" rows="2"> - <Cell color="#ff0000"/> - <Cell color="#00ff00"/> - <Cell color="#0000ff"/> - <Cell color="#ffff00"/> - <Cell color="#00ffff"/> - <Cell color="#ff00ff"/> - </GridLayout> -</Rect> +Rect { + id: Page + width: 480 + height: 200 + color: "white" + Text { + id: HelloText + text: "Hello world!" + font.size: 24 + font.bold: true + y: 30 + anchors.horizontalCenter: Page.horizontalCenter + } + GridLayout { + id: ColorPicker + x: 0 + anchors.bottom: Page.bottom + width: 120 + height: 50 + columns: 3 + rows: 2 + Cell { + color: "#ff0000" + } + Cell { + color: "#00ff00" + } + Cell { + color: "#0000ff" + } + Cell { + color: "#ffff00" + } + Cell { + color: "#00ffff" + } + Cell { + color: "#ff00ff" + } + } +} |