diff --git a/plugins/Toolbox/resources/images/placeholder.svg b/plugins/Toolbox/resources/images/placeholder.svg new file mode 100644 index 0000000000..cc674a4b38 --- /dev/null +++ b/plugins/Toolbox/resources/images/placeholder.svg @@ -0,0 +1,3 @@ + + + diff --git a/plugins/Toolbox/resources/qml/components/ToolboxDownloadsGridTile.qml b/plugins/Toolbox/resources/qml/components/ToolboxDownloadsGridTile.qml index 78cdf1562a..49c8c4573e 100644 --- a/plugins/Toolbox/resources/qml/components/ToolboxDownloadsGridTile.qml +++ b/plugins/Toolbox/resources/qml/components/ToolboxDownloadsGridTile.qml @@ -66,8 +66,10 @@ Item anchors.centerIn: parent width: UM.Theme.getSize("toolbox_thumbnail_small").width - UM.Theme.getSize("wide_margin").width height: UM.Theme.getSize("toolbox_thumbnail_small").height - UM.Theme.getSize("wide_margin").width + sourceSize.width: width + sourceSize.height: height fillMode: Image.PreserveAspectFit - source: model.icon_url || "../../images/logobot.svg" + source: model.icon_url || "../../images/placeholder.svg" mipmap: true } UM.RecolorImage diff --git a/plugins/Toolbox/resources/qml/components/ToolboxDownloadsShowcaseTile.qml b/plugins/Toolbox/resources/qml/components/ToolboxDownloadsShowcaseTile.qml index f6e32b2d84..1ee38b02e5 100644 --- a/plugins/Toolbox/resources/qml/components/ToolboxDownloadsShowcaseTile.qml +++ b/plugins/Toolbox/resources/qml/components/ToolboxDownloadsShowcaseTile.qml @@ -22,8 +22,10 @@ Rectangle id: thumbnail height: UM.Theme.getSize("toolbox_thumbnail_large").height - 4 * UM.Theme.getSize("default_margin").height width: UM.Theme.getSize("toolbox_thumbnail_large").height - 4 * UM.Theme.getSize("default_margin").height + sourceSize.height: height + sourceSize.width: width fillMode: Image.PreserveAspectFit - source: model.icon_url || "../../images/logobot.svg" + source: model.icon_url || "../../images/placeholder.svg" mipmap: true anchors { diff --git a/plugins/Toolbox/resources/qml/dialogs/CompatibilityDialog.qml b/plugins/Toolbox/resources/qml/dialogs/CompatibilityDialog.qml index 17bbdba4c5..b33036847b 100644 --- a/plugins/Toolbox/resources/qml/dialogs/CompatibilityDialog.qml +++ b/plugins/Toolbox/resources/qml/dialogs/CompatibilityDialog.qml @@ -68,9 +68,11 @@ UM.Dialog{ Image { id: packageIcon - source: model.icon_url || "../../images/logobot.svg" + source: model.icon_url || "../../images/placeholder.svg" height: lineHeight width: height + sourceSize.height: height + sourceSize.width: width mipmap: true fillMode: Image.PreserveAspectFit } @@ -111,9 +113,11 @@ UM.Dialog{ Image { id: packageIcon - source: model.icon_url || "../../images/logobot.svg" + source: model.icon_url || "../../images/placeholder.svg" height: lineHeight width: height + sourceSize.height: height + sourceSize.width: width mipmap: true fillMode: Image.PreserveAspectFit } diff --git a/plugins/Toolbox/resources/qml/dialogs/ToolboxLicenseDialog.qml b/plugins/Toolbox/resources/qml/dialogs/ToolboxLicenseDialog.qml index dd0237eada..6e6df2ee67 100644 --- a/plugins/Toolbox/resources/qml/dialogs/ToolboxLicenseDialog.qml +++ b/plugins/Toolbox/resources/qml/dialogs/ToolboxLicenseDialog.qml @@ -53,8 +53,10 @@ UM.Dialog id: icon width: 30 * screenScaleFactor height: width + sourceSize.width: width + sourceSize.height: height fillMode: Image.PreserveAspectFit - source: licenseModel.iconUrl || "../../images/logobot.svg" + source: licenseModel.iconUrl || "../../images/placeholder.svg" mipmap: true } diff --git a/plugins/Toolbox/resources/qml/pages/ToolboxAuthorPage.qml b/plugins/Toolbox/resources/qml/pages/ToolboxAuthorPage.qml index 2baa8b5210..acc6140b5b 100644 --- a/plugins/Toolbox/resources/qml/pages/ToolboxAuthorPage.qml +++ b/plugins/Toolbox/resources/qml/pages/ToolboxAuthorPage.qml @@ -33,7 +33,7 @@ Item width: UM.Theme.getSize("toolbox_thumbnail_medium").width height: UM.Theme.getSize("toolbox_thumbnail_medium").height fillMode: Image.PreserveAspectFit - source: details.icon_url || "../../images/logobot.svg" + source: details.icon_url || "../../images/placeholder.svg" mipmap: true anchors { diff --git a/plugins/Toolbox/resources/qml/pages/ToolboxDetailPage.qml b/plugins/Toolbox/resources/qml/pages/ToolboxDetailPage.qml index 94caafb00b..3cd881af63 100644 --- a/plugins/Toolbox/resources/qml/pages/ToolboxDetailPage.qml +++ b/plugins/Toolbox/resources/qml/pages/ToolboxDetailPage.qml @@ -46,8 +46,12 @@ Item { anchors.fill: parent fillMode: Image.PreserveAspectFit - source: details === null ? "" : (details.icon_url || "../../images/logobot.svg") + source: details === null ? "" : (details.icon_url || "../../images/placeholder.svg") mipmap: true + height: UM.Theme.getSize("toolbox_thumbnail_large").height - 4 * UM.Theme.getSize("default_margin").height + width: UM.Theme.getSize("toolbox_thumbnail_large").height - 4 * UM.Theme.getSize("default_margin").height + sourceSize.height: height + sourceSize.width: width } }