From 7c41444789be188fc47b3d68f4431d85d52d1e46 Mon Sep 17 00:00:00 2001 From: Juho Annunen Date: Tue, 17 Apr 2018 13:57:22 +0300 Subject: Update Charts demo to new UI theme Task-number: QTBUG-62792 Change-Id: I95c6fb038f5d427da2ed1ee6698e1afcfa436eee Reviewed-by: Sami Nurmenniemi --- basicsuite/enterprise-charts/BaseChart.qml | 64 ++++++++++++++++++++++ basicsuite/enterprise-charts/View1.qml | 19 +++---- basicsuite/enterprise-charts/View10.qml | 19 ++++--- basicsuite/enterprise-charts/View11.qml | 20 ++++--- basicsuite/enterprise-charts/View12.qml | 39 ++++++------- basicsuite/enterprise-charts/View2.qml | 15 +++-- basicsuite/enterprise-charts/View3.qml | 15 +++-- basicsuite/enterprise-charts/View4.qml | 26 +++++---- basicsuite/enterprise-charts/View5.qml | 16 ++++-- basicsuite/enterprise-charts/View6.qml | 21 ++++--- basicsuite/enterprise-charts/View7.qml | 20 ++++--- basicsuite/enterprise-charts/View8.qml | 21 ++++--- basicsuite/enterprise-charts/View9.qml | 21 ++++--- basicsuite/enterprise-charts/enterprise-charts.pro | 1 + basicsuite/enterprise-charts/main.qml | 9 +++ basicsuite/shared/SharedMain.qml | 9 +++ 16 files changed, 228 insertions(+), 107 deletions(-) create mode 100644 basicsuite/enterprise-charts/BaseChart.qml diff --git a/basicsuite/enterprise-charts/BaseChart.qml b/basicsuite/enterprise-charts/BaseChart.qml new file mode 100644 index 0000000..27811b0 --- /dev/null +++ b/basicsuite/enterprise-charts/BaseChart.qml @@ -0,0 +1,64 @@ +/**************************************************************************** +** +** Copyright (C) 2018 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of the examples of Qt for Device Creation. +** +** $QT_BEGIN_LICENSE:BSD$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** BSD License Usage +** Alternatively, you may use this file under the terms of the BSD license +** as follows: +** +** "Redistribution and use in source and binary forms, with or without +** modification, are permitted provided that the following conditions are +** met: +** * Redistributions of source code must retain the above copyright +** notice, this list of conditions and the following disclaimer. +** * Redistributions in binary form must reproduce the above copyright +** notice, this list of conditions and the following disclaimer in +** the documentation and/or other materials provided with the +** distribution. +** * Neither the name of The Qt Company Ltd nor the names of its +** contributors may be used to endorse or promote products derived +** from this software without specific prior written permission. +** +** +** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QtCharts 2.0 + +ChartView{ + id: chart + titleFont.family: appFont + titleFont.styleName: "SemiBold" + titleColor: "white" + legend.alignment: Qt.AlignBottom + legend.font.family: appFont + legend.labelColor: "white" + antialiasing: true + backgroundColor: "transparent" +} diff --git a/basicsuite/enterprise-charts/View1.qml b/basicsuite/enterprise-charts/View1.qml index 64aa78c..f85a18e 100644 --- a/basicsuite/enterprise-charts/View1.qml +++ b/basicsuite/enterprise-charts/View1.qml @@ -53,31 +53,30 @@ import QtQuick 2.0 //![2] import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent property variant othersSlice: 0 + //![1] - ChartView { + BaseChart { id: chart title: "Top-5 car brand shares in Finland" anchors.fill: parent - legend.alignment: Qt.AlignBottom - antialiasing: true - PieSeries { id: pieSeries - PieSlice { label: "Volkswagen"; value: 13.5 } - PieSlice { label: "Toyota"; value: 10.9 } - PieSlice { label: "Ford"; value: 8.6 } - PieSlice { label: "Skoda"; value: 8.2 } - PieSlice { label: "Volvo"; value: 6.8 } + PieSlice { label: "Volkswagen"; value: 13.5; color: defaultGreen } + PieSlice { label: "Toyota"; value: 10.9; color: mediumGreen } + PieSlice { label: "Ford"; value: 8.6; color: darkGreen } + PieSlice { label: "Skoda"; value: 8.2; color: defaultGrey } + PieSlice { label: "Volvo"; value: 6.8; color: secondaryGrey } } } Component.onCompleted: { // You can also manipulate slices dynamically othersSlice = pieSeries.append("Others", 52.0); + othersSlice.color = mediumGrey; pieSeries.find("Volkswagen").exploded = true; } //![1] diff --git a/basicsuite/enterprise-charts/View10.qml b/basicsuite/enterprise-charts/View10.qml index adcd350..79ca4ab 100644 --- a/basicsuite/enterprise-charts/View10.qml +++ b/basicsuite/enterprise-charts/View10.qml @@ -51,21 +51,24 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { title: "Horizontal Stacked Bar series" anchors.fill: parent - legend.alignment: Qt.AlignBottom - antialiasing: true HorizontalStackedBarSeries { 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] diff --git a/basicsuite/enterprise-charts/View11.qml b/basicsuite/enterprise-charts/View11.qml index 37c3d80..dd81733 100644 --- a/basicsuite/enterprise-charts/View11.qml +++ b/basicsuite/enterprise-charts/View11.qml @@ -51,21 +51,25 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { title: "Horizontal Percent Bar series" anchors.fill: parent - legend.alignment: Qt.AlignBottom - antialiasing: true HorizontalPercentBarSeries { 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] diff --git a/basicsuite/enterprise-charts/View12.qml b/basicsuite/enterprise-charts/View12.qml index 39d8a13..588ec4b 100644 --- a/basicsuite/enterprise-charts/View12.qml +++ b/basicsuite/enterprise-charts/View12.qml @@ -51,42 +51,39 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { id: chart title: "Production costs" - anchors.fill: parent legend.visible: false - antialiasing: true - + anchors.fill: parent PieSeries { id: pieOuter size: 0.96 holeSize: 0.7 - PieSlice { id: slice; label: "Alpha"; value: 19511; color: "#8AB846"; borderColor: "#163430" } - PieSlice { label: "Epsilon"; value: 11105; color: "#C0EEFF"; borderColor: "#3B391C" } - PieSlice { label: "Psi"; value: 9352; color: "#DF8939"; borderColor: "#13060C" } + + PieSlice { id: slice; label: "Alpha"; value: 19511; color: defaultGreen; borderColor: "#163430" } + PieSlice { label: "Epsilon"; value: 11105; color: defaultGrey; borderColor: "#3B391C" } + PieSlice { label: "Psi"; value: 9352; color: darkGrey2; borderColor: "#13060C" } } PieSeries { size: 0.7 id: pieInner holeSize: 0.25 + PieSlice { label: "Materials"; value: 10334; color: mediumGreen; borderColor: "#163430" } + PieSlice { label: "Employee"; value: 3066; color: darkGreen; borderColor: "#163430" } + PieSlice { label: "Logistics"; value: 6111; color: mediumGreen; borderColor: "#163430" } - PieSlice { label: "Materials"; value: 10334; color: "#8AB846"; borderColor: "#163430" } - PieSlice { label: "Employee"; value: 3066; color: "#AAE356"; borderColor: "#163430" } - PieSlice { label: "Logistics"; value: 6111; color: "#99CC4E"; borderColor: "#163430" } - - PieSlice { label: "Materials"; value: 7371; color: "#C0EEFF"; borderColor: "#3B391C" } - PieSlice { label: "Employee"; value: 2443; color: "#C9FAFF"; borderColor: "#3B391C" } - PieSlice { label: "Logistics"; value: 1291; color: "#B0FAFF"; borderColor: "#3B391C" } + PieSlice { label: "Materials"; value: 7371; color: mediumGrey2; borderColor: "#3B391C" } + PieSlice { label: "Employee"; value: 2443; color: mediumGrey; borderColor: "#3B391C" } + PieSlice { label: "Logistics"; value: 1291; color: mediumGrey2; borderColor: "#3B391C" } - PieSlice { label: "Materials"; value: 4022; color: "#DF8939"; borderColor: "#13060C" } - PieSlice { label: "Employee"; value: 3998; color: "#FC9D42"; borderColor: "#13060C" } - PieSlice { label: "Logistics"; value: 1332; color: "#F2963F"; borderColor: "#13060C" } + PieSlice { label: "Materials"; value: 4022; color: secondaryGrey; borderColor: "#13060C" } + PieSlice { label: "Employee"; value: 3998; color: darkGrey; borderColor: "#13060C" } + PieSlice { label: "Logistics"; value: 1332; color: secondaryGrey; borderColor: "#13060C" } } } @@ -96,11 +93,15 @@ Rectangle { pieOuter.at(i).labelPosition = PieSlice.LabelOutside; pieOuter.at(i).labelVisible = true; pieOuter.at(i).borderWidth = 3; + pieOuter.at(i).labelColor = "white"; + pieOuter.at(i).labelFont = appFont; } for (var i = 0; i < pieInner.count; i++) { pieInner.at(i).labelPosition = PieSlice.LabelInsideNormal; pieInner.at(i).labelVisible = true; pieInner.at(i).borderWidth = 2; + pieInner.at(i).labelColor = "white"; + pieInner.at(i).labelFont = appFont; } } //![1] diff --git a/basicsuite/enterprise-charts/View2.qml b/basicsuite/enterprise-charts/View2.qml index 8f136cc..504e6a1 100644 --- a/basicsuite/enterprise-charts/View2.qml +++ b/basicsuite/enterprise-charts/View2.qml @@ -51,17 +51,15 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { title: "Line" anchors.fill: parent - antialiasing: true - LineSeries { name: "LineSeries" + color: defaultGreen XYPoint { x: 0; y: 0 } XYPoint { x: 1.1; y: 2.1 } XYPoint { x: 1.9; y: 3.3 } @@ -70,6 +68,13 @@ Rectangle { XYPoint { x: 3.4; y: 3.0 } XYPoint { x: 4.1; y: 3.3 } } + + Component.onCompleted: { + axes[0].labelsColor = "white"; + axes[1].labelsColor = "white"; + axes[0].labelsFont = appFont; + axes[1].labelsFont = appFont; + } } //![1] } diff --git a/basicsuite/enterprise-charts/View3.qml b/basicsuite/enterprise-charts/View3.qml index 8429050..8c4e862 100644 --- a/basicsuite/enterprise-charts/View3.qml +++ b/basicsuite/enterprise-charts/View3.qml @@ -51,17 +51,15 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { title: "Spline" anchors.fill: parent - antialiasing: true - SplineSeries { name: "SplineSeries" + color: defaultGreen XYPoint { x: 0; y: 0.0 } XYPoint { x: 1.1; y: 3.2 } XYPoint { x: 1.9; y: 2.4 } @@ -70,6 +68,13 @@ Rectangle { XYPoint { x: 3.4; y: 2.3 } XYPoint { x: 4.1; y: 3.1 } } + + Component.onCompleted: { + axes[0].labelsColor = "white"; + axes[1].labelsColor = "white"; + axes[0].labelsFont = appFont; + axes[1].labelsFont = appFont; + } } //![1] } diff --git a/basicsuite/enterprise-charts/View4.qml b/basicsuite/enterprise-charts/View4.qml index ac3ea56..606029a 100644 --- a/basicsuite/enterprise-charts/View4.qml +++ b/basicsuite/enterprise-charts/View4.qml @@ -51,15 +51,12 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { title: "NHL All-Star Team Players" anchors.fill: parent - antialiasing: true - ValueAxis { id: valueAxis min: 2000 @@ -70,8 +67,8 @@ Rectangle { AreaSeries { name: "Russian" - color: "#FFD52B1E" - borderColor: "#FF0039A5" + color: mediumGrey2 + borderColor: darkGreen borderWidth: 3 axisX: valueAxis upperSeries: LineSeries { @@ -93,8 +90,8 @@ Rectangle { AreaSeries { name: "Swedish" - color: "#AF005292" - borderColor: "#AFFDCA00" + color: lightGrey + borderColor: mediumGreen borderWidth: 3 axisX: valueAxis upperSeries: LineSeries { @@ -115,8 +112,8 @@ Rectangle { AreaSeries { name: "Finnish" - color: "#00357F" - borderColor: "#FEFEFE" + color: secondaryGrey + borderColor: defaultGreen borderWidth: 3 axisX: valueAxis upperSeries: LineSeries { @@ -134,5 +131,12 @@ Rectangle { XYPoint { x: 2011; y: 1 } } } + + Component.onCompleted: { + axes[0].labelsColor = "white"; + axes[1].labelsColor = "white"; + axes[0].labelsFont = appFont; + axes[1].labelsFont = appFont; + } } } diff --git a/basicsuite/enterprise-charts/View5.qml b/basicsuite/enterprise-charts/View5.qml index f1005c3..17e9b2f 100644 --- a/basicsuite/enterprise-charts/View5.qml +++ b/basicsuite/enterprise-charts/View5.qml @@ -51,18 +51,16 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { title: "Scatters" anchors.fill: parent - antialiasing: true - ScatterSeries { id: scatter1 name: "Scatter1" + color: defaultGreen XYPoint { x: 1.5; y: 1.5 } XYPoint { x: 1.5; y: 1.6 } XYPoint { x: 1.57; y: 1.55 } @@ -74,6 +72,7 @@ Rectangle { ScatterSeries { name: "Scatter2" + color: defaultGrey //![1] XYPoint { x: 2.0; y: 2.0 } XYPoint { x: 2.0; y: 2.1 } @@ -82,5 +81,12 @@ Rectangle { XYPoint { x: 2.4; y: 2.7 } XYPoint { x: 2.67; y: 2.65 } } + + Component.onCompleted: { + axes[0].labelsColor = "white"; + axes[1].labelsColor = "white"; + axes[0].labelsFont = appFont; + axes[1].labelsFont = appFont; + } } } diff --git a/basicsuite/enterprise-charts/View6.qml b/basicsuite/enterprise-charts/View6.qml index 6f29bf9..23d4b70 100644 --- a/basicsuite/enterprise-charts/View6.qml +++ b/basicsuite/enterprise-charts/View6.qml @@ -51,22 +51,25 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { title: "Bar series" anchors.fill: parent - legend.alignment: Qt.AlignBottom - antialiasing: true - BarSeries { id: mySeries axisX: 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] diff --git a/basicsuite/enterprise-charts/View7.qml b/basicsuite/enterprise-charts/View7.qml index c8b6654..5b5426c 100644 --- a/basicsuite/enterprise-charts/View7.qml +++ b/basicsuite/enterprise-charts/View7.qml @@ -51,22 +51,24 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { title: "Stacked Bar series" anchors.fill: parent - legend.alignment: Qt.AlignBottom - antialiasing: true - StackedBarSeries { id: mySeries axisX: 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] diff --git a/basicsuite/enterprise-charts/View8.qml b/basicsuite/enterprise-charts/View8.qml index fbb30e3..ff7bed7 100644 --- a/basicsuite/enterprise-charts/View8.qml +++ b/basicsuite/enterprise-charts/View8.qml @@ -51,21 +51,24 @@ import QtQuick 2.0 import QtCharts 2.0 -Rectangle { +Item { anchors.fill: parent - //![1] - ChartView { + BaseChart { title: "Percent Bar series" anchors.fill: parent - legend.alignment: Qt.AlignBottom - antialiasing: true - PercentBarSeries { axisX: 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] 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] diff --git a/basicsuite/enterprise-charts/enterprise-charts.pro b/basicsuite/enterprise-charts/enterprise-charts.pro index 7896c62..803feb0 100644 --- a/basicsuite/enterprise-charts/enterprise-charts.pro +++ b/basicsuite/enterprise-charts/enterprise-charts.pro @@ -4,6 +4,7 @@ include(../shared/shared.pri) b2qtdemo_deploy_defaults() content.files = \ + BaseChart.qml \ loader.qml \ main.qml \ View1.qml \ diff --git a/basicsuite/enterprise-charts/main.qml b/basicsuite/enterprise-charts/main.qml index d29ed2d..6c16b82 100644 --- a/basicsuite/enterprise-charts/main.qml +++ b/basicsuite/enterprise-charts/main.qml @@ -56,6 +56,14 @@ Rectangle { width: 600 height: 400 property bool sourceLoaded: false + color: defaultBackground + + property string darkGrey: "#222840" + property string darkGrey2: "#53586b" + property string mediumGrey: "#6b7080" + property string mediumGrey2: "#848895" + property string lightGrey: "#b5b7bf" + ListView { id: root @@ -112,6 +120,7 @@ Rectangle { color: "white" anchors.centerIn: parent text: "You can navigate between views using swipe or arrow keys" + font.family: appFont } Behavior on opacity { diff --git a/basicsuite/shared/SharedMain.qml b/basicsuite/shared/SharedMain.qml index ec6d13b..d9f38a8 100644 --- a/basicsuite/shared/SharedMain.qml +++ b/basicsuite/shared/SharedMain.qml @@ -60,6 +60,15 @@ Window { color: "black" + property string defaultGreen: "#41cd52" + property string mediumGreen: "#21be2b" + property string darkGreen: "#17a81a" + + property string defaultBackground: "#09102b" + + property string defaultGrey: "#9d9faa" + property string secondaryGrey: "#3a4055" + Item { id: root anchors.centerIn: window.contentItem -- cgit v1.2.3