GeneralPage.qml 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757
  1. // Copyright (c) 2017 Ultimaker B.V.
  2. // Cura is released under the terms of the LGPLv3 or higher.
  3. import QtQuick 2.1
  4. import QtQuick.Controls 1.1
  5. import QtQuick.Layouts 1.1
  6. import QtQuick.Controls.Styles 1.1
  7. import UM 1.1 as UM
  8. import Cura 1.0 as Cura
  9. UM.PreferencesPage
  10. {
  11. //: General configuration page title
  12. title: catalog.i18nc("@title:tab","General")
  13. id: generalPreferencesPage
  14. function setDefaultLanguage(languageCode)
  15. {
  16. //loops trough the languageList and sets the language using the languageCode
  17. for(var i = 0; i < languageList.count; i++)
  18. {
  19. if (languageComboBox.model.get(i).code == languageCode)
  20. {
  21. languageComboBox.currentIndex = i
  22. }
  23. }
  24. }
  25. function setDefaultTheme(defaultThemeCode)
  26. {
  27. for(var i = 0; i < themeList.count; i++)
  28. {
  29. if (themeComboBox.model.get(i).code == defaultThemeCode)
  30. {
  31. themeComboBox.currentIndex = i
  32. }
  33. }
  34. }
  35. function setDefaultDiscardOrKeepProfile(code)
  36. {
  37. for (var i = 0; i < choiceOnProfileOverrideDropDownButton.model.count; i++)
  38. {
  39. if (choiceOnProfileOverrideDropDownButton.model.get(i).code == code)
  40. {
  41. choiceOnProfileOverrideDropDownButton.currentIndex = i;
  42. break;
  43. }
  44. }
  45. }
  46. function setDefaultOpenProjectOption(code)
  47. {
  48. for (var i = 0; i < choiceOnOpenProjectDropDownButton.model.count; ++i)
  49. {
  50. if (choiceOnOpenProjectDropDownButton.model.get(i).code == code)
  51. {
  52. choiceOnOpenProjectDropDownButton.currentIndex = i
  53. break;
  54. }
  55. }
  56. }
  57. function reset()
  58. {
  59. UM.Preferences.resetPreference("general/language")
  60. var defaultLanguage = UM.Preferences.getValue("general/language")
  61. setDefaultLanguage(defaultLanguage)
  62. UM.Preferences.resetPreference("general/theme")
  63. var defaultTheme = UM.Preferences.getValue("general/theme")
  64. setDefaultTheme(defaultTheme)
  65. UM.Preferences.resetPreference("physics/automatic_push_free")
  66. pushFreeCheckbox.checked = boolCheck(UM.Preferences.getValue("physics/automatic_push_free"))
  67. UM.Preferences.resetPreference("physics/automatic_drop_down")
  68. dropDownCheckbox.checked = boolCheck(UM.Preferences.getValue("physics/automatic_drop_down"))
  69. UM.Preferences.resetPreference("mesh/scale_to_fit")
  70. scaleToFitCheckbox.checked = boolCheck(UM.Preferences.getValue("mesh/scale_to_fit"))
  71. UM.Preferences.resetPreference("mesh/scale_tiny_meshes")
  72. scaleTinyCheckbox.checked = boolCheck(UM.Preferences.getValue("mesh/scale_tiny_meshes"))
  73. UM.Preferences.resetPreference("cura/select_models_on_load")
  74. selectModelsOnLoadCheckbox.checked = boolCheck(UM.Preferences.getValue("cura/select_models_on_load"))
  75. UM.Preferences.resetPreference("cura/jobname_prefix")
  76. prefixJobNameCheckbox.checked = boolCheck(UM.Preferences.getValue("cura/jobname_prefix"))
  77. UM.Preferences.resetPreference("view/show_overhang");
  78. showOverhangCheckbox.checked = boolCheck(UM.Preferences.getValue("view/show_overhang"))
  79. UM.Preferences.resetPreference("view/center_on_select");
  80. centerOnSelectCheckbox.checked = boolCheck(UM.Preferences.getValue("view/center_on_select"))
  81. UM.Preferences.resetPreference("view/invert_zoom");
  82. invertZoomCheckbox.checked = boolCheck(UM.Preferences.getValue("view/invert_zoom"))
  83. UM.Preferences.resetPreference("view/zoom_to_mouse");
  84. zoomToMouseCheckbox.checked = boolCheck(UM.Preferences.getValue("view/zoom_to_mouse"))
  85. UM.Preferences.resetPreference("view/top_layer_count");
  86. topLayerCountCheckbox.checked = boolCheck(UM.Preferences.getValue("view/top_layer_count"))
  87. UM.Preferences.resetPreference("cura/choice_on_profile_override")
  88. setDefaultDiscardOrKeepProfile(UM.Preferences.getValue("cura/choice_on_profile_override"))
  89. UM.Preferences.resetPreference("cura/choice_on_open_project")
  90. setDefaultOpenProjectOption(UM.Preferences.getValue("cura/choice_on_open_project"))
  91. if (pluginExistsAndEnabled("SliceInfoPlugin")) {
  92. UM.Preferences.resetPreference("info/send_slice_info")
  93. sendDataCheckbox.checked = boolCheck(UM.Preferences.getValue("info/send_slice_info"))
  94. }
  95. if (pluginExistsAndEnabled("UpdateChecker")) {
  96. UM.Preferences.resetPreference("info/automatic_update_check")
  97. checkUpdatesCheckbox.checked = boolCheck(UM.Preferences.getValue("info/automatic_update_check"))
  98. }
  99. }
  100. function pluginExistsAndEnabled(pluginName)
  101. {
  102. var pluginItem = plugins.find("id", pluginName)
  103. if (pluginItem > -1)
  104. {
  105. return plugins.getItem(pluginItem).enabled
  106. }
  107. return false
  108. }
  109. ScrollView
  110. {
  111. width: parent.width
  112. height: parent.height
  113. flickableItem.flickableDirection: Flickable.VerticalFlick;
  114. Column
  115. {
  116. //: Model used to check if a plugin exists
  117. UM.PluginsModel { id: plugins }
  118. //: Language selection label
  119. UM.I18nCatalog{id: catalog; name:"cura"}
  120. Label
  121. {
  122. font.bold: true
  123. text: catalog.i18nc("@label","Interface")
  124. }
  125. GridLayout
  126. {
  127. id: interfaceGrid
  128. columns: 4
  129. Label
  130. {
  131. id: languageLabel
  132. text: catalog.i18nc("@label","Language:")
  133. anchors.verticalCenter: languageComboBox.verticalCenter
  134. }
  135. ComboBox
  136. {
  137. id: languageComboBox
  138. model: ListModel
  139. {
  140. id: languageList
  141. Component.onCompleted: {
  142. append({ text: "English", code: "en_US" })
  143. append({ text: "Deutsch", code: "de_DE" })
  144. append({ text: "Español", code: "es_ES" })
  145. //Finnish is disabled for being incomplete: append({ text: "Suomi", code: "fi_FI" })
  146. append({ text: "Français", code: "fr_FR" })
  147. append({ text: "Italiano", code: "it_IT" })
  148. append({ text: "日本語", code: "ja_JP" })
  149. append({ text: "한국어", code: "ko_KR" })
  150. append({ text: "Nederlands", code: "nl_NL" })
  151. //Polish is disabled for being incomplete: append({ text: "Polski", code: "pl_PL" })
  152. append({ text: "Português do Brasil", code: "pt_BR" })
  153. append({ text: "Português", code: "pt_PT" })
  154. append({ text: "Русский", code: "ru_RU" })
  155. append({ text: "Türkçe", code: "tr_TR" })
  156. append({ text: "简体中文", code: "zh_CN" })
  157. append({ text: "正體字", code: "zh_TW" })
  158. var date_object = new Date();
  159. if (date_object.getUTCMonth() == 8 && date_object.getUTCDate() == 19) //Only add Pirate on the 19th of September.
  160. {
  161. append({ text: "Pirate", code: "en_7S" })
  162. }
  163. }
  164. }
  165. currentIndex:
  166. {
  167. var code = UM.Preferences.getValue("general/language");
  168. for(var i = 0; i < languageList.count; ++i)
  169. {
  170. if(model.get(i).code == code)
  171. {
  172. return i
  173. }
  174. }
  175. }
  176. onActivated: UM.Preferences.setValue("general/language", model.get(index).code)
  177. Component.onCompleted:
  178. {
  179. // Because ListModel is stupid and does not allow using qsTr() for values.
  180. for(var i = 0; i < languageList.count; ++i)
  181. {
  182. languageList.setProperty(i, "text", catalog.i18n(languageList.get(i).text));
  183. }
  184. // Glorious hack time. ComboBox does not update the text properly after changing the
  185. // model. So change the indices around to force it to update.
  186. currentIndex += 1;
  187. currentIndex -= 1;
  188. }
  189. }
  190. Label
  191. {
  192. id: currencyLabel
  193. text: catalog.i18nc("@label","Currency:")
  194. anchors.verticalCenter: currencyField.verticalCenter
  195. }
  196. TextField
  197. {
  198. id: currencyField
  199. text: UM.Preferences.getValue("cura/currency")
  200. onTextChanged: UM.Preferences.setValue("cura/currency", text)
  201. }
  202. Label
  203. {
  204. id: themeLabel
  205. text: catalog.i18nc("@label","Theme:")
  206. anchors.verticalCenter: themeComboBox.verticalCenter
  207. }
  208. ComboBox
  209. {
  210. id: themeComboBox
  211. model: ListModel
  212. {
  213. id: themeList
  214. Component.onCompleted: {
  215. var themes = UM.Theme.getThemes()
  216. for (var i = 0; i < themes.length; i++)
  217. {
  218. append({ text: themes[i].name.toString(), code: themes[i].id.toString() });
  219. }
  220. }
  221. }
  222. currentIndex:
  223. {
  224. var code = UM.Preferences.getValue("general/theme");
  225. for(var i = 0; i < themeList.count; ++i)
  226. {
  227. if(model.get(i).code == code)
  228. {
  229. return i
  230. }
  231. }
  232. return 0;
  233. }
  234. onActivated: UM.Preferences.setValue("general/theme", model.get(index).code)
  235. Component.onCompleted:
  236. {
  237. // Because ListModel is stupid and does not allow using qsTr() for values.
  238. for(var i = 0; i < themeList.count; ++i)
  239. {
  240. themeList.setProperty(i, "text", catalog.i18n(themeList.get(i).text));
  241. }
  242. // Glorious hack time. ComboBox does not update the text properly after changing the
  243. // model. So change the indices around to force it to update.
  244. currentIndex += 1;
  245. currentIndex -= 1;
  246. }
  247. }
  248. }
  249. Label
  250. {
  251. id: languageCaption
  252. //: Language change warning
  253. text: catalog.i18nc("@label", "You will need to restart the application for these changes to have effect.")
  254. wrapMode: Text.WordWrap
  255. font.italic: true
  256. }
  257. Item
  258. {
  259. //: Spacer
  260. height: UM.Theme.getSize("default_margin").height
  261. width: UM.Theme.getSize("default_margin").width
  262. }
  263. UM.TooltipArea
  264. {
  265. width: childrenRect.width;
  266. height: childrenRect.height;
  267. text: catalog.i18nc("@info:tooltip", "Slice automatically when changing settings.")
  268. CheckBox
  269. {
  270. id: autoSliceCheckbox
  271. checked: boolCheck(UM.Preferences.getValue("general/auto_slice"))
  272. onClicked: UM.Preferences.setValue("general/auto_slice", checked)
  273. text: catalog.i18nc("@option:check", "Slice automatically");
  274. }
  275. }
  276. Item
  277. {
  278. //: Spacer
  279. height: UM.Theme.getSize("default_margin").height
  280. width: UM.Theme.getSize("default_margin").width
  281. }
  282. Label
  283. {
  284. font.bold: true
  285. text: catalog.i18nc("@label", "Viewport behavior")
  286. }
  287. UM.TooltipArea
  288. {
  289. width: childrenRect.width;
  290. height: childrenRect.height;
  291. text: catalog.i18nc("@info:tooltip", "Highlight unsupported areas of the model in red. Without support these areas will not print properly.")
  292. CheckBox
  293. {
  294. id: showOverhangCheckbox
  295. checked: boolCheck(UM.Preferences.getValue("view/show_overhang"))
  296. onClicked: UM.Preferences.setValue("view/show_overhang", checked)
  297. text: catalog.i18nc("@option:check", "Display overhang");
  298. }
  299. }
  300. UM.TooltipArea {
  301. width: childrenRect.width;
  302. height: childrenRect.height;
  303. text: catalog.i18nc("@info:tooltip", "Moves the camera so the model is in the center of the view when a model is selected")
  304. CheckBox
  305. {
  306. id: centerOnSelectCheckbox
  307. text: catalog.i18nc("@action:button","Center camera when item is selected");
  308. checked: boolCheck(UM.Preferences.getValue("view/center_on_select"))
  309. onClicked: UM.Preferences.setValue("view/center_on_select", checked)
  310. }
  311. }
  312. UM.TooltipArea {
  313. width: childrenRect.width;
  314. height: childrenRect.height;
  315. text: catalog.i18nc("@info:tooltip", "Should the default zoom behavior of cura be inverted?")
  316. CheckBox
  317. {
  318. id: invertZoomCheckbox
  319. text: catalog.i18nc("@action:button", "Invert the direction of camera zoom.");
  320. checked: boolCheck(UM.Preferences.getValue("view/invert_zoom"))
  321. onClicked: UM.Preferences.setValue("view/invert_zoom", checked)
  322. }
  323. }
  324. UM.TooltipArea
  325. {
  326. width: childrenRect.width;
  327. height: childrenRect.height;
  328. text: catalog.i18nc("@info:tooltip", "Should zooming move in the direction of the mouse?")
  329. CheckBox
  330. {
  331. id: zoomToMouseCheckbox
  332. text: catalog.i18nc("@action:button", "Zoom toward mouse direction");
  333. checked: boolCheck(UM.Preferences.getValue("view/zoom_to_mouse"))
  334. onClicked: UM.Preferences.setValue("view/zoom_to_mouse", checked)
  335. }
  336. }
  337. UM.TooltipArea
  338. {
  339. width: childrenRect.width
  340. height: childrenRect.height
  341. text: catalog.i18nc("@info:tooltip", "Should models on the platform be moved so that they no longer intersect?")
  342. CheckBox
  343. {
  344. id: pushFreeCheckbox
  345. text: catalog.i18nc("@option:check", "Ensure models are kept apart")
  346. checked: boolCheck(UM.Preferences.getValue("physics/automatic_push_free"))
  347. onCheckedChanged: UM.Preferences.setValue("physics/automatic_push_free", checked)
  348. }
  349. }
  350. UM.TooltipArea
  351. {
  352. width: childrenRect.width
  353. height: childrenRect.height
  354. text: catalog.i18nc("@info:tooltip", "Should models on the platform be moved down to touch the build plate?")
  355. CheckBox
  356. {
  357. id: dropDownCheckbox
  358. text: catalog.i18nc("@option:check", "Automatically drop models to the build plate")
  359. checked: boolCheck(UM.Preferences.getValue("physics/automatic_drop_down"))
  360. onCheckedChanged: UM.Preferences.setValue("physics/automatic_drop_down", checked)
  361. }
  362. }
  363. UM.TooltipArea
  364. {
  365. width: childrenRect.width;
  366. height: childrenRect.height;
  367. text: catalog.i18nc("@info:tooltip","Show caution message in g-code reader.")
  368. CheckBox
  369. {
  370. id: gcodeShowCautionCheckbox
  371. checked: boolCheck(UM.Preferences.getValue("gcodereader/show_caution"))
  372. onClicked: UM.Preferences.setValue("gcodereader/show_caution", checked)
  373. text: catalog.i18nc("@option:check","Caution message in g-code reader");
  374. }
  375. }
  376. UM.TooltipArea
  377. {
  378. width: childrenRect.width
  379. height: childrenRect.height
  380. text: catalog.i18nc("@info:tooltip", "Should layer be forced into compatibility mode?")
  381. CheckBox
  382. {
  383. id: forceLayerViewCompatibilityModeCheckbox
  384. text: catalog.i18nc("@option:check", "Force layer view compatibility mode (restart required)")
  385. checked: boolCheck(UM.Preferences.getValue("view/force_layer_view_compatibility_mode"))
  386. onCheckedChanged: UM.Preferences.setValue("view/force_layer_view_compatibility_mode", checked)
  387. }
  388. }
  389. Item
  390. {
  391. //: Spacer
  392. height: UM.Theme.getSize("default_margin").height
  393. width: UM.Theme.getSize("default_margin").height
  394. }
  395. Label
  396. {
  397. font.bold: true
  398. text: catalog.i18nc("@label","Opening and saving files")
  399. }
  400. UM.TooltipArea
  401. {
  402. width: childrenRect.width
  403. height: childrenRect.height
  404. text: catalog.i18nc("@info:tooltip","Should models be scaled to the build volume if they are too large?")
  405. CheckBox
  406. {
  407. id: scaleToFitCheckbox
  408. text: catalog.i18nc("@option:check","Scale large models")
  409. checked: boolCheck(UM.Preferences.getValue("mesh/scale_to_fit"))
  410. onCheckedChanged: UM.Preferences.setValue("mesh/scale_to_fit", checked)
  411. }
  412. }
  413. UM.TooltipArea
  414. {
  415. width: childrenRect.width
  416. height: childrenRect.height
  417. text: catalog.i18nc("@info:tooltip","An model may appear extremely small if its unit is for example in meters rather than millimeters. Should these models be scaled up?")
  418. CheckBox
  419. {
  420. id: scaleTinyCheckbox
  421. text: catalog.i18nc("@option:check","Scale extremely small models")
  422. checked: boolCheck(UM.Preferences.getValue("mesh/scale_tiny_meshes"))
  423. onCheckedChanged: UM.Preferences.setValue("mesh/scale_tiny_meshes", checked)
  424. }
  425. }
  426. UM.TooltipArea
  427. {
  428. width: childrenRect.width
  429. height: childrenRect.height
  430. text: catalog.i18nc("@info:tooltip","Should models be selected after they are loaded?")
  431. CheckBox
  432. {
  433. id: selectModelsOnLoadCheckbox
  434. text: catalog.i18nc("@option:check","Select models when loaded")
  435. checked: boolCheck(UM.Preferences.getValue("cura/select_models_on_load"))
  436. onCheckedChanged: UM.Preferences.setValue("cura/select_models_on_load", checked)
  437. }
  438. }
  439. UM.TooltipArea
  440. {
  441. width: childrenRect.width
  442. height: childrenRect.height
  443. text: catalog.i18nc("@info:tooltip", "Should a prefix based on the printer name be added to the print job name automatically?")
  444. CheckBox
  445. {
  446. id: prefixJobNameCheckbox
  447. text: catalog.i18nc("@option:check", "Add machine prefix to job name")
  448. checked: boolCheck(UM.Preferences.getValue("cura/jobname_prefix"))
  449. onCheckedChanged: UM.Preferences.setValue("cura/jobname_prefix", checked)
  450. }
  451. }
  452. UM.TooltipArea
  453. {
  454. width: childrenRect.width
  455. height: childrenRect.height
  456. text: catalog.i18nc("@info:tooltip", "Should a summary be shown when saving a project file?")
  457. CheckBox
  458. {
  459. text: catalog.i18nc("@option:check", "Show summary dialog when saving project")
  460. checked: boolCheck(UM.Preferences.getValue("cura/dialog_on_project_save"))
  461. onCheckedChanged: UM.Preferences.setValue("cura/dialog_on_project_save", checked)
  462. }
  463. }
  464. UM.TooltipArea
  465. {
  466. width: childrenRect.width
  467. height: childrenRect.height
  468. text: catalog.i18nc("@info:tooltip", "Default behavior when opening a project file")
  469. Column
  470. {
  471. spacing: 4 * screenScaleFactor
  472. Label
  473. {
  474. text: catalog.i18nc("@window:text", "Default behavior when opening a project file: ")
  475. }
  476. ComboBox
  477. {
  478. id: choiceOnOpenProjectDropDownButton
  479. width: 200 * screenScaleFactor
  480. model: ListModel
  481. {
  482. id: openProjectOptionModel
  483. Component.onCompleted:
  484. {
  485. append({ text: catalog.i18nc("@option:openProject", "Always ask me this"), code: "always_ask" })
  486. append({ text: catalog.i18nc("@option:openProject", "Always open as a project"), code: "open_as_project" })
  487. append({ text: catalog.i18nc("@option:openProject", "Always import models"), code: "open_as_model" })
  488. }
  489. }
  490. currentIndex:
  491. {
  492. var index = 0;
  493. var currentChoice = UM.Preferences.getValue("cura/choice_on_open_project");
  494. for (var i = 0; i < model.count; ++i)
  495. {
  496. if (model.get(i).code == currentChoice)
  497. {
  498. index = i;
  499. break;
  500. }
  501. }
  502. return index;
  503. }
  504. onActivated: UM.Preferences.setValue("cura/choice_on_open_project", model.get(index).code)
  505. }
  506. }
  507. }
  508. Item
  509. {
  510. //: Spacer
  511. height: UM.Theme.getSize("default_margin").height
  512. width: UM.Theme.getSize("default_margin").width
  513. }
  514. UM.TooltipArea
  515. {
  516. width: childrenRect.width;
  517. height: childrenRect.height;
  518. text: catalog.i18nc("@info:tooltip", "When you have made changes to a profile and switched to a different one, a dialog will be shown asking whether you want to keep your modifications or not, or you can choose a default behaviour and never show that dialog again.")
  519. Column
  520. {
  521. spacing: 4 * screenScaleFactor
  522. Label
  523. {
  524. font.bold: true
  525. text: catalog.i18nc("@label", "Profiles")
  526. }
  527. Label
  528. {
  529. text: catalog.i18nc("@window:text", "Default behavior for changed setting values when switching to a different profile: ")
  530. }
  531. ComboBox
  532. {
  533. id: choiceOnProfileOverrideDropDownButton
  534. width: 200 * screenScaleFactor
  535. model: ListModel
  536. {
  537. id: discardOrKeepProfileListModel
  538. Component.onCompleted:
  539. {
  540. append({ text: catalog.i18nc("@option:discardOrKeep", "Always ask me this"), code: "always_ask" })
  541. append({ text: catalog.i18nc("@option:discardOrKeep", "Always discard changed settings"), code: "always_discard" })
  542. append({ text: catalog.i18nc("@option:discardOrKeep", "Always transfer changed settings to new profile"), code: "always_keep" })
  543. }
  544. }
  545. currentIndex:
  546. {
  547. var index = 0;
  548. var code = UM.Preferences.getValue("cura/choice_on_profile_override");
  549. for (var i = 0; i < model.count; ++i)
  550. {
  551. if (model.get(i).code == code)
  552. {
  553. index = i;
  554. break;
  555. }
  556. }
  557. return index;
  558. }
  559. onActivated: UM.Preferences.setValue("cura/choice_on_profile_override", model.get(index).code)
  560. }
  561. }
  562. }
  563. Item
  564. {
  565. //: Spacer
  566. height: UM.Theme.getSize("default_margin").height
  567. width: UM.Theme.getSize("default_margin").height
  568. }
  569. Label
  570. {
  571. font.bold: true
  572. visible: checkUpdatesCheckbox.visible || sendDataCheckbox.visible
  573. text: catalog.i18nc("@label","Privacy")
  574. }
  575. UM.TooltipArea
  576. {
  577. visible: pluginExistsAndEnabled("UpdateChecker")
  578. width: childrenRect.width
  579. height: visible ? childrenRect.height : 0
  580. text: catalog.i18nc("@info:tooltip","Should Cura check for updates when the program is started?")
  581. CheckBox
  582. {
  583. id: checkUpdatesCheckbox
  584. text: catalog.i18nc("@option:check","Check for updates on start")
  585. checked: boolCheck(UM.Preferences.getValue("info/automatic_update_check"))
  586. onCheckedChanged: UM.Preferences.setValue("info/automatic_update_check", checked)
  587. }
  588. }
  589. UM.TooltipArea
  590. {
  591. visible: pluginExistsAndEnabled("SliceInfoPlugin")
  592. width: childrenRect.width
  593. height: visible ? childrenRect.height : 0
  594. text: catalog.i18nc("@info:tooltip","Should anonymous data about your print be sent to Ultimaker? Note, no models, IP addresses or other personally identifiable information is sent or stored.")
  595. CheckBox
  596. {
  597. id: sendDataCheckbox
  598. text: catalog.i18nc("@option:check","Send (anonymous) print information")
  599. checked: boolCheck(UM.Preferences.getValue("info/send_slice_info"))
  600. onCheckedChanged: UM.Preferences.setValue("info/send_slice_info", checked)
  601. }
  602. Button
  603. {
  604. id: showMoreInfo
  605. anchors.top: sendDataCheckbox.bottom
  606. text: catalog.i18nc("@action:button", "More information")
  607. onClicked:
  608. {
  609. CuraApplication.showMoreInformationDialogForAnonymousDataCollection();
  610. }
  611. }
  612. }
  613. Item
  614. {
  615. //: Spacer
  616. height: UM.Theme.getSize("default_margin").height
  617. width: UM.Theme.getSize("default_margin").height
  618. }
  619. Label
  620. {
  621. font.bold: true
  622. text: catalog.i18nc("@label","Experimental")
  623. }
  624. UM.TooltipArea
  625. {
  626. width: childrenRect.width
  627. height: childrenRect.height
  628. text: catalog.i18nc("@info:tooltip","Use multi build plate functionality")
  629. CheckBox
  630. {
  631. id: useMultiBuildPlateCheckbox
  632. text: catalog.i18nc("@option:check","Use multi build plate functionality (restart required)")
  633. checked: boolCheck(UM.Preferences.getValue("cura/use_multi_build_plate"))
  634. onCheckedChanged: UM.Preferences.setValue("cura/use_multi_build_plate", checked)
  635. }
  636. }
  637. Connections
  638. {
  639. target: UM.Preferences
  640. onPreferenceChanged:
  641. {
  642. sendDataCheckbox.checked = boolCheck(UM.Preferences.getValue("info/send_slice_info"))
  643. }
  644. }
  645. }
  646. }
  647. }