summaryrefslogtreecommitdiffstats
path: root/demos
diff options
context:
space:
mode:
authorTero Ahola <tero.ahola@digia.com>2012-11-28 14:36:59 +0200
committerTero Ahola <tero.ahola@digia.com>2012-11-28 14:40:05 +0200
commit2932f37127178496c91f6cf0fc94e9cb04740b12 (patch)
tree4455e752b380206eafa511f27a1d5fffcb97902e /demos
parent4de64fb010d7ee98cb6797c684431d415679889c (diff)
Fixed QML oscilloscope layout
Diffstat (limited to 'demos')
-rw-r--r--demos/qmloscilloscope/datasource.cpp2
-rw-r--r--demos/qmloscilloscope/qml/qmloscilloscope/ControlPanel.qml5
-rw-r--r--demos/qmloscilloscope/qml/qmloscilloscope/MultiButton.qml13
-rw-r--r--demos/qmloscilloscope/qml/qmloscilloscope/ScopeView.qml4
-rw-r--r--demos/qmloscilloscope/qml/qmloscilloscope/main.qml1
5 files changed, 16 insertions, 9 deletions
diff --git a/demos/qmloscilloscope/datasource.cpp b/demos/qmloscilloscope/datasource.cpp
index dfbc0d4b..f09c51c2 100644
--- a/demos/qmloscilloscope/datasource.cpp
+++ b/demos/qmloscilloscope/datasource.cpp
@@ -53,8 +53,6 @@ void DataSource::update(QAbstractSeries *series)
void DataSource::generateData(int type, int rowCount, int colCount)
{
- qDebug() << "DataSource::generateData:" << type << rowCount << colCount;
-
// Remove previous data
foreach (QList<QPointF> row, m_data)
row.clear();
diff --git a/demos/qmloscilloscope/qml/qmloscilloscope/ControlPanel.qml b/demos/qmloscilloscope/qml/qmloscilloscope/ControlPanel.qml
index f94d46bf..f5c536e4 100644
--- a/demos/qmloscilloscope/qml/qmloscilloscope/ControlPanel.qml
+++ b/demos/qmloscilloscope/qml/qmloscilloscope/ControlPanel.qml
@@ -21,7 +21,7 @@
import QtQuick 1.0
Column {
- spacing: 5
+ spacing: 8
signal animationsEnabled(bool enabled)
signal seriesTypeChanged(string type)
signal refreshRateChanged(variant rate);
@@ -29,8 +29,9 @@ Column {
signal antialiasingEnabled(bool enabled)
Text {
- text: "Oscilloscope"
+ text: "Scope-PAS2"
font.pointSize: 18
+ color: "white"
}
MultiButton {
diff --git a/demos/qmloscilloscope/qml/qmloscilloscope/MultiButton.qml b/demos/qmloscilloscope/qml/qmloscilloscope/MultiButton.qml
index 9509e84f..95d804c0 100644
--- a/demos/qmloscilloscope/qml/qmloscilloscope/MultiButton.qml
+++ b/demos/qmloscilloscope/qml/qmloscilloscope/MultiButton.qml
@@ -22,9 +22,14 @@ import QtQuick 1.0
Rectangle {
id: button
- width: 120
- height: 30
- border.color: "gray"
+ width: 115
+ height: 31
+ gradient: Gradient {
+ GradientStop { position: mouseArea.pressed ? 1.0 : 0.0; color: "#A09090" }
+ GradientStop { position: mouseArea.pressed ? 0.0 : 1.0; color: "#505050" }
+ }
+ smooth: true
+
radius: 7
property string text: "Option: "
property variant items: ["first"]
@@ -34,10 +39,12 @@ Rectangle {
Text {
id: buttonText
anchors.centerIn: parent
+ color: "#FFFFFF"
text: button.text + button.items[currentSelection]
}
MouseArea {
+ id: mouseArea
anchors.fill: parent
onClicked: {
currentSelection = (currentSelection + 1) % items.length;
diff --git a/demos/qmloscilloscope/qml/qmloscilloscope/ScopeView.qml b/demos/qmloscilloscope/qml/qmloscilloscope/ScopeView.qml
index 1a7b2b0e..97c94039 100644
--- a/demos/qmloscilloscope/qml/qmloscilloscope/ScopeView.qml
+++ b/demos/qmloscilloscope/qml/qmloscilloscope/ScopeView.qml
@@ -19,7 +19,7 @@
****************************************************************************/
import QtQuick 1.0
-import QtCommercial.Chart 1.1
+import QtCommercial.Chart 1.2
//![1]
ChartView {
@@ -55,7 +55,7 @@ ChartView {
id: lineSeries2
name: "signal 2"
axisX: axisX
- axisY: axisY2
+ axisYRight: axisY2
}
// ...
//![1]
diff --git a/demos/qmloscilloscope/qml/qmloscilloscope/main.qml b/demos/qmloscilloscope/qml/qmloscilloscope/main.qml
index 8794a622..daac400f 100644
--- a/demos/qmloscilloscope/qml/qmloscilloscope/main.qml
+++ b/demos/qmloscilloscope/qml/qmloscilloscope/main.qml
@@ -25,6 +25,7 @@ Rectangle {
id: main
width: 400
height: 300
+ color: "#404040"
ControlPanel {
id: controlPanel