summaryrefslogtreecommitdiffstats
path: root/basicsuite/enterprise-charts/View9.qml
diff options
context:
space:
mode:
Diffstat (limited to 'basicsuite/enterprise-charts/View9.qml')
-rw-r--r--basicsuite/enterprise-charts/View9.qml21
1 files changed, 12 insertions, 9 deletions
diff --git a/basicsuite/enterprise-charts/View9.qml b/basicsuite/enterprise-charts/View9.qml
index 23bc818..89a20b6 100644
--- a/basicsuite/enterprise-charts/View9.qml
+++ b/basicsuite/enterprise-charts/View9.qml
@@ -51,21 +51,24 @@
import QtQuick 2.0
import QtCharts 2.0
-Rectangle {
+Item {
anchors.fill: parent
-
//![1]
- ChartView {
+ BaseChart {
title: "Horizontal Bar series"
anchors.fill: parent
- legend.alignment: Qt.AlignBottom
- antialiasing: true
-
HorizontalBarSeries {
axisY: BarCategoryAxis { categories: ["2007", "2008", "2009", "2010", "2011", "2012" ] }
- BarSet { label: "Bob"; values: [2, 2, 3, 4, 5, 6] }
- BarSet { label: "Susan"; values: [5, 1, 2, 4, 1, 7] }
- BarSet { label: "James"; values: [3, 5, 8, 13, 5, 8] }
+ BarSet { label: "Bob"; color: defaultGreen; values: [2, 2, 3, 4, 5, 6] }
+ BarSet { label: "Susan"; color: defaultGrey; values: [5, 1, 2, 4, 1, 7] }
+ BarSet { label: "James"; color: secondaryGrey; values: [3, 5, 8, 13, 5, 8] }
+ }
+
+ Component.onCompleted: {
+ axes[0].labelsColor = "white";
+ axes[1].labelsColor = "white";
+ axes[0].labelsFont = appFont;
+ axes[1].labelsFont = appFont;
}
}
//![1]