Dynamically inserting data in graph
Unsolved
General and Desktop
-
here is my graph.qml, i need to insert data (XYPoint(x:..,y:..)) in graph.qml from main.qml (I am accessing this graph.qml in main.qml)
import QtQuick 2.0
import QtCharts 2.0Item {
id: graph
anchors.fill: parentproperty bool tempVisibilty property bool torqueVisibilty property bool accelVisibilty function callme(val1,val2) { console.log("I am called = "+val1+" =ok= "+val2) } ChartView { id: chartView title: "Sensor" anchors.fill: parent antialiasing: true LineSeries { visible:tempVisibilty id:temperature name: "Temperature" XYPoint { x: 0; y: 0 } XYPoint { x: 1.1; y: 2.1 } XYPoint { x: 1.9; y: 3.3 } XYPoint { x: 2.1; y: 2.1 } XYPoint { x: 2.9; y: 4.9 } XYPoint { x: 3.4; y: 3.0 } XYPoint { x: 4.1; y: 3.3 } }
}
}