DataCollectionsContent.qml 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. // Copyright (c) 2019 Ultimaker B.V.
  2. // Cura is released under the terms of the LGPLv3 or higher.
  3. import QtQuick 2.10
  4. import QtQuick.Controls 2.3
  5. import UM 1.3 as UM
  6. import Cura 1.1 as Cura
  7. //
  8. // This component contains the content for the "Help us to improve Ultimaker Cura" page of the welcome on-boarding process.
  9. //
  10. Item
  11. {
  12. UM.I18nCatalog { id: catalog; name: "cura" }
  13. Label
  14. {
  15. id: titleLabel
  16. anchors.top: parent.top
  17. anchors.horizontalCenter: parent.horizontalCenter
  18. horizontalAlignment: Text.AlignHCenter
  19. text: catalog.i18nc("@label", "Help us to improve Ultimaker Cura")
  20. color: UM.Theme.getColor("primary_button")
  21. font: UM.Theme.getFont("huge")
  22. renderType: Text.NativeRendering
  23. }
  24. // Area where the cloud contents can be put. Pictures, texts and such.
  25. Item
  26. {
  27. id: contentsArea
  28. anchors
  29. {
  30. top: titleLabel.bottom
  31. bottom: getStartedButton.top
  32. left: parent.left
  33. right: parent.right
  34. topMargin: UM.Theme.getSize("default_margin").width
  35. }
  36. Column
  37. {
  38. anchors.centerIn: parent
  39. width: parent.width
  40. spacing: UM.Theme.getSize("wide_margin").height
  41. Image
  42. {
  43. id: curaImage
  44. anchors.horizontalCenter: parent.horizontalCenter
  45. source: UM.Theme.getImage("first_run_share_data")
  46. }
  47. Label
  48. {
  49. id: textLabel
  50. width: parent.width
  51. anchors.horizontalCenter: parent.horizontalCenter
  52. horizontalAlignment: Text.AlignHCenter
  53. text:
  54. {
  55. var t = catalog.i18nc("@text", "Ultimaker Cura collects anonymous data to improve print quality and user experience.")
  56. var t2 = catalog.i18nc("@text", "More information")
  57. t += " <span style=\"color: rgb(0,0,255)\">" + t2 + "</span>"
  58. return t
  59. }
  60. textFormat: Text.RichText
  61. wrapMode: Text.WordWrap
  62. font: UM.Theme.getFont("medium")
  63. renderType: Text.NativeRendering
  64. MouseArea
  65. {
  66. anchors.fill: parent
  67. onClicked:
  68. {
  69. CuraApplication.showMoreInformationDialogForAnonymousDataCollection()
  70. }
  71. }
  72. }
  73. }
  74. }
  75. Cura.PrimaryButton
  76. {
  77. id: getStartedButton
  78. anchors.right: parent.right
  79. anchors.bottom: parent.bottom
  80. text: catalog.i18nc("@button", "Next")
  81. onClicked: base.showNextPage()
  82. }
  83. }