diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/AreaEditor.qml b/tests/qmlchartproperties/qml/qmlchartproperties/AreaEditor.qml index 43ad78f..ec3b7f7 100644 --- a/tests/qmlchartproperties/qml/qmlchartproperties/AreaEditor.qml +++ b/tests/qmlchartproperties/qml/qmlchartproperties/AreaEditor.qml @@ -28,6 +28,20 @@ Flow { flow: Flow.TopToBottom property variant series + onSeriesChanged: { + seriesConnections.target = series; + } + + Connections { + id: seriesConnections + ignoreUnknownSignals: true + onNameChanged: console.log("series.onNameChanged: " + series.name); + onVisibleChanged: console.log("series.onVisibleChanged: " + series.visible); + onColorChanged: console.log("series.onColorChanged: " + series.color); + onBorderColorChanged: console.log("series.onBorderColorChanged: " + series.borderColor); + onCountChanged: console.log("series.onCountChanged: " + series.count); + } + Button { text: "visible" onClicked: series.visible = !series.visible; diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/BarEditor.qml b/tests/qmlchartproperties/qml/qmlchartproperties/BarEditor.qml index 38543ad..f0af47a 100644 --- a/tests/qmlchartproperties/qml/qmlchartproperties/BarEditor.qml +++ b/tests/qmlchartproperties/qml/qmlchartproperties/BarEditor.qml @@ -27,6 +27,29 @@ Flow { flow: Flow.TopToBottom property variant series + onSeriesChanged: { + seriesConnections.target = series; + setConnections.target = series.at(0); + } + + Connections { + id: seriesConnections + ignoreUnknownSignals: true + onNameChanged: console.log("series.onNameChanged: " + series.name); + onVisibleChanged: console.log("series.onVisibleChanged: " + series.visible); + onLabelsVisibleChanged: console.log("series.onLabelsVisibleChanged: " + series.labelsVisible); + onCountChanged: console.log("series.onCountChanged: " + series.count); + } + + Connections { + id: setConnections + ignoreUnknownSignals: true + onColorChanged: console.log("series.onColorChanged: " + series.color); + onBorderColorChanged: console.log("series.onBorderColorChanged: " + series.borderColor); + onLabelColorChanged: console.log("series.onLabelColorChanged: " + series.labelColor); + onCountChanged: console.log("series.onCountChanged: " + series.count); + } + Button { text: "visible" onClicked: series.visible = !series.visible; diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/Button.qml b/tests/qmlchartproperties/qml/qmlchartproperties/Button.qml index e5325c1..a435faa 100644 --- a/tests/qmlchartproperties/qml/qmlchartproperties/Button.qml +++ b/tests/qmlchartproperties/qml/qmlchartproperties/Button.qml @@ -58,7 +58,7 @@ Rectangle { Timer { id: repeatTimer - interval: 200 + interval: 140 repeat: true triggeredOnStart: false running: false diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/ChartEditor.qml b/tests/qmlchartproperties/qml/qmlchartproperties/ChartEditor.qml index 11aa3e6..60b57fe 100644 --- a/tests/qmlchartproperties/qml/qmlchartproperties/ChartEditor.qml +++ b/tests/qmlchartproperties/qml/qmlchartproperties/ChartEditor.qml @@ -28,8 +28,13 @@ Flow { flow: Flow.TopToBottom property variant series // TODO: rename to chart + onSeriesChanged: { + legendConnections.target = series.legend + } + Connections { target: series + ignoreUnknownSignals: true onVisibleChanged: console.log("chart.onVisibleChanged: " + series.visible); onThemeChanged: console.log("chart.onThemeChanged: " + series.theme); onLegendChanged: console.log("chart.onLegendChanged: " + series.legend); @@ -37,8 +42,10 @@ Flow { onTitleColorChanged: console.log("chart.onTitleColorChanged: " + series.titleColor); onBackgroundColorChanged: console.log("chart.onBackgroundColorChanged: " + series.backgroundColor); } + Connections { - target: series.legend + id: legendConnections + ignoreUnknownSignals: true onAlignmentChanged: console.log("legend.onAlignmentChanged: " + series.legend.alignment); onVisibleChanged: console.log("legend.onVisibleChanged: " + series.legend.visible); } diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/LineEditor.qml b/tests/qmlchartproperties/qml/qmlchartproperties/LineEditor.qml index f4243f4..99ac402 100644 --- a/tests/qmlchartproperties/qml/qmlchartproperties/LineEditor.qml +++ b/tests/qmlchartproperties/qml/qmlchartproperties/LineEditor.qml @@ -28,6 +28,20 @@ Flow { flow: Flow.TopToBottom property variant series + onSeriesChanged: { + seriesConnections.target = series; + } + + Connections { + id: seriesConnections + ignoreUnknownSignals: true + onNameChanged: console.log("series.onNameChanged: " + series.name); + onVisibleChanged: console.log("series.onVisibleChanged: " + series.visible); + onPointsVisibleChanged: console.log("series.onPointsVisibleChanged: " + series.pointsVisible); + onColorChanged: console.log("series.onColorChanged: " + series.color); + onCountChanged: console.log("series.onCountChanged: " + series.count); + } + Button { text: "visible" onClicked: series.visible = !series.visible; diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/PieEditor.qml b/tests/qmlchartproperties/qml/qmlchartproperties/PieEditor.qml index 4309ced..f25c5c1 100644 --- a/tests/qmlchartproperties/qml/qmlchartproperties/PieEditor.qml +++ b/tests/qmlchartproperties/qml/qmlchartproperties/PieEditor.qml @@ -27,6 +27,45 @@ Flow { flow: Flow.TopToBottom property variant series + onSeriesChanged: { + seriesConnections.target = series; + sliceConnections.target = series.at(0); + } + + Connections { + id: seriesConnections + ignoreUnknownSignals: true + onVisibleChanged: console.log("series.onVisibleChanged: " + series.visible); + onHorizontalPositionChanged:console.log("series.onHorizontalPositionChanged: " + series.horizontalPosition); + onVerticalPositionChanged: console.log("series.onVerticalPositionChanged: " + series.verticalPosition); + onSizeChanged: console.log("series.onSizeChanged: " + series.size); + onStartAngleChanged: console.log("series.onStartAngleChanged: " + series.startAngle); + onEndAngleChanged: console.log("series.onEndAngleChanged: " + series.endAngle); + onCountChanged: console.log("series.onCountChanged: " + series.count); + onSumChanged: console.log("series.onSumChanged: " + series.sum); + } + + Connections { + id: sliceConnections + ignoreUnknownSignals: true + onValueChanged: console.log("slice.onValueChanged: " + series.at(0).value); + onLabelVisibleChanged: console.log("slice.onLabelVisibleChanged: " + series.at(0).labelVisible); + onExplodedChanged: console.log("slice.onExplodedChanged: " + series.at(0).exploded); + onPenChanged: console.log("slice.onPenChanged: " + series.at(0).pen); + onBorderColorChanged: console.log("slice.onBorderColorChanged: " + series.at(0).borderColor); + onBorderWidthChanged: console.log("slice.onBorderWidthChanged: " + series.at(0).borderWidth); + onBrushChanged: console.log("slice.onBrushChanged: " + series.at(0).brush); + onColorChanged: console.log("slice.onColorChanged: " + series.at(0).color); + onLabelColorChanged: console.log("slice.onLabelColorChanged: " + series.at(0).labelColor); + onLabelBrushChanged: console.log("slice.onLabelBrushChanged: " + series.at(0).labelBrush); + onLabelFontChanged: console.log("slice.onLabelFontChanged: " + series.at(0).labelFont); + onLabelArmLengthFactorChanged: console.log("slice.onLabelArmLengthFactorChanged: " + series.at(0).labelArmLengthFactor); + onExplodeDistanceFactorChanged: console.log("slice.onExplodeDistanceFactorChanged: " + series.at(0).explodeDistanceFactor); + onPercentageChanged: console.log("slice.onPercentageChanged: " + series.at(0).percentage); + onStartAngleChanged: console.log("slice.onStartAngleChanged: " + series.at(0).startAngle); + onAngleSpanChanged: console.log("slice.onAngleSpanChanged: " + series.at(0).angleSpan); + } + Button { text: "visible" onClicked: series.visible = !series.visible; @@ -57,19 +96,19 @@ Flow { } Button { text: "series start angle +" - onClicked: series.startAngle += 0.1; + onClicked: series.startAngle += 1.1; } Button { text: "series start angle -" - onClicked: series.startAngle -= 0.1; + onClicked: series.startAngle -= 1.1; } Button { text: "series end angle +" - onClicked: series.endAngle += 0.1; + onClicked: series.endAngle += 1.1; } Button { text: "series end angle -" - onClicked: series.endAngle -= 0.1; + onClicked: series.endAngle -= 1.1; } Button { text: "slice color" diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/ScatterEditor.qml b/tests/qmlchartproperties/qml/qmlchartproperties/ScatterEditor.qml index 05d8341..97a7051 100644 --- a/tests/qmlchartproperties/qml/qmlchartproperties/ScatterEditor.qml +++ b/tests/qmlchartproperties/qml/qmlchartproperties/ScatterEditor.qml @@ -28,6 +28,23 @@ Flow { flow: Flow.TopToBottom property variant series + onSeriesChanged: { + seriesConnections.target = series; + } + + Connections { + id: seriesConnections + ignoreUnknownSignals: true + onNameChanged: console.log("series.onNameChanged: " + series.name); + onVisibleChanged: console.log("series.onVisibleChanged: " + series.visible); + onPointsVisibleChanged: console.log("series.onPointsVisibleChanged: " + series.pointsVisible); + onColorChanged: console.log("series.onColorChanged: " + series.color); + onBorderColorChanged: console.log("series.onBorderColorChanged: " + series.borderColor); + onCountChanged: console.log("series.onCountChanged: " + series.count); + onMarkerSizeChanged: console.log("series.onMarkerSizeChanged: " + series.markerSize); + onMarkerShapeChanged: console.log("series.onMarkerShapeChanged: " + series.markerShape); + } + Button { text: "visible" onClicked: series.visible = !series.visible; diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/main.qml b/tests/qmlchartproperties/qml/qmlchartproperties/main.qml index 9524e64..51f13a9 100644 --- a/tests/qmlchartproperties/qml/qmlchartproperties/main.qml +++ b/tests/qmlchartproperties/qml/qmlchartproperties/main.qml @@ -85,8 +85,7 @@ Rectangle { height: parent.height source: "Chart.qml" onStatusChanged: { - console.log("chartLoader.status: " + status + " " + source); - if (status == Loader.Ready && editorLoader.status == Loader.Ready) + if (status == Loader.Ready && editorLoader.status == Loader.Ready && chartLoader.item) editorLoader.item.series = chartLoader.item.series; } } @@ -97,8 +96,7 @@ Rectangle { height: parent.height source: "ChartEditor.qml" onStatusChanged: { - console.log("editorLoader.status: " + status + " " + source); - if (status == Loader.Ready && chartLoader.status == Loader.Ready) + if (status == Loader.Ready && chartLoader.status == Loader.Ready && chartLoader.item) editorLoader.item.series = chartLoader.item.series; } }