-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSparkline.qml
46 lines (39 loc) · 917 Bytes
/
Sparkline.qml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import QtQuick 2.0
import MrPlotter 0.1
Item {
id: toplevel
property string uuid
property string archiver
property bool autozoomOnLoad
property alias color: stream.color
property alias timeDomain: mrp.timeDomain
property alias scrollZoomable: pa.scrollZoomable
Stream {
id: stream
uuid: toplevel.uuid
archiver: toplevel.archiver
}
SmoothYAxis {
id: yaxis
dynamicAutoscale: true
name: "Reading"
domain: [-1, 1]
streamList: [stream]
}
PlotArea {
id: pa
anchors.fill: toplevel
streamList: [stream]
}
MrPlotter {
id: mrp
plotList: [pa]
timeDomain: [1415643674978, 1415643674979, 469055, 469060]
Component.onCompleted: {
if (autozoomOnLoad)
{
mrp.autozoom([stream]);
}
}
}
}