From d41d68e6fab8f5af12fd8cb77af497d2487dd558 Mon Sep 17 00:00:00 2001 From: Konstantinos Karmas Date: Wed, 28 Jul 2021 16:57:15 +0200 Subject: [PATCH] Replace warning icon in the unable to slice message With the new warning icon that has a solid background, similar to the warning icon used in the messages. CURA-8439 --- .../qml/ActionPanel/SliceProcessWidget.qml | 47 +++++++++++++++++-- 1 file changed, 42 insertions(+), 5 deletions(-) diff --git a/resources/qml/ActionPanel/SliceProcessWidget.qml b/resources/qml/ActionPanel/SliceProcessWidget.qml index 42df08560a..92b81f43cf 100644 --- a/resources/qml/ActionPanel/SliceProcessWidget.qml +++ b/resources/qml/ActionPanel/SliceProcessWidget.qml @@ -57,16 +57,53 @@ Column font: UM.Theme.getFont("default") renderType: Text.NativeRendering } - - Cura.IconWithText + Item { id: unableToSliceMessage width: parent.width visible: widget.backendState == UM.Backend.Error - text: catalog.i18nc("@label:PrintjobStatus", "Unable to slice") - source: UM.Theme.getIcon("Warning") - iconColor: UM.Theme.getColor("warning") + height: icon.height + Item + { + id: icon + anchors.verticalCenter: parent.verticalCenter + width: visible ? UM.Theme.getSize("section_icon").width : 0 + height: width + UM.RecolorImage + { + id: warningIconBackground + height: parent.height + width: parent.width + sourceSize.width: width + sourceSize.height: height + source: UM.Theme.getIcon("CircleSolid", "low") + color: UM.Theme.getColor("warning") + } + UM.RecolorImage + { + id: warningIcon + height: parent.height + width: parent.width + sourceSize.width: width + sourceSize.height: height + source: UM.Theme.getIcon("Warning", "low") + color: UM.Theme.getColor("message_warning_icon") + } + } + Label + { + id: label + anchors.left: icon.right + anchors.right: parent.right + anchors.verticalCenter: parent.verticalCenter + anchors.leftMargin: UM.Theme.getSize("default_margin").width + text: catalog.i18nc("@label:PrintjobStatus", "Unable to slice") + color: UM.Theme.getColor("text") + font: UM.Theme.getFont("default") + renderType: Text.NativeRendering + wrapMode: Text.WordWrap + } } // Progress bar, only visible when the backend is in the process of slice the printjob