diff --git a/plugins/ImageReader/ConfigUI.qml b/plugins/ImageReader/ConfigUI.qml index 893f8e248c..65374702ab 100644 --- a/plugins/ImageReader/ConfigUI.qml +++ b/plugins/ImageReader/ConfigUI.qml @@ -156,11 +156,10 @@ UM.Dialog anchors.verticalCenter: parent.verticalCenter } - Rectangle { + Item { width: 180 height: 20 - Layout.fillWidth:true - color: "transparent" + Layout.fillWidth: true Slider { id: smoothing diff --git a/plugins/LayerView/LayerView.qml b/plugins/LayerView/LayerView.qml index fef0c52c12..82728d2a1e 100644 --- a/plugins/LayerView/LayerView.qml +++ b/plugins/LayerView/LayerView.qml @@ -41,8 +41,9 @@ Item width: valueLabel.width + UM.Theme.getSize("default_margin").width Behavior on height { NumberAnimation { duration: 50; } } - border.width: UM.Theme.getSize("default_lining").width; - border.color: UM.Theme.getColor("slider_groove_border"); + border.width: UM.Theme.getSize("default_lining").width + border.color: UM.Theme.getColor("slider_groove_border") + color: UM.Theme.getColor("tool_panel_background") visible: UM.LayerView.getLayerActivity && Printer.getPlatformActivity ? true : false diff --git a/resources/definitions/rigidbot.def.json b/resources/definitions/rigidbot.def.json index 9dbde35921..9877b546b4 100644 --- a/resources/definitions/rigidbot.def.json +++ b/resources/definitions/rigidbot.def.json @@ -39,7 +39,7 @@ "default_value": "RepRap (Marlin/Sprinter)" }, "machine_start_gcode": { - "default_value": ";Basic settings: Layer height: {layer_height} Walls: {wall_thickness} Fill: {infill_sparse_density}\n;M190 S{material_bed_temperature} ;Uncomment to add your own bed temperature line\n;M109 S{material_print_temperature} ;Uncomment to add your own temperature line\nG21 ;metric values\nG90 ;absolute positioning\nM82 ;set extruder to absolute mode\nM107 ;start with the fan off\nG28 X0 Y0 ;move X/Y to min endstops\nG28 Z0 ;move Z to min endstops\nM205 X8 ;X/Y Jerk settings\nG1 Z15.0 F{travel_speed} ;move the platform down 15mm\nG92 E0 ;zero the extruded length\nG1 F200 E7 ;extrude 3mm of feed stock\nG92 E0 ;zero the extruded length again\nG1 F{speed_travel}\n;Put printing message on LCD screen\nM117 Rigibot Printing..." + "default_value": ";Basic settings: Layer height: {layer_height} Walls: {wall_thickness} Fill: {infill_sparse_density}\n;M190 S{material_bed_temperature} ;Uncomment to add your own bed temperature line\n;M109 S{material_print_temperature} ;Uncomment to add your own temperature line\nG21 ;metric values\nG90 ;absolute positioning\nM82 ;set extruder to absolute mode\nM107 ;start with the fan off\nG28 X0 Y0 ;move X/Y to min endstops\nG28 Z0 ;move Z to min endstops\nM205 X8 ;X/Y Jerk settings\nG1 Z15.0 F{speed_travel} ;move the platform down 15mm\nG92 E0 ;zero the extruded length\nG1 F200 E7 ;extrude 3mm of feed stock\nG92 E0 ;zero the extruded length again\nG1 F{speed_travel}\n;Put printing message on LCD screen\nM117 Rigibot Printing..." }, "machine_end_gcode": { "default_value": ";End GCode\nM104 S0 ;extruder heater off\nM140 S0 ;heated bed heater off (if you have it)\nG91 ;relative positioning\nG1 E-1 F300 ;retract the filament a bit before lifting the nozzle, to release some of the pressure\nG1 Z+10 E-1 X-20 Y-20 F{speed_travel} ;move Z up a bit and retract filament even more\nG28 X0 Y0 ;move X/Y to min endstops, so the head is out of the way\nG1 Y230 F3000 ;move Y so the head is out of the way and Plate is moved forward\nM84 ;steppers off\nG90 ;absolute positioning" diff --git a/resources/i18n/ptbr/cura.po b/resources/i18n/ptbr/cura.po index 0317eb209d..56ab5c9a8e 100644 --- a/resources/i18n/ptbr/cura.po +++ b/resources/i18n/ptbr/cura.po @@ -1,9 +1,9 @@ -# Portuguese translation for Cura. -# Copyright (C) 2016, 2017 -# This file is distributed under the same license as the Cura package. -# FIRST AUTHOR , 2016. -# SECOND AUTHOR , 2017. -# +# Portuguese translation for Cura. +# Copyright (C) 2016, 2017 +# This file is distributed under the same license as the Cura package. +# FIRST AUTHOR , 2016. +# SECOND AUTHOR , 2017. +# msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" @@ -16,6 +16,7 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n > 1);\n" #: /home/ruben/Projects/Cura/plugins/MachineSettingsAction/__init__.py:12 msgctxt "@label" @@ -1223,11 +1224,11 @@ msgctxt "@label" msgid "Extruder Temperature: %1/%2°C" msgstr "Temperatura do Extrusor: %1/%2°C" -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# #: /home/ruben/Projects/Cura/plugins/Doodle3D-cura-plugin/ControlWindow.qml:45 msgctxt "@label" msgid "" diff --git a/resources/i18n/ptbr/fdmextruder.def.json.po b/resources/i18n/ptbr/fdmextruder.def.json.po index 7d7b55867e..b836faeb49 100644 --- a/resources/i18n/ptbr/fdmextruder.def.json.po +++ b/resources/i18n/ptbr/fdmextruder.def.json.po @@ -11,6 +11,7 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n > 1);\n" #: fdmextruder.def.json msgctxt "machine_settings label" diff --git a/resources/i18n/ptbr/fdmprinter.def.json.po b/resources/i18n/ptbr/fdmprinter.def.json.po index 6cc527b11b..a24be84e72 100644 --- a/resources/i18n/ptbr/fdmprinter.def.json.po +++ b/resources/i18n/ptbr/fdmprinter.def.json.po @@ -10,6 +10,7 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n > 1);\n" #: fdmprinter.def.json msgctxt "machine_settings label" diff --git a/resources/qml/AddMachineDialog.qml b/resources/qml/AddMachineDialog.qml index 8a97a23bb3..756badc4d2 100644 --- a/resources/qml/AddMachineDialog.qml +++ b/resources/qml/AddMachineDialog.qml @@ -74,10 +74,8 @@ UM.Dialog width: machineList.width style: ButtonStyle { - background: Rectangle + background: Item { - border.width: 0 - color: "transparent"; height: UM.Theme.getSize("standard_list_lineheight").height width: machineList.width } diff --git a/resources/qml/JobSpecs.qml b/resources/qml/JobSpecs.qml index 00d22ae8a8..70c306f1bc 100644 --- a/resources/qml/JobSpecs.qml +++ b/resources/qml/JobSpecs.qml @@ -9,7 +9,7 @@ import QtQuick.Layouts 1.1 import UM 1.1 as UM import Cura 1.0 as Cura -Rectangle { +Item { id: base property bool activity: Printer.getPlatformActivity @@ -29,7 +29,6 @@ Rectangle { property variant printMaterialCosts: PrintInformation.materialCosts height: childrenRect.height - color: "transparent" Connections { @@ -84,9 +83,8 @@ Rectangle { } style: ButtonStyle { - background: Rectangle + background: Item { - color: "transparent" UM.RecolorImage { width: UM.Theme.getSize("save_button_specs_icons").width; diff --git a/resources/qml/Legend.qml b/resources/qml/Legend.qml index 353747ef67..94eeb1e903 100644 --- a/resources/qml/Legend.qml +++ b/resources/qml/Legend.qml @@ -9,14 +9,13 @@ import QtQuick.Layouts 1.1 import UM 1.1 as UM import Cura 1.0 as Cura -Rectangle { +Item { id: base UM.I18nCatalog { id: catalog; name:"cura"} width: childrenRect.width height: childrenRect.height - color: "transparent" Connections { diff --git a/resources/qml/MonitorButton.qml b/resources/qml/MonitorButton.qml index 4a68e532d1..1b8f36b264 100644 --- a/resources/qml/MonitorButton.qml +++ b/resources/qml/MonitorButton.qml @@ -10,7 +10,7 @@ import QtQuick.Layouts 1.1 import UM 1.1 as UM import Cura 1.0 as Cura -Rectangle +Item { id: base; UM.I18nCatalog { id: catalog; name:"cura"} @@ -20,7 +20,6 @@ Rectangle property real progress: printerConnected ? Cura.MachineManager.printerOutputDevices[0].progress : 0 property int backendState: UM.Backend.state - property bool showProgress: { // determine if we need to show the progress bar + percentage if(!printerConnected || !printerAcceptsCommands) { diff --git a/resources/qml/Preferences/GeneralPage.qml b/resources/qml/Preferences/GeneralPage.qml index c3e4d5d846..6d3cc9c1e7 100644 --- a/resources/qml/Preferences/GeneralPage.qml +++ b/resources/qml/Preferences/GeneralPage.qml @@ -97,6 +97,7 @@ UM.PreferencesPage append({ text: "Français", code: "fr" }) append({ text: "Italiano", code: "it" }) append({ text: "Nederlands", code: "nl" }) + append({ text: "Português do Brasil", code: "ptbr" }) append({ text: "Русский", code: "ru" }) append({ text: "Türkçe", code: "tr" }) } diff --git a/resources/qml/SaveButton.qml b/resources/qml/SaveButton.qml index 323123e9a7..2b435aad1b 100644 --- a/resources/qml/SaveButton.qml +++ b/resources/qml/SaveButton.qml @@ -8,7 +8,7 @@ import QtQuick.Layouts 1.1 import UM 1.1 as UM -Rectangle { +Item { id: base; UM.I18nCatalog { id: catalog; name:"cura"} @@ -53,7 +53,7 @@ Rectangle { text: statusText; } - Rectangle{ + Rectangle { id: progressBar width: parent.width - 2 * UM.Theme.getSize("default_margin").width height: UM.Theme.getSize("progressbar").height @@ -64,7 +64,7 @@ Rectangle { radius: UM.Theme.getSize("progressbar_radius").width color: UM.Theme.getColor("progressbar_background") - Rectangle{ + Rectangle { width: Math.max(parent.width * base.progress) height: parent.height color: UM.Theme.getColor("progressbar_control") @@ -73,7 +73,7 @@ Rectangle { } } - Rectangle{ + Item { id: saveRow width: base.width height: saveToButton.height diff --git a/resources/qml/Settings/SettingItem.qml b/resources/qml/Settings/SettingItem.qml index 7b50809baa..65e8b7e1c1 100644 --- a/resources/qml/Settings/SettingItem.qml +++ b/resources/qml/Settings/SettingItem.qml @@ -145,8 +145,6 @@ Item { height: parent.height; width: height; - backgroundColor: UM.Theme.getColor("setting_control"); - hoverBackgroundColor: UM.Theme.getColor("setting_control") color: UM.Theme.getColor("setting_control_button") hoverColor: UM.Theme.getColor("setting_control_button") @@ -173,8 +171,6 @@ Item { height: parent.height; width: height; - backgroundColor: UM.Theme.getColor("setting_control"); - hoverBackgroundColor: UM.Theme.getColor("setting_control_highlight") color: UM.Theme.getColor("setting_control_button") hoverColor: UM.Theme.getColor("setting_control_button_hover") @@ -278,8 +274,6 @@ Item { } } - backgroundColor: UM.Theme.getColor("setting_control"); - hoverBackgroundColor: UM.Theme.getColor("setting_control_highlight") color: UM.Theme.getColor("setting_control_button") hoverColor: UM.Theme.getColor("setting_control_button_hover") diff --git a/resources/qml/Sidebar.qml b/resources/qml/Sidebar.qml index d27569c6b8..148606679f 100644 --- a/resources/qml/Sidebar.qml +++ b/resources/qml/Sidebar.qml @@ -175,6 +175,9 @@ Rectangle height: UM.Theme.getSize("sidebar_header").height onClicked: monitoringPrint = false iconSource: UM.Theme.getIcon("tab_settings"); + property color overlayColor: "transparent" + property string overlayIconSource: "" + checkable: true checked: !monitoringPrint exclusiveGroup: sidebarHeaderBarGroup @@ -203,15 +206,53 @@ Rectangle width: height height: UM.Theme.getSize("sidebar_header").height onClicked: monitoringPrint = true - iconSource: { - if(!printerConnected) - return UM.Theme.getIcon("tab_monitor"); - else if(!printerAcceptsCommands) - return UM.Theme.getIcon("tab_monitor_unknown"); + iconSource: printerConnected ? UM.Theme.getIcon("tab_monitor_with_status") : UM.Theme.getIcon("tab_monitor") + property color overlayColor: + { + if(!printerAcceptsCommands) + { + return UM.Theme.getColor("status_unknown"); + } if(Cura.MachineManager.printerOutputDevices[0].printerState == "maintenance") { - return UM.Theme.getIcon("tab_monitor_busy"); + return UM.Theme.getColor("status_busy"); + } + switch(Cura.MachineManager.printerOutputDevices[0].jobState) + { + case "printing": + case "pre_print": + case "wait_cleanup": + case "pausing": + case "resuming": + return UM.Theme.getColor("status_busy"); + case "ready": + case "": + return UM.Theme.getColor("status_ready"); + case "paused": + return UM.Theme.getColor("status_paused"); + case "error": + return UM.Theme.getColor("status_stopped"); + case "offline": + return UM.Theme.getColor("status_offline"); + default: + return UM.Theme.getColor("text_reversed"); + } + } + property string overlayIconSource: + { + if(!printerConnected) + { + return ""; + } + else if(!printerAcceptsCommands) + { + return UM.Theme.getIcon("tab_status_unknown"); + } + + if(Cura.MachineManager.printerOutputDevices[0].printerState == "maintenance") + { + return UM.Theme.getIcon("tab_status_busy"); } switch(Cura.MachineManager.printerOutputDevices[0].jobState) @@ -219,20 +260,23 @@ Rectangle case "printing": case "pre_print": case "wait_cleanup": - return UM.Theme.getIcon("tab_monitor_busy"); + case "pausing": + case "resuming": + return UM.Theme.getIcon("tab_status_busy"); case "ready": case "": - return UM.Theme.getIcon("tab_monitor_connected") + return UM.Theme.getIcon("tab_status_connected") case "paused": - return UM.Theme.getIcon("tab_monitor_paused") + return UM.Theme.getIcon("tab_status_paused") case "error": - return UM.Theme.getIcon("tab_monitor_stopped") + return UM.Theme.getIcon("tab_status_stopped") case "offline": - return UM.Theme.getIcon("tab_monitor_offline") + return UM.Theme.getIcon("tab_status_offline") default: - return UM.Theme.getIcon("tab_monitor") + return "" } } + checkable: true checked: monitoringPrint exclusiveGroup: sidebarHeaderBarGroup diff --git a/resources/qml/SidebarHeader.qml b/resources/qml/SidebarHeader.qml index 3a87d51dcf..93d4e9d6f2 100644 --- a/resources/qml/SidebarHeader.qml +++ b/resources/qml/SidebarHeader.qml @@ -201,7 +201,7 @@ Column color: UM.Theme.getColor("text"); } - Rectangle + Item { anchors.verticalCenter: parent.verticalCenter diff --git a/resources/qml/SidebarSimple.qml b/resources/qml/SidebarSimple.qml index e40e114e0e..61cc23d403 100644 --- a/resources/qml/SidebarSimple.qml +++ b/resources/qml/SidebarSimple.qml @@ -25,7 +25,7 @@ Item Component.onDestruction: PrintInformation.enabled = false UM.I18nCatalog { id: catalog; name:"cura"} - Rectangle + Item { id: infillCellLeft anchors.top: parent.top @@ -216,7 +216,7 @@ Item } } - Rectangle + Item { id: helpersCell anchors.top: infillCellRight.bottom @@ -461,7 +461,7 @@ Item supportExtruderCombobox.updateCurrentColor(); } - Rectangle + Item { id: tipsCell anchors.top: helpersCell.bottom diff --git a/resources/themes/cura/icons/tab_monitor.svg b/resources/themes/cura/icons/tab_monitor.svg index 9658a6af5f..2677cec6e2 100644 --- a/resources/themes/cura/icons/tab_monitor.svg +++ b/resources/themes/cura/icons/tab_monitor.svg @@ -1,3 +1,3 @@ - + diff --git a/resources/themes/cura/icons/tab_monitor_busy.svg b/resources/themes/cura/icons/tab_monitor_busy.svg deleted file mode 100644 index 84ab2e23f1..0000000000 --- a/resources/themes/cura/icons/tab_monitor_busy.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/resources/themes/cura/icons/tab_monitor_connected.svg b/resources/themes/cura/icons/tab_monitor_connected.svg deleted file mode 100644 index ef2bfbf8f5..0000000000 --- a/resources/themes/cura/icons/tab_monitor_connected.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/resources/themes/cura/icons/tab_monitor_offline.svg b/resources/themes/cura/icons/tab_monitor_offline.svg deleted file mode 100644 index 4a16d5a559..0000000000 --- a/resources/themes/cura/icons/tab_monitor_offline.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/resources/themes/cura/icons/tab_monitor_stopped.svg b/resources/themes/cura/icons/tab_monitor_stopped.svg deleted file mode 100644 index 6f63c7c2db..0000000000 --- a/resources/themes/cura/icons/tab_monitor_stopped.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/resources/themes/cura/icons/tab_monitor_unknown.svg b/resources/themes/cura/icons/tab_monitor_unknown.svg deleted file mode 100644 index 3d798c7e27..0000000000 --- a/resources/themes/cura/icons/tab_monitor_unknown.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/resources/themes/cura/icons/tab_monitor_paused.svg b/resources/themes/cura/icons/tab_monitor_with_status.svg similarity index 74% rename from resources/themes/cura/icons/tab_monitor_paused.svg rename to resources/themes/cura/icons/tab_monitor_with_status.svg index 10cdc9a2a3..dc3b373313 100644 --- a/resources/themes/cura/icons/tab_monitor_paused.svg +++ b/resources/themes/cura/icons/tab_monitor_with_status.svg @@ -1,5 +1,4 @@ - - - + + diff --git a/resources/themes/cura/icons/tab_status_busy.svg b/resources/themes/cura/icons/tab_status_busy.svg new file mode 100644 index 0000000000..cb72fdd623 --- /dev/null +++ b/resources/themes/cura/icons/tab_status_busy.svg @@ -0,0 +1,4 @@ + + + diff --git a/resources/themes/cura/icons/tab_status_connected.svg b/resources/themes/cura/icons/tab_status_connected.svg new file mode 100644 index 0000000000..16ec7d7523 --- /dev/null +++ b/resources/themes/cura/icons/tab_status_connected.svg @@ -0,0 +1,4 @@ + + + diff --git a/resources/themes/cura/icons/tab_status_offline.svg b/resources/themes/cura/icons/tab_status_offline.svg new file mode 100644 index 0000000000..850ca1bc03 --- /dev/null +++ b/resources/themes/cura/icons/tab_status_offline.svg @@ -0,0 +1,4 @@ + + + diff --git a/resources/themes/cura/icons/tab_status_paused.svg b/resources/themes/cura/icons/tab_status_paused.svg new file mode 100644 index 0000000000..feffb7894c --- /dev/null +++ b/resources/themes/cura/icons/tab_status_paused.svg @@ -0,0 +1,4 @@ + + + diff --git a/resources/themes/cura/icons/tab_status_stopped.svg b/resources/themes/cura/icons/tab_status_stopped.svg new file mode 100644 index 0000000000..86386d3a6b --- /dev/null +++ b/resources/themes/cura/icons/tab_status_stopped.svg @@ -0,0 +1,51 @@ + + + + + + image/svg+xml + + + + + + + + diff --git a/resources/themes/cura/icons/tab_status_unknown.svg b/resources/themes/cura/icons/tab_status_unknown.svg new file mode 100644 index 0000000000..1033b39a4c --- /dev/null +++ b/resources/themes/cura/icons/tab_status_unknown.svg @@ -0,0 +1,4 @@ + + + diff --git a/resources/themes/cura/styles.qml b/resources/themes/cura/styles.qml index a57f60b387..64b4436622 100644 --- a/resources/themes/cura/styles.qml +++ b/resources/themes/cura/styles.qml @@ -100,12 +100,24 @@ QtObject { } label: Item { - Image { - anchors.centerIn: parent; + UM.RecolorImage { + color: UM.Theme.getColor("text_reversed") + anchors.centerIn: parent opacity: !control.enabled ? 0.2 : 1.0 - source: control.iconSource; - width: Theme.getSize("button_icon").width; - height: Theme.getSize("button_icon").height; + source: control.iconSource + width: Theme.getSize("button_icon").width + height: Theme.getSize("button_icon").height + + sourceSize: Theme.getSize("button_icon") + } + UM.RecolorImage { + visible: control.overlayIconSource != "" + color: control.overlayColor + anchors.centerIn: parent + opacity: !control.enabled ? 0.2 : 1.0 + source: control.overlayIconSource + width: Theme.getSize("button_icon").width + height: Theme.getSize("button_icon").height sourceSize: Theme.getSize("button_icon") } diff --git a/resources/themes/cura/theme.json b/resources/themes/cura/theme.json index 31caeeabd4..23ebacd7f9 100644 --- a/resources/themes/cura/theme.json +++ b/resources/themes/cura/theme.json @@ -193,6 +193,7 @@ "status_busy": [12, 169, 227, 255], "status_paused": [255, 140, 0, 255], "status_stopped": [236, 82, 80, 255], + "status_unknown": [127, 127, 127, 255], "disabled_axis": [127, 127, 127, 255], "x_axis": [255, 0, 0, 255],