summaryrefslogtreecommitdiffstats
path: root/tests/qmlchartproperties
diff options
context:
space:
mode:
authorTero Ahola <tero.ahola@digia.com>2012-08-29 15:39:46 +0300
committerTero Ahola <tero.ahola@digia.com>2012-08-29 15:39:46 +0300
commit43c827a80f7842445c10d738361985ef3c421c0f (patch)
tree74151773fce93090f0d806efb666562793e60a8c /tests/qmlchartproperties
parentbe69f6b0e1736f53864892cfe84968b95eba8bb2 (diff)
Fixed QML BarSet::remove
Diffstat (limited to 'tests/qmlchartproperties')
-rw-r--r--tests/qmlchartproperties/qml/qmlchartproperties/BarEditor.qml87
-rw-r--r--tests/qmlchartproperties/qml/qmlchartproperties/PieEditor.qml1
2 files changed, 76 insertions, 12 deletions
diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/BarEditor.qml b/tests/qmlchartproperties/qml/qmlchartproperties/BarEditor.qml
index 8556fb69..68396c21 100644
--- a/tests/qmlchartproperties/qml/qmlchartproperties/BarEditor.qml
+++ b/tests/qmlchartproperties/qml/qmlchartproperties/BarEditor.qml
@@ -25,19 +25,63 @@ Row {
spacing: 5
property variant series
+ // buttons for selecting the edited object: series, barset or label
Flow {
spacing: 5
flow: Flow.TopToBottom
+ Button {
+ id: seriesButton
+ text: "series"
+ unpressedColor: "#79bd8f"
+ onClicked: {
+ seriesFlow.visible = true;
+ setFlow.visible = false;
+ labelsFlow.visible = false;
+ color = "#00a388";
+ sliceButton.color = "#79bd8f";
+ labelButton.color = "#79bd8f";
+ }
+ }
+ Button {
+ id: setButton
+ text: "BarSet"
+ unpressedColor: "#79bd8f"
+ onClicked: {
+ seriesFlow.visible = false;
+ setFlow.visible = true;
+ labelsFlow.visible = false;
+ color = "#00a388";
+ seriesButton.color = "#79bd8f";
+ labelButton.color = "#79bd8f";
+ }
+ }
+ Button {
+ id: labelButton
+ text: "label"
+ unpressedColor: "#79bd8f"
+ onClicked: {
+ seriesFlow.visible = false;
+ setFlow.visible = false;
+ labelsFlow.visible = true;
+ color = "#00a388";
+ seriesButton.color = "#79bd8f";
+ sliceButton.color = "#79bd8f";
+ }
+ }
+ }
+
+ // Buttons for editing series
+ Flow {
+ id: seriesFlow
+ spacing: 5
+ flow: Flow.TopToBottom
+ visible: false
Button {
text: "visible"
onClicked: series.visible = !series.visible;
}
Button {
- text: "labels visible"
- onClicked: series.labelsVisible = !series.labelsVisible;
- }
- Button {
text: "bar width +"
onClicked: series.barWidth += 0.1;
}
@@ -45,6 +89,15 @@ Row {
text: "bar width -"
onClicked: series.barWidth -= 0.1;
}
+ }
+
+ // Buttons for editing sets
+ Flow {
+ id: setFlow
+ spacing: 5
+ flow: Flow.TopToBottom
+ visible: false
+
Button {
text: "append set"
onClicked: {
@@ -97,17 +150,29 @@ Row {
text: "set 1 borderWidth - (" + series.at(0).borderWidth + ")"
onClicked: series.at(0).borderWidth -= 0.5;
}
+ }
+
+
+ Flow {
+ id: labelsFlow
+ spacing: 5
+ flow: Flow.TopToBottom
+ visible: false
+
+ Button {
+ text: "labels visible"
+ onClicked: series.labelsVisible = !series.labelsVisible;
+ }
Button {
text: "set 1 label color"
onClicked: series.at(0).labelColor = main.nextColor();
}
- }
-
- FontEditor {
- id: fontEditor
- fontDescription: "label"
- function editedFont() {
- return series.at(0).labelFont;
+ FontEditor {
+ id: fontEditor
+ fontDescription: "label"
+ function editedFont() {
+ return series.at(0).labelFont;
+ }
}
}
}
diff --git a/tests/qmlchartproperties/qml/qmlchartproperties/PieEditor.qml b/tests/qmlchartproperties/qml/qmlchartproperties/PieEditor.qml
index 999c47d9..1fe06e8c 100644
--- a/tests/qmlchartproperties/qml/qmlchartproperties/PieEditor.qml
+++ b/tests/qmlchartproperties/qml/qmlchartproperties/PieEditor.qml
@@ -29,7 +29,6 @@ Row {
// buttons for selecting the edited object: series, slice or label
Flow {
- id: editorSelectorFlow
spacing: 5
flow: Flow.TopToBottom
Button {