summaryrefslogtreecommitdiffstats
path: root/examples/declarative/tutorials/extending/chapter1-basics/app.qml
diff options
context:
space:
mode:
Diffstat (limited to 'examples/declarative/tutorials/extending/chapter1-basics/app.qml')
-rw-r--r--examples/declarative/tutorials/extending/chapter1-basics/app.qml18
1 files changed, 10 insertions, 8 deletions
diff --git a/examples/declarative/tutorials/extending/chapter1-basics/app.qml b/examples/declarative/tutorials/extending/chapter1-basics/app.qml
index 9af155c..ada088d 100644
--- a/examples/declarative/tutorials/extending/chapter1-basics/app.qml
+++ b/examples/declarative/tutorials/extending/chapter1-basics/app.qml
@@ -38,21 +38,23 @@
**
****************************************************************************/
//![0]
-import Music 1.0
+import Charts 1.0
import Qt 4.7
-Rectangle {
+Item {
width: 300; height: 200
- Musician {
- id: aMusician
- name: "Reddy the Rocker"
- instrument: "Guitar"
+ PieChart {
+ id: aPieChart
+ anchors.centerIn: parent
+ width: 100; height: 100
+ name: "A simple pie chart"
+ color: "red"
}
Text {
- anchors.fill: parent
- text: aMusician.name + " plays the " + aMusician.instrument
+ anchors { bottom: parent.bottom; horizontalCenter: parent.horizontalCenter; bottomMargin: 20 }
+ text: aPieChart.name
}
}
//![0]