diff --git a/plugins/PrepareStage/PrepareMenu.qml b/plugins/PrepareStage/PrepareMenu.qml index 82f61da069..2d3814309e 100644 --- a/plugins/PrepareStage/PrepareMenu.qml +++ b/plugins/PrepareStage/PrepareMenu.qml @@ -23,16 +23,14 @@ Item { left: parent.left right: parent.right - leftMargin: UM.Theme.getSize("wide_margin").width - rightMargin: UM.Theme.getSize("wide_margin").width + leftMargin: UM.Theme.getSize("wide_margin").width * 2 + rightMargin: UM.Theme.getSize("wide_margin").width * 2 } // Item to ensure that all of the buttons are nicely centered. Item { - anchors.horizontalCenter: parent.horizontalCenter - width: parent.width - 2 * UM.Theme.getSize("wide_margin").width - height: parent.height + anchors.fill: parent RowLayout { diff --git a/plugins/PreviewStage/PreviewMenu.qml b/plugins/PreviewStage/PreviewMenu.qml index c6f9d64756..9e039896c6 100644 --- a/plugins/PreviewStage/PreviewMenu.qml +++ b/plugins/PreviewStage/PreviewMenu.qml @@ -24,17 +24,15 @@ Item { left: parent.left right: parent.right - leftMargin: UM.Theme.getSize("wide_margin").width - rightMargin: UM.Theme.getSize("wide_margin").width + leftMargin: UM.Theme.getSize("wide_margin").width * 2 + rightMargin: UM.Theme.getSize("wide_margin").width * 2 } Row { id: stageMenuRow - anchors.horizontalCenter: parent.horizontalCenter - width: parent.width - 2 * UM.Theme.getSize("wide_margin").width - height: parent.height + anchors.fill: parent // This is a trick to make sure that the borders of the two adjacent buttons' borders overlap. Otherwise // there will be double border (one from each button) spacing: -UM.Theme.getSize("default_lining").width @@ -52,7 +50,7 @@ Item { id: viewPanel height: parent.height - width: source != "" ? (previewMenu.width - viewsSelector.width - printSetupSelectorItem.width) : 0 + width: source != "" ? (parent.width - viewsSelector.width - printSetupSelectorItem.width) : 0 source: UM.Controller.activeView != null && UM.Controller.activeView.stageMenuComponent != null ? UM.Controller.activeView.stageMenuComponent : "" } diff --git a/plugins/UM3NetworkPrinting/resources/qml/CameraButton.qml b/plugins/UM3NetworkPrinting/resources/qml/CameraButton.qml index 2e3d17ceb0..8dca61ec38 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/CameraButton.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/CameraButton.qml @@ -1,23 +1,26 @@ -// Copyright (c) 2019 Ultimaker B.V. +// Copyright (c) 2021 Ultimaker B.V. // Cura is released under the terms of the LGPLv3 or higher. import QtQuick 2.3 -import QtQuick.Controls 1.4 +import QtQuick.Controls 2.4 import QtQuick.Controls.Styles 1.3 import UM 1.3 as UM import Cura 1.0 as Cura -Rectangle +Button { - id: base - - property var enabled: true - property var iconSource: null - color: enabled ? UM.Theme.getColor("monitor_icon_primary") : UM.Theme.getColor("monitor_icon_disabled") - height: width - radius: Math.round(0.5 * width) - width: 24 * screenScaleFactor + width: UM.Theme.getSize("button").width * 0.75 //Matching the size of the content of tool buttons. + height: UM.Theme.getSize("button").height * 0.75 + + hoverEnabled: true + + background: Rectangle + { + anchors.fill: parent + radius: 0.5 * width + color: parent.enabled ? (parent.hovered ? UM.Theme.getColor("monitor_secondary_button_hover") : "transparent") : UM.Theme.getColor("monitor_icon_disabled") + } UM.RecolorImage { @@ -27,30 +30,21 @@ Rectangle horizontalCenter: parent.horizontalCenter verticalCenter: parent.verticalCenter } - color: UM.Theme.getColor("monitor_icon_accent") + color: UM.Theme.getColor("primary") height: width source: iconSource width: Math.round(parent.width / 2) } - MouseArea + onClicked: { - id: clickArea - anchors.fill: parent - hoverEnabled: base.enabled - onClicked: + if (OutputDevice.activeCameraUrl != "") { - if (base.enabled) - { - if (OutputDevice.activeCameraUrl != "") - { - OutputDevice.setActiveCameraUrl("") - } - else - { - OutputDevice.setActiveCameraUrl(modelData.cameraUrl) - } - } + OutputDevice.setActiveCameraUrl("") + } + else + { + OutputDevice.setActiveCameraUrl(modelData.cameraUrl) } } } diff --git a/resources/definitions/creasee_cs20.def.json b/resources/definitions/creasee_cs20.def.json new file mode 100644 index 0000000000..ab30f3dd1c --- /dev/null +++ b/resources/definitions/creasee_cs20.def.json @@ -0,0 +1,32 @@ +{ + "version": 2, + "name": "Creasee CS20", + "inherits": "fdmprinter", + "metadata": { + "visible": true, + "manufacturer": "Creasee", + "machine_extruder_trains": + { + "0": "creasee_extruder_0" + } + }, + + "overrides": { + "machine_name": { "default_value": "Creasee CS20" }, + "machine_width": { + "default_value": 220 + }, + "machine_depth": { + "default_value": 220 + }, + "machine_height": { + "default_value": 250 + }, + "machine_start_gcode": { + "default_value": "G28 ;Home\nG1 Z15.0 F2000 ;Move the platform" + }, + "machine_end_gcode": { + "default_value": "M104 S0\nM140 S0\nG92 E0\nG1 E-10 F2000\nG28 X0 Y0\nM84" + } + } +} diff --git a/resources/definitions/creasee_cs30.def.json b/resources/definitions/creasee_cs30.def.json new file mode 100644 index 0000000000..7d6a5090bb --- /dev/null +++ b/resources/definitions/creasee_cs30.def.json @@ -0,0 +1,32 @@ +{ + "version": 2, + "name": "Creasee CS30", + "inherits": "fdmprinter", + "metadata": { + "visible": true, + "manufacturer": "Creasee", + "machine_extruder_trains": + { + "0": "creasee_extruder_1" + } + }, + + "overrides": { + "machine_name": { "default_value": "Creasee CS30" }, + "machine_width": { + "default_value": 300 + }, + "machine_depth": { + "default_value": 300 + }, + "machine_height": { + "default_value": 400 + }, + "machine_start_gcode": { + "default_value": "G28 ;Home\nG1 Z15.0 F2000 ;Move the platform" + }, + "machine_end_gcode": { + "default_value": "M104 S0\nM140 S0\nG92 E0\nG1 E-10 F2000\nG28 X0 Y0\nM84" + } + } +} diff --git a/resources/definitions/dagoma_disco.def.json b/resources/definitions/dagoma_disco.def.json index bf098b8b4a..89773d9c0e 100644 --- a/resources/definitions/dagoma_disco.def.json +++ b/resources/definitions/dagoma_disco.def.json @@ -73,6 +73,7 @@ "machine_steps_per_mm_x": { "default_value": 80 }, "machine_steps_per_mm_y": { "default_value": 80 }, "machine_steps_per_mm_z": { "default_value": 2560 }, - "machine_steps_per_mm_e": { "default_value": 98 } + "machine_steps_per_mm_e": { "default_value": 98 }, + "speed_z_hop": {"default_value": 4} } } diff --git a/resources/definitions/maker_made_300x.def.json b/resources/definitions/maker_made_300x.def.json index 9651aaf5f3..ae112af5d1 100644 --- a/resources/definitions/maker_made_300x.def.json +++ b/resources/definitions/maker_made_300x.def.json @@ -96,7 +96,6 @@ "speed_travel": {"value": 150}, "speed_layer_0": {"value": 10}, "speed_travel_layer_0": {"value": 50}, - "machine_max_feedrate_z": {"value": 0}, "speed_slowdown_layers": {"value": 2}, "speed_equalize_flow_enabled": {"value": false }, "acceleration_enabled": {"value": false }, diff --git a/resources/definitions/malyan_m200.def.json b/resources/definitions/malyan_m200.def.json index c853f8f772..e9980724cb 100644 --- a/resources/definitions/malyan_m200.def.json +++ b/resources/definitions/malyan_m200.def.json @@ -80,6 +80,7 @@ "retraction_amount" : { "default_value": 4.5}, "retraction_speed" : { "default_value": 40}, "coasting_enable": { "default_value": true }, - "prime_tower_enable": { "default_value": false} + "prime_tower_enable": { "default_value": false}, + "speed_z_hop": {"default_value": 1.5} } } diff --git a/resources/definitions/pbr3d_g1.def.json b/resources/definitions/pbr3d_g1.def.json new file mode 100644 index 0000000000..fbe1d5bfc6 --- /dev/null +++ b/resources/definitions/pbr3d_g1.def.json @@ -0,0 +1,45 @@ +{ + "version": 2, + "name": "PBR 3D Gen-I", + "inherits": "fdmprinter", + "metadata": { + "visible": true, + "author": "Kapil H. Sonone, Prof. Bahubali P. Fuladi", + "manufacturer": "PBR Research", + "file_formats": "text/x-gcode", + "platform": "pbr3d_g1_buildplate.stl", + "platform_offset": [0, -5, 0], + "machine_extruder_trains": + { + "0": "pbr3d_g1_extruder_0" + } + }, + + "overrides": { + "machine_name": { "default_value": "PBR 3D Gen-I" }, + "machine_heated_bed": { + "default_value": true + }, + "machine_width": { + "default_value": 200 + }, + "machine_height": { + "default_value": 200 + }, + "machine_depth": { + "default_value": 200 + }, + "machine_center_is_zero": { + "default_value": false + }, + "gantry_height": { + "value": "200" + }, + "machine_start_gcode": { + "default_value": "G28 ;Home\nG1 Z15.0 F6000 ;Move the Platform down 15mm\n;Prime the extruder\nG92 E0\nG1 F200 E3\nG92 E0" + }, + "machine_end_gcode": { + "default_value": "M104 S0\nM140 S0\n;Retract the Filament\nG92 E1\nG1 E-1 F300\nG28 X0 Y0\nM84" + } + } +} diff --git a/resources/definitions/printrbot_play.def.json b/resources/definitions/printrbot_play.def.json index e3c0c85d80..b1f7e72967 100644 --- a/resources/definitions/printrbot_play.def.json +++ b/resources/definitions/printrbot_play.def.json @@ -45,6 +45,7 @@ }, "machine_end_gcode": { "default_value": "M104 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+0.5 E-5 X-20 Y-20 F9000 ;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\nM84 ;steppers off\nG90 ;absolute positioning" - } + }, + "speed_z_hop": {"default_value": 5} } } diff --git a/resources/definitions/rigid3d_base.def.json b/resources/definitions/rigid3d_base.def.json index 76ed115a57..de6365c415 100644 --- a/resources/definitions/rigid3d_base.def.json +++ b/resources/definitions/rigid3d_base.def.json @@ -146,7 +146,8 @@ "adaptive_layer_height_variation_step": { "value": 0.04 }, "top_bottom_thickness": {"value": "layer_height_0 + layer_height * 3" }, - "wall_thickness": {"value": "line_width * 2" } + "wall_thickness": {"value": "line_width * 2" }, + "speed_z_hop": {"default_value": 8} } } \ No newline at end of file diff --git a/resources/definitions/tevo_tarantula.def.json b/resources/definitions/tevo_tarantula.def.json index eee773cd74..8efa9c4f87 100644 --- a/resources/definitions/tevo_tarantula.def.json +++ b/resources/definitions/tevo_tarantula.def.json @@ -47,6 +47,7 @@ "machine_max_acceleration_y": { "default_value": 2650 }, "acceleration_print": { "default_value": 2650 }, "machine_start_gcode": { "default_value": "G21 ;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\nG1 Z15.0 F9000 ;move the platform down 15mm\nG92 E0 ;zero the extruded length\nG1 F200 E3 ;extrude 3mm of feed stock\nG92 E0 ;zero the extruded length again\nG1 F9000\n;Put printing message on LCD screen\nM117 Printing..." }, - "machine_end_gcode": { "default_value": "M104 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+0.5 E-5 X-20 Y-20 F9000 ;move Z up a bit and retract filament even more\nG90 ;absolute positioning\nG1 X0 Y200 F3600 ;move extruder out of the way by moving the baseplate to the front for easier access to printed object\nM84 ;steppers off" } + "machine_end_gcode": { "default_value": "M104 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+0.5 E-5 X-20 Y-20 F9000 ;move Z up a bit and retract filament even more\nG90 ;absolute positioning\nG1 X0 Y200 F3600 ;move extruder out of the way by moving the baseplate to the front for easier access to printed object\nM84 ;steppers off" }, + "speed_z_hop": {"default_value": 3} } } diff --git a/resources/extruders/creasee_extruder_0.def.json b/resources/extruders/creasee_extruder_0.def.json new file mode 100644 index 0000000000..abefa6b1c8 --- /dev/null +++ b/resources/extruders/creasee_extruder_0.def.json @@ -0,0 +1,15 @@ +{ + "version": 2, + "name": "Extruder 1", + "inherits": "fdmextruder", + "metadata": { + "machine": "creasee_cs20", + "position": "0" + }, + + "overrides": { + "extruder_nr": { "default_value": 0 }, + "machine_nozzle_size": { "default_value": 0.4 }, + "material_diameter": { "default_value": 1.75 } + } +} diff --git a/resources/extruders/creasee_extruder_1.def.json b/resources/extruders/creasee_extruder_1.def.json new file mode 100644 index 0000000000..747e1c48f8 --- /dev/null +++ b/resources/extruders/creasee_extruder_1.def.json @@ -0,0 +1,15 @@ +{ + "version": 2, + "name": "Extruder 1", + "inherits": "fdmextruder", + "metadata": { + "machine": "creasee_cs30", + "position": "0" + }, + + "overrides": { + "extruder_nr": { "default_value": 0 }, + "machine_nozzle_size": { "default_value": 0.4 }, + "material_diameter": { "default_value": 1.75 } + } +} diff --git a/resources/extruders/pbr3d_g1_extruder_0.def.json b/resources/extruders/pbr3d_g1_extruder_0.def.json new file mode 100644 index 0000000000..3a79fe4f20 --- /dev/null +++ b/resources/extruders/pbr3d_g1_extruder_0.def.json @@ -0,0 +1,15 @@ +{ + "version": 2, + "name": "Extruder 1", + "inherits": "fdmextruder", + "metadata": { + "machine": "pbr3d_g1", + "position": "0" + }, + + "overrides": { + "extruder_nr": { "default_value": 0 }, + "machine_nozzle_size": { "default_value": 0.4 }, + "material_diameter": { "default_value": 1.75 } + } +} diff --git a/resources/meshes/pbr3d_g1_buildplate.stl b/resources/meshes/pbr3d_g1_buildplate.stl new file mode 100644 index 0000000000..1f7b77bd78 Binary files /dev/null and b/resources/meshes/pbr3d_g1_buildplate.stl differ diff --git a/resources/qml/ActionButton.qml b/resources/qml/ActionButton.qml index 0c1be007b5..31d5c35d2c 100644 --- a/resources/qml/ActionButton.qml +++ b/resources/qml/ActionButton.qml @@ -1,4 +1,4 @@ -// Copyright (c) 2020 Ultimaker B.V. +// Copyright (c) 2021 Ultimaker B.V. // Cura is released under the terms of the LGPLv3 or higher. import QtQuick 2.7 @@ -18,19 +18,16 @@ Button property alias textFont: buttonText.font property alias cornerRadius: backgroundRect.radius property alias tooltip: tooltip.tooltipText - property alias cornerSide: backgroundRect.cornerSide property color color: UM.Theme.getColor("primary") property color hoverColor: UM.Theme.getColor("primary_hover") property color disabledColor: color property color textColor: UM.Theme.getColor("button_text") property color textHoverColor: textColor - property color textDisabledColor: textColor + property color textDisabledColor: disabledColor property color outlineColor: color - property color outlineHoverColor: hoverColor - property color outlineDisabledColor: outlineColor - property alias shadowColor: shadow.color - property alias shadowEnabled: shadow.visible + property color outlineHoverColor: outlineColor + property color outlineDisabledColor: disabledColor property alias busy: busyIndicator.visible property bool underlineTextOnHover: false @@ -46,6 +43,49 @@ Button // but it can exceed a maximum, then this value have to be set. property int maximumWidth: 0 + // These properties are deprecated. + // To (maybe) prevent a major SDK upgrade, mark them as deprecated instead of just outright removing them. + // Note, if you still want rounded corners, use (something based on) Cura.RoundedRectangle. + property alias cornerSide: deprecatedProperties.cornerSide + property alias shadowColor: deprecatedProperties.shadowColor + property alias shadowEnabled: deprecatedProperties.shadowEnabled + + Item + { + id: deprecatedProperties + + visible: false + enabled: false + width: 0 + height: 0 + + property var cornerSide: null + property var shadowColor: null + property var shadowEnabled: null + + onCornerSideChanged: + { + if (cornerSide != null) + { + CuraApplication.writeToLog("w", "'ActionButton.cornerSide' is deprecated since 4.11. Rounded corners can still be made with 'Cura.RoundedRectangle'."); + } + } + onShadowColorChanged: + { + if (shadowColor != null) + { + CuraApplication.writeToLog("w", "'ActionButton.shadowColor' is deprecated since 4.11.") + } + } + onShadowEnabledChanged: + { + if (shadowEnabled != null) + { + CuraApplication.writeToLog("w", "'ActionButton.shadowEnabled' is deprecated since 4.11.") + } + } + } + leftPadding: UM.Theme.getSize("default_margin").width rightPadding: UM.Theme.getSize("default_margin").width height: UM.Theme.getSize("action_button").height @@ -130,24 +170,13 @@ Button background: Cura.RoundedRectangle { id: backgroundRect - cornerSide: Cura.RoundedRectangle.Direction.All color: button.enabled ? (button.hovered ? button.hoverColor : button.color) : button.disabledColor - radius: UM.Theme.getSize("action_button_radius").width border.width: UM.Theme.getSize("default_lining").width border.color: button.enabled ? (button.hovered ? button.outlineHoverColor : button.outlineColor) : button.outlineDisabledColor - } - DropShadow - { - id: shadow - // Don't blur the shadow + // Disable the rounded-ness of this rectangle. We can't use a normal Rectangle here yet, as the API/SDK has only just been deprecated. radius: 0 - anchors.fill: backgroundRect - source: backgroundRect - verticalOffset: 2 - visible: false - // Should always be drawn behind the background. - z: backgroundRect.z - 1 + cornerSide: Cura.RoundedRectangle.Direction.None } Cura.ToolTip @@ -189,4 +218,4 @@ Button duration: 2500 } } -} \ No newline at end of file +} diff --git a/resources/qml/ActionPanel/OutputDevicesActionButton.qml b/resources/qml/ActionPanel/OutputDevicesActionButton.qml index 6d1a1d83dd..48416e69fd 100644 --- a/resources/qml/ActionPanel/OutputDevicesActionButton.qml +++ b/resources/qml/ActionPanel/OutputDevicesActionButton.qml @@ -1,4 +1,4 @@ -// Copyright (c) 2018 Ultimaker B.V. +// Copyright (c) 2021 Ultimaker B.V. // Cura is released under the terms of the LGPLv3 or higher. import QtQuick 2.7 @@ -23,7 +23,6 @@ Item id: saveToButton height: parent.height fixedWidthMode: true - cornerSide: deviceSelectionMenu.visible ? Cura.RoundedRectangle.Direction.Left : Cura.RoundedRectangle.Direction.All anchors { @@ -43,15 +42,11 @@ Item } } - Cura.ActionButton + Cura.PrimaryButton { id: deviceSelectionMenu height: parent.height - shadowEnabled: true - shadowColor: UM.Theme.getColor("primary_shadow") - cornerSide: Cura.RoundedRectangle.Direction.Right - anchors { top: parent.top @@ -61,7 +56,7 @@ Item leftPadding: UM.Theme.getSize("narrow_margin").width //Need more space than usual here for wide text. rightPadding: UM.Theme.getSize("narrow_margin").width iconSource: popup.opened ? UM.Theme.getIcon("ChevronSingleUp") : UM.Theme.getIcon("ChevronSingleDown") - color: UM.Theme.getColor("action_panel_secondary") + color: popup.opened ? hoverColor : UM.Theme.getColor("action_panel_secondary") visible: (devicesModel.deviceCount > 1) onClicked: popup.opened ? popup.close() : popup.open() @@ -70,6 +65,7 @@ Item { id: popup padding: 0 + spacing: 0 y: -height x: parent.width - width @@ -78,17 +74,16 @@ Item contentItem: ColumnLayout { + spacing: 0 + Repeater { model: devicesModel - delegate: Cura.ActionButton + delegate: Cura.PrimaryButton { text: model.description visible: model.id != UM.OutputDeviceManager.activeDevice // Don't show the active device in the list - color: "transparent" - cornerRadius: 0 - hoverColor: UM.Theme.getColor("primary") Layout.fillWidth: true // The total width of the popup should be defined by the largest button. By stating that each // button should be minimally the size of it's content (aka; implicitWidth) we can ensure that. @@ -102,13 +97,6 @@ Item } } } - - background: Rectangle - { - opacity: visible ? 1 : 0 - Behavior on opacity { NumberAnimation { duration: 100 } } - color: UM.Theme.getColor("action_panel_secondary") - } } } diff --git a/resources/qml/Cura.qml b/resources/qml/Cura.qml index db910d1798..191ae712d4 100644 --- a/resources/qml/Cura.qml +++ b/resources/qml/Cura.qml @@ -429,6 +429,14 @@ UM.MainWindow height: UM.Theme.getSize("message_action_button").height } } + link: Component + { + Cura.TertiaryButton + { + text: model.name + height: UM.Theme.getSize("message_action_button").height + } + } } } diff --git a/resources/qml/ExtruderIcon.qml b/resources/qml/ExtruderIcon.qml index be67515196..f33e345b68 100644 --- a/resources/qml/ExtruderIcon.qml +++ b/resources/qml/ExtruderIcon.qml @@ -47,7 +47,7 @@ Item id: extruderNumberText anchors.centerIn: parent text: index + 1 - font: UM.Theme.getFont("small_black") + font: UM.Theme.getFont("small_emphasis") color: UM.Theme.getColor("text") width: contentWidth height: contentHeight diff --git a/resources/qml/Menus/ConfigurationMenu/ConfigurationMenu.qml b/resources/qml/Menus/ConfigurationMenu/ConfigurationMenu.qml index 75bb7d0787..43ccde461e 100644 --- a/resources/qml/Menus/ConfigurationMenu/ConfigurationMenu.qml +++ b/resources/qml/Menus/ConfigurationMenu/ConfigurationMenu.qml @@ -59,10 +59,10 @@ Cura.ExpandablePopup anchors.verticalCenter: parent.verticalCenter } - Item + ColumnLayout { - height: childrenRect.height opacity: model.enabled ? 1 : UM.Theme.getColor("extruder_disabled").a + spacing: 0 anchors { left: extruderIcon.right @@ -81,13 +81,8 @@ Cura.ExpandablePopup font: UM.Theme.getFont("default") color: UM.Theme.getColor("text") renderType: Text.NativeRendering + width: parent.width - anchors - { - top: parent.top - left: parent.left - right: parent.right - } visible: !truncated } @@ -100,13 +95,7 @@ Cura.ExpandablePopup font: UM.Theme.getFont("default") color: UM.Theme.getColor("text") renderType: Text.NativeRendering - - anchors - { - top: parent.top - left: parent.left - right: parent.right - } + width: parent.width visible: !materialBrandColorTypeLabel.visible && !truncated } @@ -120,13 +109,7 @@ Cura.ExpandablePopup font: UM.Theme.getFont("default") color: UM.Theme.getColor("text") renderType: Text.NativeRendering - - anchors - { - top: parent.top - left: parent.left - right: parent.right - } + width: parent.width visible: !materialBrandColorTypeLabel.visible && !materialColorTypeLabel.visible } // Label that shows the name of the variant @@ -141,13 +124,7 @@ Cura.ExpandablePopup font: UM.Theme.getFont("default_bold") color: UM.Theme.getColor("text") renderType: Text.NativeRendering - - anchors - { - left: parent.left - top: materialBrandColorTypeLabel.bottom - right: parent.right - } + width: parent.width } } } diff --git a/resources/qml/Menus/ConfigurationMenu/CustomConfiguration.qml b/resources/qml/Menus/ConfigurationMenu/CustomConfiguration.qml index 7d1393151f..8376693ad1 100644 --- a/resources/qml/Menus/ConfigurationMenu/CustomConfiguration.qml +++ b/resources/qml/Menus/ConfigurationMenu/CustomConfiguration.qml @@ -302,15 +302,15 @@ Item } Item { - width: instructionButton.width + 2 * UM.Theme.getSize("default_margin").width + width: instructionButton.width + 2 * UM.Theme.getSize("narrow_margin").width height: instructionButton.visible ? materialSelection.height: 0 Button { id: instructionButton hoverEnabled: true contentItem: Item {} - height: 0.5 * materialSelection.height - width: height + height: UM.Theme.getSize("small_button").height + width: UM.Theme.getSize("small_button").width anchors.centerIn: parent background: UM.RecolorImage { diff --git a/resources/qml/PrimaryButton.qml b/resources/qml/PrimaryButton.qml index fca63d2cdb..52c460bde4 100644 --- a/resources/qml/PrimaryButton.qml +++ b/resources/qml/PrimaryButton.qml @@ -1,4 +1,4 @@ -// Copyright (c) 2018 Ultimaker B.V. +// Copyright (c) 2021 Ultimaker B.V. // Cura is released under the terms of the LGPLv3 or higher. import QtQuick 2.2 @@ -9,8 +9,6 @@ import Cura 1.1 as Cura Cura.ActionButton { - shadowEnabled: true - shadowColor: enabled ? UM.Theme.getColor("primary_button_shadow"): UM.Theme.getColor("action_button_disabled_shadow") color: UM.Theme.getColor("primary_button") textColor: UM.Theme.getColor("primary_button_text") outlineColor: "transparent" diff --git a/resources/qml/PrintSetupSelector/Custom/CustomPrintSetup.qml b/resources/qml/PrintSetupSelector/Custom/CustomPrintSetup.qml index 120aca9228..cde2cd8dfc 100644 --- a/resources/qml/PrintSetupSelector/Custom/CustomPrintSetup.qml +++ b/resources/qml/PrintSetupSelector/Custom/CustomPrintSetup.qml @@ -226,12 +226,12 @@ Item { Cura.ExtruderIcon { - anchors.horizontalCenter: parent.horizontalCenter + anchors.centerIn: parent materialColor: model.color extruderEnabled: model.enabled iconVariant: "default" - width: UM.Theme.getSize("medium_button_icon").width - height: UM.Theme.getSize("medium_button_icon").height + height: parent.height + width: height } } onClicked: diff --git a/resources/qml/PrintSetupSelector/Recommended/RecommendedInfillDensitySelector.qml b/resources/qml/PrintSetupSelector/Recommended/RecommendedInfillDensitySelector.qml index a29b69c924..705a3e95ef 100644 --- a/resources/qml/PrintSetupSelector/Recommended/RecommendedInfillDensitySelector.qml +++ b/resources/qml/PrintSetupSelector/Recommended/RecommendedInfillDensitySelector.qml @@ -43,7 +43,7 @@ Item { return UM.Theme.getIcon("Infill2") } - return UM.Theme.getIcon("Solid") + return UM.Theme.getIcon("Infill100") } } diff --git a/resources/qml/SecondaryButton.qml b/resources/qml/SecondaryButton.qml index f03d8acdfa..ba4e0bb2c1 100644 --- a/resources/qml/SecondaryButton.qml +++ b/resources/qml/SecondaryButton.qml @@ -1,4 +1,4 @@ -// Copyright (c) 2018 Ultimaker B.V. +// Copyright (c) 2021 Ultimaker B.V. // Cura is released under the terms of the LGPLv3 or higher. import QtQuick 2.2 @@ -9,11 +9,9 @@ import Cura 1.1 as Cura Cura.ActionButton { - shadowEnabled: true - shadowColor: enabled ? UM.Theme.getColor("secondary_button_shadow"): UM.Theme.getColor("action_button_disabled_shadow") color: UM.Theme.getColor("secondary_button") textColor: UM.Theme.getColor("secondary_button_text") - outlineColor: "transparent" + outlineColor: UM.Theme.getColor("secondary_button_text") disabledColor: UM.Theme.getColor("action_button_disabled") textDisabledColor: UM.Theme.getColor("action_button_disabled_text") hoverColor: UM.Theme.getColor("secondary_button_hover") diff --git a/resources/qml/TertiaryButton.qml b/resources/qml/TertiaryButton.qml index eb714c22f6..76684b6ef2 100644 --- a/resources/qml/TertiaryButton.qml +++ b/resources/qml/TertiaryButton.qml @@ -1,4 +1,4 @@ -// Copyright (c) 2020 Ultimaker B.V. +// Copyright (c) 2021 Ultimaker B.V. // Cura is released under the terms of the LGPLv3 or higher. import QtQuick 2.2 @@ -9,8 +9,6 @@ import Cura 1.1 as Cura Cura.ActionButton { - shadowEnabled: true - shadowColor: enabled ? UM.Theme.getColor("secondary_button_shadow"): UM.Theme.getColor("action_button_disabled_shadow") color: "transparent" textColor: UM.Theme.getColor("text_link") outlineColor: "transparent" diff --git a/resources/themes/cura-dark/theme.json b/resources/themes/cura-dark/theme.json index e3266b923b..0d6fa2f260 100644 --- a/resources/themes/cura-dark/theme.json +++ b/resources/themes/cura-dark/theme.json @@ -16,13 +16,20 @@ "primary_text": [255, 255, 255, 204], "secondary": [95, 95, 95, 255], - "icon": [204, 204, 204, 255], + "secondary_button": [0, 0, 0, 0], + "secondary_button_hover": [85, 85, 87, 255], + "secondary_button_text": [255, 255, 255, 255], + + "icon": [255, 255, 255, 255], "toolbar_background": [39, 44, 48, 255], - "toolbar_button_active": [95, 95, 95, 255], - "toolbar_button_hover": [95, 95, 95, 255], - "toolbar_button_active_hover": [95, 95, 95, 255], + "toolbar_button_active": [57, 57, 58, 255], + "toolbar_button_hover": [57, 57, 58, 255], + "toolbar_button_active_hover": [57, 57, 58, 255], "main_window_header_button_text_inactive": [128, 128, 128, 255], + "main_window_header_background": [14, 14, 14, 255], + "main_window_header_background_gradient": [32, 32, 32, 255], + "main_window_header_button_background_hovered": [46, 46, 46, 255], "account_sync_state_icon": [255, 255, 255, 204], @@ -32,7 +39,7 @@ "text": [255, 255, 255, 204], "text_detail": [255, 255, 255, 172], - "text_link": [255, 255, 255, 127], + "text_link": [25, 110, 240, 255], "text_inactive": [255, 255, 255, 88], "text_hover": [255, 255, 255, 204], "text_pressed": [255, 255, 255, 204], @@ -87,8 +94,8 @@ "action_button_active": [39, 44, 48, 30], "action_button_active_text": [255, 255, 255, 255], "action_button_active_border": [255, 255, 255, 100], - "action_button_disabled": [19, 24, 28, 255], - "action_button_disabled_text": [200, 200, 200, 80], + "action_button_disabled": [85, 85, 87, 255], + "action_button_disabled_text": [103, 103, 104, 255], "action_button_disabled_border": [255, 255, 255, 30], "scrollbar_background": [39, 44, 48, 0], diff --git a/resources/themes/cura-light/icons/default/Infill100.svg b/resources/themes/cura-light/icons/default/Infill100.svg new file mode 100644 index 0000000000..d136666990 --- /dev/null +++ b/resources/themes/cura-light/icons/default/Infill100.svg @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/resources/themes/cura-light/icons/default/Solid.svg b/resources/themes/cura-light/icons/default/Solid.svg index 34367b7bc7..608a56a3e3 100644 --- a/resources/themes/cura-light/icons/default/Solid.svg +++ b/resources/themes/cura-light/icons/default/Solid.svg @@ -1,10 +1,3 @@ - - - - - - - - - - + + + \ No newline at end of file diff --git a/resources/themes/cura-light/theme.json b/resources/themes/cura-light/theme.json index bd49b1cf90..93a40d645d 100644 --- a/resources/themes/cura-light/theme.json +++ b/resources/themes/cura-light/theme.json @@ -148,22 +148,22 @@ "weight": 50, "family": "Noto Sans" }, - "small_black": { + "small_emphasis": { "size": 0.9, "weight": 100, "family": "Noto Sans" }, - "small_black_ja_JP": { + "small_emphasis_ja_JP": { "size": 0.9, "weight": 100, "family": "Noto Sans" }, - "small_black_zh_CN": { + "small_emphasis_zh_CN": { "size": 0.9, "weight": 100, "family": "Noto Sans" }, - "small_black_zh_TW": { + "small_emphasis_zh_TW": { "size": 0.9, "weight": 100, "family": "Noto Sans" @@ -188,15 +188,15 @@ "icon": [8, 7, 63, 255], - "primary_button": [38, 113, 231, 255], + "primary_button": [25, 110, 240, 255], "primary_button_shadow": [27, 95, 202, 255], - "primary_button_hover": [81, 145, 247, 255], + "primary_button_hover": [16, 70, 156, 255], "primary_button_text": [255, 255, 255, 255], - "secondary_button": [240, 240, 240, 255], + "secondary_button": [255, 255, 255, 0], "secondary_button_shadow": [216, 216, 216, 255], - "secondary_button_hover": [228, 228, 228, 255], - "secondary_button_text": [30, 102, 215, 255], + "secondary_button_hover": [232, 240, 253, 255], + "secondary_button_text": [25, 110, 240, 255], "main_window_header_background": [8, 7, 63, 255], "main_window_header_background_gradient": [25, 23, 91, 255], @@ -216,7 +216,7 @@ "machine_selector_text_active": [255, 255, 255, 255], "machine_selector_printer_icon": [8, 7, 63, 255], - "action_panel_secondary": [27, 95, 202, 255], + "action_panel_secondary": [25, 110, 240, 255], "first_run_shadow": [50, 50, 50, 255], @@ -230,7 +230,7 @@ "text": [25, 25, 25, 255], "text_detail": [174, 174, 174, 128], - "text_link": [50, 130, 255, 255], + "text_link": [25, 110, 240, 255], "text_inactive": [174, 174, 174, 255], "text_pressed": [50, 130, 255, 255], "text_subtext": [0, 0, 0, 255], @@ -287,8 +287,8 @@ "action_button_active_text": [0, 0, 0, 255], "action_button_active_border": [50, 130, 255, 255], "action_button_disabled": [245, 245, 245, 255], - "action_button_disabled_text": [127, 127, 127, 255], - "action_button_disabled_border": [245, 245, 245, 255], + "action_button_disabled_text": [196, 196, 196, 255], + "action_button_disabled_border": [196, 196, 196, 255], "action_button_shadow": [223, 223, 223, 255], "action_button_disabled_shadow": [228, 228, 228, 255], @@ -350,7 +350,7 @@ "checkbox_hover": [255, 255, 255, 255], "checkbox_border": [199, 199, 199, 255], "checkbox_border_hover": [50, 130, 255, 255], - "checkbox_mark": [50, 130, 255, 255], + "checkbox_mark": [35, 35, 35, 255], "checkbox_disabled": [223, 223, 223, 255], "checkbox_text": [35, 35, 35, 255], @@ -437,7 +437,7 @@ "monitor_icon_accent": [255, 255, 255, 255], "monitor_icon_disabled": [238, 238, 238, 255], - "monitor_secondary_button_hover": [228, 228, 228, 255], + "monitor_secondary_button_hover": [232, 242, 252, 255], "monitor_secondary_button": [240, 240, 240, 255], "monitor_secondary_button_text": [30, 102, 215, 255], "monitor_secondary_button_shadow": [216, 216, 216, 255], @@ -614,7 +614,7 @@ "message": [30.0, 5.0], "message_close": [1, 1], "message_radius": [0.25, 0.25], - "message_action_button": [0, 2.0], + "message_action_button": [0, 2.5], "message_image": [15.0, 5.0], "infill_button_margin": [0.5, 0.5],