6 property int minimum: 0
7 property int maximum: 100
9 property int value2: 50
11 function setMax(intiger) { maximum=intiger }
12 function setMin(intiger) { minimum=intiger }
13 function setValue(intiger) { value= intiger }
14 function setValue2(intiger) { value2= intiger }
21 source: "qrc:/progressBar/background.png"
22 width: parent.width; height: parent.height
23 border { left: 4; top: 4; right: 4; bottom: 4 }
31 property int widthDest: (progressBar.width * (value - minimum)) / (maximum - minimum) - 6
32 property int position: (progressBar.width * (value2 - minimum)) / (maximum - minimum)
34 width: (value>-1) ? (highlight.widthDest) : (90)
35 anchors.leftMargin: (value>-1) ? (0) : (highlight.position)
43 Behavior on anchors.leftMargin {
45 loops: Animation.Infinite
46 SmoothedAnimation { velocity: 450; to: progressBar.width - 96}
47 SmoothedAnimation { velocity: 450; to: 0 }
52 anchors.top: parent.top
53 anchors.left: parent.left
55 anchors.bottom: parent.bottom
59 GradientStop {color:"#0510a0"; position: 0.0 }
60 GradientStop {color:"#6b98f7"; position: 1.0 }
66 anchors.right: highlight.right
67 anchors.rightMargin: (value>-1) ? 6 : 35;
68 anchors.verticalCenter: parent.verticalCenter
71 text: (value>-1) ? (Math.floor((value - minimum) / (maximum - minimum) * 100) + '%') : ("???");