12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667 |
- import QtQuick 2.5
- import QtQuick.Controls 1.4
- //import Qt.labs.controls 1.0
- import QtQuick.Controls 2.0
- import QtQuick.Controls.Styles 1.3
- import QtGraphicalEffects 1.0
- import "qrc:/Globals"
- Item {
- id: item1
- property int buttImgBorder: 20 // in percent of parent.height defaults to 20%
- property double itemMargin: height * (buttImgBorder / 200.0)
- width: parent.width
- height: parent.height / 10.0
- x: 0
- y: parent.height - height
- Rectangle {
- anchors.fill: parent
- gradient: Gradient {
- // GradientStop { position: 0.0; color: "darkgray" }
- // GradientStop { position: 1.0; color: "black" }
- GradientStop { position: 0.0; color: "darkgray" }
- GradientStop { position: 1.0; color: "white" }
- }
- }
- Label {
- id: versHMI
- text: Globals.versionINFO + " : " + Globals.getActUserRoleText(Globals.actUserRole) //+
- //" IN: " + Globals.in1Status + Globals.in2Status + Globals.in3Status + Globals.in4Status
- font.pixelSize: 22
- anchors.left: parent.left
- anchors.top: parent.top
- anchors.topMargin: (parent.height - font.pixelSize) / 2
- anchors.leftMargin: 5
- width: parent.width * 0.25
- scale: paintedWidth > width ? (width / paintedWidth):1
- transformOrigin: Item.Left
- }
- Text {
- anchors.right: parent.right
- anchors.top: parent.top
- anchors.topMargin: (parent.height - font.pixelSize) / 2
- color: "white"
- text : ""
- font.pixelSize: 22
- width: parent.width * 0.6
- scale: paintedWidth > width ? (width / paintedWidth):1
- transformOrigin: Item.Left
- Timer {
- interval: 500
- running: true
- repeat: true
- triggeredOnStart: true
- onTriggered: {
- // parent.text = Qt.formatDateTime(new Date(),Qt.DefaultLocaleShortDate) + " ";
- parent.text = Qt.formatDateTime(new Date(),Qt.DefaultLocaleLongDate) + " ";
- }
- }
- }
- }
|