From bf168388dd49e61797e8fd2528279accd1dab909 Mon Sep 17 00:00:00 2001 From: casper Date: Wed, 1 Dec 2021 10:29:21 +0100 Subject: [PATCH 1/2] Change styling of "Search in the browser" button in the marketplace To comply with the UX design. cura 8563 --- plugins/Marketplace/resources/qml/Marketplace.qml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plugins/Marketplace/resources/qml/Marketplace.qml b/plugins/Marketplace/resources/qml/Marketplace.qml index 39a7557de6..471c7523cb 100644 --- a/plugins/Marketplace/resources/qml/Marketplace.qml +++ b/plugins/Marketplace/resources/qml/Marketplace.qml @@ -168,7 +168,10 @@ Window iconSource: UM.Theme.getIcon("LinkExternal") isIconOnRightSide: true - font: UM.Theme.getFont("default") + height: UM.theme.getSize("standard_list_lineheight").height + + textFont: UM.Theme.getFont("default") + textColor: UM.Theme.getColor("text") onClicked: content.item && Qt.openUrlExternally(content.item.searchInBrowserUrl) } From bd9722654cd579532aae45e00924f8346b72e402 Mon Sep 17 00:00:00 2001 From: casper Date: Wed, 1 Dec 2021 11:45:30 +0100 Subject: [PATCH 2/2] Use FontMetrics component to calculate the line height cura 8563 --- plugins/Marketplace/resources/qml/Marketplace.qml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/plugins/Marketplace/resources/qml/Marketplace.qml b/plugins/Marketplace/resources/qml/Marketplace.qml index 471c7523cb..1773066bbd 100644 --- a/plugins/Marketplace/resources/qml/Marketplace.qml +++ b/plugins/Marketplace/resources/qml/Marketplace.qml @@ -162,15 +162,20 @@ Window } } + FontMetrics + { + id: fontMetrics + font: UM.Theme.getFont("default") + } + Cura.TertiaryButton { text: catalog.i18nc("@info", "Search in the browser") iconSource: UM.Theme.getIcon("LinkExternal") isIconOnRightSide: true - height: UM.theme.getSize("standard_list_lineheight").height - - textFont: UM.Theme.getFont("default") + height: fontMetrics.height + textFont: fontMetrics.font textColor: UM.Theme.getColor("text") onClicked: content.item && Qt.openUrlExternally(content.item.searchInBrowserUrl)