diff options
Diffstat (limited to 'plugins')
22 files changed, 84 insertions, 199 deletions
diff --git a/plugins/CuraDrive/src/qml/components/BackupListItem.qml b/plugins/CuraDrive/src/qml/components/BackupListItem.qml index e35c8351b7..ced85d53bd 100644 --- a/plugins/CuraDrive/src/qml/components/BackupListItem.qml +++ b/plugins/CuraDrive/src/qml/components/BackupListItem.qml @@ -6,7 +6,7 @@ import QtQuick.Controls 2.1 import QtQuick.Layouts 1.3 import QtQuick.Dialogs 1.1 -import UM 1.1 as UM +import UM 1.5 as UM import Cura 1.0 as Cura Item @@ -42,28 +42,22 @@ Item onClicked: backupListItem.showDetails = !backupListItem.showDetails } - Label + UM.Label { text: new Date(modelData.generated_time).toLocaleString(UM.Preferences.getValue("general/language")) - color: UM.Theme.getColor("text") elide: Text.ElideRight Layout.minimumWidth: 100 * screenScaleFactor Layout.maximumWidth: 500 * screenScaleFactor Layout.fillWidth: true - font: UM.Theme.getFont("default") - renderType: Text.NativeRendering } - Label + UM.Label { text: modelData.metadata.description - color: UM.Theme.getColor("text") elide: Text.ElideRight Layout.minimumWidth: 100 * screenScaleFactor Layout.maximumWidth: 500 * screenScaleFactor Layout.fillWidth: true - font: UM.Theme.getFont("default") - renderType: Text.NativeRendering } Cura.SecondaryButton diff --git a/plugins/CuraDrive/src/qml/components/BackupListItemDetailsRow.qml b/plugins/CuraDrive/src/qml/components/BackupListItemDetailsRow.qml index 9e4612fcf8..8ddf8e9d42 100644 --- a/plugins/CuraDrive/src/qml/components/BackupListItemDetailsRow.qml +++ b/plugins/CuraDrive/src/qml/components/BackupListItemDetailsRow.qml @@ -5,7 +5,7 @@ import QtQuick 2.7 import QtQuick.Controls 2.1 import QtQuick.Layouts 1.3 -import UM 1.3 as UM +import UM 1.5 as UM RowLayout { @@ -26,27 +26,21 @@ RowLayout color: UM.Theme.getColor("text") } - Label + UM.Label { id: detailName - color: UM.Theme.getColor("text") elide: Text.ElideRight Layout.minimumWidth: 50 * screenScaleFactor Layout.maximumWidth: 100 * screenScaleFactor Layout.fillWidth: true - font: UM.Theme.getFont("default") - renderType: Text.NativeRendering } - Label + UM.Label { id: detailValue - color: UM.Theme.getColor("text") elide: Text.ElideRight Layout.minimumWidth: 50 * screenScaleFactor Layout.maximumWidth: 100 * screenScaleFactor Layout.fillWidth: true - font: UM.Theme.getFont("default") - renderType: Text.NativeRendering } } diff --git a/plugins/CuraDrive/src/qml/pages/WelcomePage.qml b/plugins/CuraDrive/src/qml/pages/WelcomePage.qml index 0b207bc170..53b8819bd6 100644 --- a/plugins/CuraDrive/src/qml/pages/WelcomePage.qml +++ b/plugins/CuraDrive/src/qml/pages/WelcomePage.qml @@ -5,7 +5,7 @@ import QtQuick 2.7 import QtQuick.Controls 2.1 import QtQuick.Window 2.2 -import UM 1.3 as UM +import UM 1.5 as UM import Cura 1.1 as Cura import "../components" @@ -28,18 +28,14 @@ Column width: Math.round(parent.width / 4) } - Label + UM.Label { id: welcomeTextLabel text: catalog.i18nc("@description", "Backup and synchronize your Cura settings.") width: Math.round(parent.width / 2) - font: UM.Theme.getFont("default") - color: UM.Theme.getColor("text") - verticalAlignment: Text.AlignVCenter horizontalAlignment: Text.AlignHCenter anchors.horizontalCenter: parent.horizontalCenter wrapMode: Label.WordWrap - renderType: Text.NativeRendering } Cura.PrimaryButton diff --git a/plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml b/plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml index 9957171379..c97989c449 100644 --- a/plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml +++ b/plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml @@ -5,7 +5,7 @@ import QtQuick 2.2 import QtQuick.Controls 1.2 import QtQuick.Controls.Styles 1.2 -import UM 1.2 as UM +import UM 1.5 as UM import Cura 1.0 as Cura import ".." @@ -126,13 +126,10 @@ Item } - Label + UM.Label { id: meshTypeLabel - font: UM.Theme.getFont("default") - color: UM.Theme.getColor("text") height: UM.Theme.getSize("setting").height - verticalAlignment: Text.AlignVCenter } diff --git a/plugins/PrepareStage/PrepareMenu.qml b/plugins/PrepareStage/PrepareMenu.qml index cf7665bda6..f0779df98f 100644 --- a/plugins/PrepareStage/PrepareMenu.qml +++ b/plugins/PrepareStage/PrepareMenu.qml @@ -5,7 +5,7 @@ import QtQuick 2.9 import QtQuick.Layouts 1.1 import QtQuick.Controls 2.3 -import UM 1.3 as UM +import UM 1.5 as UM import Cura 1.1 as Cura @@ -131,14 +131,10 @@ Item height: UM.Theme.getSize("action_button").height hoverEnabled: true - contentItem: Label + contentItem: UM.Label { text: model.displayText - color: UM.Theme.getColor("text") font: UM.Theme.getFont("medium") - renderType: Text.NativeRendering - verticalAlignment: Text.AlignVCenter - width: contentWidth height: parent.height } diff --git a/plugins/SimulationView/SimulationViewMenuComponent.qml b/plugins/SimulationView/SimulationViewMenuComponent.qml index 2c62473764..379da63c28 100644 --- a/plugins/SimulationView/SimulationViewMenuComponent.qml +++ b/plugins/SimulationView/SimulationViewMenuComponent.qml @@ -43,22 +43,19 @@ Cura.ExpandableComponent headerItem: Item { - Label + UM.Label { id: colorSchemeLabel text: catalog.i18nc("@label", "Color scheme") - verticalAlignment: Text.AlignVCenter height: parent.height elide: Text.ElideRight font: UM.Theme.getFont("medium") color: UM.Theme.getColor("text_medium") - renderType: Text.NativeRendering } - Label + UM.Label { text: layerTypeCombobox.currentText - verticalAlignment: Text.AlignVCenter anchors { left: colorSchemeLabel.right @@ -68,8 +65,6 @@ Cura.ExpandableComponent height: parent.height elide: Text.ElideRight font: UM.Theme.getFont("medium") - color: UM.Theme.getColor("text") - renderType: Text.NativeRendering } } @@ -165,16 +160,13 @@ Cura.ExpandableComponent } } - Label + UM.Label { id: compatibilityModeLabel text: catalog.i18nc("@label", "Compatibility Mode") - font: UM.Theme.getFont("default") - color: UM.Theme.getColor("text") visible: UM.SimulationView.compatibilityMode height: UM.Theme.getSize("layerview_row").height width: parent.width - renderType: Text.NativeRendering } Item // Spacer @@ -213,12 +205,11 @@ Cura.ExpandableComponent border.color: UM.Theme.getColor("lining") } - Label + UM.Label { text: model.name elide: Text.ElideRight color: UM.Theme.getColor("setting_control_text") - font: UM.Theme.getFont("default") anchors { verticalCenter: parent.verticalCenter @@ -227,7 +218,6 @@ Cura.ExpandableComponent leftMargin: UM.Theme.getSize("checkbox").width + Math.round(UM.Theme.getSize("default_margin").width / 2) rightMargin: UM.Theme.getSize("default_margin").width * 2 } - renderType: Text.NativeRendering } } } @@ -347,7 +337,7 @@ Cura.ExpandableComponent } } - Label + UM.Label { text: label visible: viewSettings.show_legend @@ -356,8 +346,6 @@ Cura.ExpandableComponent height: UM.Theme.getSize("layerview_row").height + UM.Theme.getSize("default_lining").height width: parent.width color: UM.Theme.getColor("setting_control_text") - font: UM.Theme.getFont("default") - renderType: Text.NativeRendering Rectangle { anchors.verticalCenter: parent.verticalCenter @@ -382,7 +370,7 @@ Cura.ExpandableComponent width: parent.width height: UM.Theme.getSize("layerview_row").height - Label //Minimum value. + UM.Label //Minimum value. { text: { @@ -413,12 +401,9 @@ Cura.ExpandableComponent return catalog.i18nc("@label","min") } anchors.left: parent.left - color: UM.Theme.getColor("setting_control_text") - font: UM.Theme.getFont("default") - renderType: Text.NativeRendering } - Label //Unit in the middle. + UM.Label //Unit in the middle. { text: { @@ -450,10 +435,9 @@ Cura.ExpandableComponent anchors.horizontalCenter: parent.horizontalCenter color: UM.Theme.getColor("setting_control_text") - font: UM.Theme.getFont("default") } - Label //Maximum value. + UM.Label //Maximum value. { text: { if (UM.SimulationView.layerActivity && CuraApplication.platformActivity) @@ -484,7 +468,6 @@ Cura.ExpandableComponent anchors.right: parent.right color: UM.Theme.getColor("setting_control_text") - font: UM.Theme.getFont("default") } } diff --git a/plugins/Toolbox/resources/qml/components/ToolboxActionButtonStyle.qml b/plugins/Toolbox/resources/qml/components/ToolboxActionButtonStyle.qml index eff74278c9..4c8504781a 100644 --- a/plugins/Toolbox/resources/qml/components/ToolboxActionButtonStyle.qml +++ b/plugins/Toolbox/resources/qml/components/ToolboxActionButtonStyle.qml @@ -4,7 +4,7 @@ import QtQuick 2.2 import QtQuick.Controls 1.4 import QtQuick.Controls.Styles 1.4 -import UM 1.1 as UM +import UM 1.5 as UM ButtonStyle { @@ -19,11 +19,9 @@ ButtonStyle color: UM.Theme.getColor("lining") } } - label: Label + label: UM.Label { text: control.text - color: UM.Theme.getColor("text") - verticalAlignment: Text.AlignVCenter horizontalAlignment: Text.AlignHCenter } }
\ No newline at end of file diff --git a/plugins/Toolbox/resources/qml/components/ToolboxCompatibilityChart.qml b/plugins/Toolbox/resources/qml/components/ToolboxCompatibilityChart.qml index e1f88a473f..265610a55e 100644 --- a/plugins/Toolbox/resources/qml/components/ToolboxCompatibilityChart.qml +++ b/plugins/Toolbox/resources/qml/components/ToolboxCompatibilityChart.qml @@ -27,7 +27,7 @@ Item // This is a bit of a hack, but the whole QML is pretty messy right now. This needs a big overhaul. height: visible ? heading.height + table.height: 0 - Label + UM.Label { id: heading width: parent.width @@ -35,7 +35,6 @@ Item wrapMode: Text.WordWrap color: UM.Theme.getColor("text_medium") font: UM.Theme.getFont("medium") - renderType: Text.NativeRendering } TableView @@ -92,29 +91,25 @@ Item itemDelegate: Item { height: UM.Theme.getSize("toolbox_chart_row").height - Label + UM.Label { anchors.verticalCenter: parent.verticalCenter elide: Text.ElideRight text: styleData.value || "" color: UM.Theme.getColor("text_medium") - font: UM.Theme.getFont("default") - renderType: Text.NativeRendering } } Component { id: columnTextDelegate - Label + UM.Label { anchors.fill: parent - verticalAlignment: Text.AlignVCenter + text: styleData.value || "" elide: Text.ElideRight color: UM.Theme.getColor("text_medium") - font: UM.Theme.getFont("default") - renderType: Text.NativeRendering } } @@ -152,7 +147,7 @@ Item } } - Label + UM.Label { id: dataSheetLinks anchors.top: compatibilityItem.bottom @@ -200,10 +195,6 @@ Item return result } - font: UM.Theme.getFont("default") - color: UM.Theme.getColor("text") - linkColor: UM.Theme.getColor("text_link") onLinkActivated: UM.UrlUtil.openUrl(link, ["http", "https"]) - renderType: Text.NativeRendering } } diff --git a/plugins/Toolbox/resources/qml/components/ToolboxDownloadsGridTile.qml b/plugins/Toolbox/resources/qml/components/ToolboxDownloadsGridTile.qml index c310bd7121..c53c80f2ea 100644 --- a/plugins/Toolbox/resources/qml/components/ToolboxDownloadsGridTile.qml +++ b/plugins/Toolbox/resources/qml/components/ToolboxDownloadsGridTile.qml @@ -5,7 +5,7 @@ import QtQuick 2.10 import QtQuick.Controls 1.4 import QtQuick.Controls.Styles 1.4 import QtQuick.Layouts 1.3 -import UM 1.1 as UM +import UM 1.5 as UM import Cura 1.1 as Cura Item @@ -98,27 +98,23 @@ Item bottom: parent.bottom } - Label + UM.Label { id: name text: model.name width: parent.width elide: Text.ElideRight - color: UM.Theme.getColor("text") font: UM.Theme.getFont("default_bold") } - Label + UM.Label { id: info text: model.description elide: Text.ElideRight width: parent.width wrapMode: Text.WordWrap - color: UM.Theme.getColor("text") - font: UM.Theme.getFont("default") anchors.top: name.bottom anchors.bottom: parent.bottom - verticalAlignment: Text.AlignVCenter maximumLineCount: 2 } } diff --git a/plugins/Toolbox/resources/qml/components/ToolboxDownloadsShowcaseTile.qml b/plugins/Toolbox/resources/qml/components/ToolboxDownloadsShowcaseTile.qml index 6695921126..2e8162b0fb 100644 --- a/plugins/Toolbox/resources/qml/components/ToolboxDownloadsShowcaseTile.qml +++ b/plugins/Toolbox/resources/qml/components/ToolboxDownloadsShowcaseTile.qml @@ -5,7 +5,7 @@ import QtQuick 2.10 import QtQuick.Controls 1.4 import QtQuick.Controls.Styles 1.4 -import UM 1.1 as UM +import UM 1.5 as UM Rectangle { @@ -34,7 +34,7 @@ Rectangle horizontalCenter: parent.horizontalCenter } } - Label + UM.Label { id: packageName text: model.name @@ -43,15 +43,12 @@ Rectangle horizontalCenter: parent.horizontalCenter top: thumbnail.bottom } - verticalAlignment: Text.AlignVCenter horizontalAlignment: Text.AlignHCenter - renderType: Text.NativeRendering height: UM.Theme.getSize("toolbox_heading_label").height width: parent.width - UM.Theme.getSize("default_margin").width wrapMode: Text.WordWrap elide: Text.ElideRight font: UM.Theme.getFont("medium_bold") - color: UM.Theme.getColor("text") } UM.RecolorImage { diff --git a/plugins/Toolbox/resources/qml/components/ToolboxFooter.qml b/plugins/Toolbox/resources/qml/components/ToolboxFooter.qml index 9863bd9a93..f5309e503b 100644 --- a/plugins/Toolbox/resources/qml/components/ToolboxFooter.qml +++ b/plugins/Toolbox/resources/qml/components/ToolboxFooter.qml @@ -4,7 +4,7 @@ import QtQuick 2.10 import QtQuick.Controls 2.3 -import UM 1.1 as UM +import UM 1.5 as UM import Cura 1.0 as Cura Item @@ -14,12 +14,10 @@ Item anchors.bottom: parent.bottom height: visible ? UM.Theme.getSize("toolbox_footer").height : 0 - Label + UM.Label { text: catalog.i18nc("@info", "You will need to restart Cura before changes in packages have effect.") - color: UM.Theme.getColor("text") height: UM.Theme.getSize("toolbox_footer_button").height - verticalAlignment: Text.AlignVCenter wrapMode: Text.WordWrap anchors { @@ -29,7 +27,6 @@ Item right: restartButton.left rightMargin: UM.Theme.getSize("default_margin").width } - renderType: Text.NativeRendering } Cura.PrimaryButton diff --git a/plugins/Toolbox/resources/qml/components/ToolboxInstalledTile.qml b/plugins/Toolbox/resources/qml/components/ToolboxInstalledTile.qml index fb59ff5d34..80acac924b 100644 --- a/plugins/Toolbox/resources/qml/components/ToolboxInstalledTile.qml +++ b/plugins/Toolbox/resources/qml/components/ToolboxInstalledTile.qml @@ -72,7 +72,7 @@ Item id: authorInfo width: Math.floor(UM.Theme.getSize("toolbox_action_button").width * 1.25) - Label + UM.Label { text: { @@ -89,24 +89,18 @@ Item width: parent.width height: Math.floor(UM.Theme.getSize("toolbox_property_label").height) wrapMode: Text.WordWrap - verticalAlignment: Text.AlignVCenter + horizontalAlignment: Text.AlignLeft onLinkActivated: Qt.openUrlExternally("mailto:" + model.author_email + "?Subject=Cura: " + model.name + " Plugin") color: model.enabled ? UM.Theme.getColor("text") : UM.Theme.getColor("lining") - linkColor: UM.Theme.getColor("text_link") - renderType: Text.NativeRendering } - Label + UM.Label { text: model.version - font: UM.Theme.getFont("default") width: parent.width height: UM.Theme.getSize("toolbox_property_label").height - color: UM.Theme.getColor("text") - verticalAlignment: Text.AlignVCenter horizontalAlignment: Text.AlignLeft - renderType: Text.NativeRendering } } ToolboxInstalledTileActions diff --git a/plugins/Toolbox/resources/qml/components/ToolboxTabButton.qml b/plugins/Toolbox/resources/qml/components/ToolboxTabButton.qml index 7a7d2be48a..a9e98a67d5 100644 --- a/plugins/Toolbox/resources/qml/components/ToolboxTabButton.qml +++ b/plugins/Toolbox/resources/qml/components/ToolboxTabButton.qml @@ -3,7 +3,7 @@ import QtQuick 2.10 import QtQuick.Controls 2.3 -import UM 1.1 as UM +import UM 1.5 as UM Button { @@ -28,17 +28,14 @@ Button } } - contentItem: Label + contentItem: UM.Label { id: label text: control.text color: UM.Theme.getColor("toolbox_header_button_text_inactive") font: UM.Theme.getFont("medium") - verticalAlignment: Text.AlignVCenter horizontalAlignment: Text.AlignHCenter - - renderType: Text.NativeRendering } states: diff --git a/plugins/Toolbox/resources/qml/pages/WelcomePage.qml b/plugins/Toolbox/resources/qml/pages/WelcomePage.qml index 04110cbc0f..49500e195f 100644 --- a/plugins/Toolbox/resources/qml/pages/WelcomePage.qml +++ b/plugins/Toolbox/resources/qml/pages/WelcomePage.qml @@ -5,7 +5,7 @@ import QtQuick 2.7 import QtQuick.Controls 2.1 import QtQuick.Window 2.2 -import UM 1.3 as UM +import UM 1.5 as UM import Cura 1.1 as Cura Column @@ -16,18 +16,14 @@ Column height: childrenRect.height anchors.centerIn: parent - Label + UM.Label { id: welcomeTextLabel text: catalog.i18nc("@description", "Please sign in to get verified plugins and materials for Ultimaker Cura Enterprise") width: Math.round(parent.width / 2) - font: UM.Theme.getFont("default") - color: UM.Theme.getColor("text") - verticalAlignment: Text.AlignVCenter horizontalAlignment: Text.AlignHCenter anchors.horizontalCenter: parent.horizontalCenter wrapMode: Label.WordWrap - renderType: Text.NativeRendering } Cura.PrimaryButton diff --git a/plugins/UM3NetworkPrinting/resources/qml/MonitorBuildplateConfiguration.qml b/plugins/UM3NetworkPrinting/resources/qml/MonitorBuildplateConfiguration.qml index 598d0ec70a..60e3726a32 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/MonitorBuildplateConfiguration.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/MonitorBuildplateConfiguration.qml @@ -3,7 +3,7 @@ import QtQuick 2.2 import QtQuick.Controls 2.0 -import UM 1.3 as UM +import UM 1.5 as UM /** * This component comprises a buildplate icon and the buildplate name. It is @@ -57,19 +57,15 @@ Item } } - Label + UM.Label { id: buildplateLabel - color: UM.Theme.getColor("text") elide: Text.ElideRight - font: UM.Theme.getFont("default") // 12pt, regular text: buildplate ? buildplate : "" visible: text !== "" // FIXED-LINE-HEIGHT: height: 18 * screenScaleFactor // TODO: Theme! - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } } } diff --git a/plugins/UM3NetworkPrinting/resources/qml/MonitorConfigOverrideDialog.qml b/plugins/UM3NetworkPrinting/resources/qml/MonitorConfigOverrideDialog.qml index 1fe766d9f7..46497cc389 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/MonitorConfigOverrideDialog.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/MonitorConfigOverrideDialog.qml @@ -5,7 +5,7 @@ import QtQuick 2.3 import QtQuick.Controls 1.4 import QtQuick.Layouts 1.3 import QtQuick.Dialogs 1.2 -import UM 1.3 as UM +import UM 1.5 as UM UM.Dialog { @@ -63,7 +63,7 @@ UM.Dialog } ] - Label + UM.Label { anchors { @@ -72,7 +72,6 @@ UM.Dialog bottomMargin: 56 * screenScaleFactor // TODO: Theme! } wrapMode: Text.WordWrap - renderType: Text.NativeRendering text: { if (!printer || !printer.activePrintJob) diff --git a/plugins/UM3NetworkPrinting/resources/qml/MonitorContextMenuButton.qml b/plugins/UM3NetworkPrinting/resources/qml/MonitorContextMenuButton.qml index 0be3732cef..1c6cfda121 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/MonitorContextMenuButton.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/MonitorContextMenuButton.qml @@ -3,7 +3,7 @@ import QtQuick 2.3 import QtQuick.Controls 2.0 -import UM 1.3 as UM +import UM 1.5 as UM import Cura 1.0 as Cura Button @@ -17,13 +17,12 @@ Button radius: Math.round(0.5 * width) width: base.width } - contentItem: Label { + contentItem: UM.Label + { color: enabled ? UM.Theme.getColor("text") : UM.Theme.getColor("monitor_text_disabled") font.pixelSize: 32 * screenScaleFactor horizontalAlignment: Text.AlignHCenter text: base.text - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering; } height: width hoverEnabled: enabled diff --git a/plugins/UM3NetworkPrinting/resources/qml/MonitorIconExtruder.qml b/plugins/UM3NetworkPrinting/resources/qml/MonitorIconExtruder.qml index ad0e8a6777..f22ac53298 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/MonitorIconExtruder.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/MonitorIconExtruder.qml @@ -3,7 +3,7 @@ import QtQuick 2.2 import QtQuick.Controls 2.0 -import UM 1.3 as UM +import UM 1.5 as UM /** * This component is a sort of "super icon" which includes a colored SVG image @@ -35,18 +35,16 @@ Item width: size } - Label + UM.Label { id: positionLabel anchors.centerIn: icon font: UM.Theme.getFont("small") - color: UM.Theme.getColor("text") height: Math.round(size / 2) horizontalAlignment: Text.AlignHCenter text: position + 1 - verticalAlignment: Text.AlignVCenter + width: Math.round(size / 2) visible: position >= 0 - renderType: Text.NativeRendering } } diff --git a/plugins/UM3NetworkPrinting/resources/qml/MonitorPrintJobCard.qml b/plugins/UM3NetworkPrinting/resources/qml/MonitorPrintJobCard.qml index 65bf4e3a07..2974e5ce6b 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/MonitorPrintJobCard.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/MonitorPrintJobCard.qml @@ -2,7 +2,7 @@ // Cura is released under the terms of the LGPLv3 or higher. import QtQuick 2.2 import QtQuick.Controls 2.0 -import UM 1.3 as UM +import UM 1.5 as UM import Cura 1.0 as Cura /** @@ -55,10 +55,9 @@ Item visible: !printJob radius: 2 * screenScaleFactor // TODO: Theme! } - Label + UM.Label { text: printJob && printJob.name ? printJob.name : "" - color: UM.Theme.getColor("text") elide: Text.ElideRight font: UM.Theme.getFont("medium") // 14pt, regular visible: printJob @@ -66,8 +65,6 @@ Item // FIXED-LINE-HEIGHT: width: parent.width height: parent.height - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } } @@ -86,18 +83,15 @@ Item radius: 2 * screenScaleFactor // TODO: Theme! } - Label + UM.Label { text: printJob ? OutputDevice.formatDuration(printJob.timeTotal) : "" - color: UM.Theme.getColor("text") elide: Text.ElideRight font: UM.Theme.getFont("medium") // 14pt, regular visible: printJob // FIXED-LINE-HEIGHT: height: Math.round(18 * screenScaleFactor) // TODO: Theme! - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } } @@ -116,11 +110,10 @@ Item radius: 2 * screenScaleFactor // TODO: Theme! } - Label + UM.Label { id: printerAssignmentLabel anchors.verticalCenter: parent.verticalCenter - color: UM.Theme.getColor("text") elide: Text.ElideRight font: UM.Theme.getFont("medium") // 14pt, regular text: { @@ -143,8 +136,6 @@ Item // FIXED-LINE-HEIGHT: height: parent.height - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } Row @@ -186,17 +177,15 @@ Item height: Math.round(72 * screenScaleFactor) // TODO: Theme! } - Label { + UM.Label + { text: printJob && printJob.owner ? printJob.owner : "" - color: UM.Theme.getColor("text") elide: Text.ElideRight font: UM.Theme.getFont("medium") // 14pt, regular anchors.top: printerConfiguration.top // FIXED-LINE-HEIGHT: height: Math.round(18 * screenScaleFactor) // TODO: Theme! - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } } } diff --git a/plugins/UM3NetworkPrinting/resources/qml/MonitorPrintJobProgressBar.qml b/plugins/UM3NetworkPrinting/resources/qml/MonitorPrintJobProgressBar.qml index 6ad295beec..c78e4ca1b8 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/MonitorPrintJobProgressBar.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/MonitorPrintJobProgressBar.qml @@ -4,7 +4,7 @@ import QtQuick 2.3 import QtQuick.Controls.Styles 1.3 import QtQuick.Controls 1.4 -import UM 1.3 as UM +import UM 1.5 as UM /** * NOTE: For most labels, a fixed height with vertical alignment is used to make @@ -34,7 +34,7 @@ Item width: UM.Theme.getSize("monitor_progress_bar").width } - Label + UM.Label { id: percentLabel anchors @@ -46,14 +46,11 @@ Item text: printJob ? Math.round(printJob.progress * 100) + "%" : "0%" color: printJob && printJob.isActive ? UM.Theme.getColor("text") : UM.Theme.getColor("monitor_text_disabled") width: contentWidth - font: UM.Theme.getFont("default") // 12pt, regular // FIXED-LINE-HEIGHT: height: UM.Theme.getSize("monitor_text_line").height - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } - Label + UM.Label { id: statusLabel anchors @@ -62,8 +59,6 @@ Item leftMargin: UM.Theme.getSize("monitor_margin").width verticalCenter: parent.verticalCenter } - color: UM.Theme.getColor("text") - font: UM.Theme.getFont("default") text: { if (!printJob) @@ -104,7 +99,5 @@ Item // FIXED-LINE-HEIGHT: height: UM.Theme.getSize("monitor_text_line").height - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } } diff --git a/plugins/UM3NetworkPrinting/resources/qml/MonitorPrinterCard.qml b/plugins/UM3NetworkPrinting/resources/qml/MonitorPrinterCard.qml index 5a4556f1f7..e115cb14ee 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/MonitorPrinterCard.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/MonitorPrinterCard.qml @@ -4,7 +4,7 @@ import QtQuick 2.3 import QtQuick.Controls 2.0 import QtQuick.Dialogs 1.1 -import UM 1.3 as UM +import UM 1.5 as UM import Cura 1.0 as Cura /** @@ -100,10 +100,9 @@ Item width: parent.width radius: 2 * screenScaleFactor // TODO: Theme! - Label + UM.Label { text: printer && printer.name ? printer.name : "" - color: UM.Theme.getColor("text") elide: Text.ElideRight font: UM.Theme.getFont("large") // 16pt, bold width: parent.width @@ -111,8 +110,6 @@ Item // FIXED-LINE-HEIGHT: height: parent.height - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } } @@ -138,21 +135,20 @@ Item Item { id: managePrinterLink - anchors { + anchors + { top: printerFamilyPill.bottom topMargin: UM.Theme.getSize("narrow_margin").height } height: 18 * screenScaleFactor // TODO: Theme! width: childrenRect.width - Label + UM.Label { id: managePrinterText anchors.verticalCenter: managePrinterLink.verticalCenter color: UM.Theme.getColor("text_link") - font: UM.Theme.getFont("default") text: catalog.i18nc("@label link to Connect and Cloud interfaces", "Manage printer") - renderType: Text.NativeRendering } UM.RecolorImage { @@ -334,7 +330,7 @@ Item height: childrenRect.height spacing: 18 * screenScaleFactor // TODO: Theme! - Label + UM.Label { id: printerStatus anchors @@ -371,7 +367,6 @@ Item return "" } visible: text !== "" - renderType: Text.NativeRendering } Item @@ -401,7 +396,7 @@ Item height: printerNameLabel.height + printerFamilyPill.height + 6 * screenScaleFactor // TODO: Theme! visible: printer && printer.activePrintJob && !printerStatus.visible - Label + UM.Label { id: printerJobNameLabel color: printer && printer.activePrintJob && printer.activePrintJob.isActive ? UM.Theme.getColor("text") : UM.Theme.getColor("monitor_text_disabled") @@ -412,11 +407,9 @@ Item // FIXED-LINE-HEIGHT: height: 18 * screenScaleFactor // TODO: Theme! - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } - Label + UM.Label { id: printerJobOwnerLabel anchors @@ -427,14 +420,11 @@ Item } color: printer && printer.activePrintJob && printer.activePrintJob.isActive ? UM.Theme.getColor("text") : UM.Theme.getColor("monitor_text_disabled") elide: Text.ElideRight - font: UM.Theme.getFont("default") // 12pt, regular text: printer && printer.activePrintJob ? printer.activePrintJob.owner : catalog.i18nc("@label", "Anonymous") width: parent.width // FIXED-LINE-HEIGHT: height: 18 * screenScaleFactor // TODO: Theme! - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } } @@ -448,21 +438,17 @@ Item visible: printer && printer.activePrintJob && printer.activePrintJob.configurationChanges.length === 0 && !printerStatus.visible } - Label + UM.Label { anchors { verticalCenter: parent.verticalCenter } - font: UM.Theme.getFont("default") text: catalog.i18nc("@label:status", "Requires configuration changes") visible: printer && printer.activePrintJob && printer.activePrintJob.configurationChanges.length > 0 && !printerStatus.visible - color: UM.Theme.getColor("text") // FIXED-LINE-HEIGHT: height: 18 * screenScaleFactor // TODO: Theme! - verticalAlignment: Text.AlignVCenter - renderType: Text.NativeRendering } } @@ -487,17 +473,15 @@ Item radius: 2 * screenScaleFactor // Todo: Theme! } } - contentItem: Label + contentItem: UM.Label { anchors.fill: parent anchors.bottomMargin: 2 * screenScaleFactor // TODO: Theme! color: UM.Theme.getColor("monitor_secondary_button_text") font: UM.Theme.getFont("medium") // 14pt, regular text: catalog.i18nc("@action:button", "Details"); - verticalAlignment: Text.AlignVCenter horizontalAlignment: Text.AlignHCenter height: 18 * screenScaleFactor // TODO: Theme! - renderType: Text.NativeRendering } implicitHeight: 32 * screenScaleFactor // TODO: Theme! implicitWidth: 96 * screenScaleFactor // TODO: Theme! diff --git a/plugins/UM3NetworkPrinting/resources/qml/PrintJobContextMenuItem.qml b/plugins/UM3NetworkPrinting/resources/qml/PrintJobContextMenuItem.qml index 3288896572..3cedc17360 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/PrintJobContextMenuItem.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/PrintJobContextMenuItem.qml @@ -1,24 +1,25 @@ -// 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.2 import QtQuick.Controls 2.0 import QtQuick.Controls.Styles 1.4 -import UM 1.3 as UM +import UM 1.5 as UM -Button { - background: Rectangle { - opacity: parent.down || parent.hovered ? 1 : 0; +Button +{ + background: Rectangle + { + opacity: parent.down || parent.hovered ? 1 : 0 color: UM.Theme.getColor("monitor_context_menu_hover") } - contentItem: Label { - color: enabled ? UM.Theme.getColor("text") : UM.Theme.getColor("monitor_text_disabled"); + contentItem: UM.Label + { + color: enabled ? UM.Theme.getColor("text") : UM.Theme.getColor("monitor_text_disabled") text: parent.text - horizontalAlignment: Text.AlignLeft; - verticalAlignment: Text.AlignVCenter; - renderType: Text.NativeRendering; + horizontalAlignment: Text.AlignLeft } - height: visible ? 39 * screenScaleFactor : 0; // TODO: Theme! - hoverEnabled: true; - width: parent.width; + height: visible ? 39 * screenScaleFactor : 0 // TODO: Theme! + hoverEnabled: true + width: parent.width } |