FooterForm.ui.qml 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. import QtQuick 2.4
  2. import QtQuick.Controls 2.4
  3. import QtQuick.Layouts 1.3
  4. Page {
  5. width: 1280
  6. height: 200
  7. font.capitalization: Font.MixedCase
  8. Connections {
  9. target: _qmlHandler
  10. onLog: {
  11. footerLog.append(new Date().toLocaleTimeString(Qt.locale("de_DE"), "[hh:mm:ss]\n") + logText)
  12. footerFlickable.contentY = footerLog.height - footerFlickable.height
  13. }
  14. onFooterSetStatus: {
  15. footerStatusText.text = "Status: " + status
  16. }
  17. }
  18. Rectangle {
  19. anchors.fill: parent
  20. color: "#404040"
  21. ColumnLayout {
  22. anchors.fill: parent
  23. RowLayout {
  24. Layout.preferredHeight: 30
  25. Layout.preferredWidth: parent.width
  26. Text {
  27. id: footerStatusText
  28. Layout.preferredHeight: parent.height
  29. Layout.preferredWidth: 1000
  30. color: "#ffffff"
  31. text: qsTr("")
  32. font.pixelSize: 23
  33. }
  34. Button {
  35. id: footerGetStatusButton
  36. Layout.preferredHeight: 30
  37. Layout.preferredWidth: 250
  38. text: qsTr("Get Status")
  39. // @disable-check M223
  40. onClicked: {
  41. footerStatusText.text = ""
  42. // @disable-check M222
  43. _qmlHandler.onFooterGetStatusButton()
  44. }
  45. }
  46. }
  47. Flickable {
  48. id: footerFlickable
  49. flickableDirection: Flickable.VerticalFlick
  50. Layout.preferredHeight: 170
  51. Layout.preferredWidth: parent.width
  52. TextArea.flickable: TextArea {
  53. selectByMouse: true
  54. id: footerLog
  55. readOnly: true
  56. wrapMode: TextArea.Wrap
  57. text: qsTr("")
  58. font.pointSize: 15
  59. }
  60. ScrollBar.vertical: ScrollBar {
  61. }
  62. }
  63. }
  64. }
  65. }