From 508c2bee469e62368da64b30f3f440e8811f51a6 Mon Sep 17 00:00:00 2001 From: Joshua Goins Date: Wed, 14 Jan 2026 20:42:47 -0500 Subject: [PATCH] Don't show "Hide Image" button for really tiny images Otherwise, it looks really buggy. --- src/messagecontent/ImageComponent.qml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/messagecontent/ImageComponent.qml b/src/messagecontent/ImageComponent.qml index 22e38b4da..5acf15bb9 100644 --- a/src/messagecontent/ImageComponent.qml +++ b/src/messagecontent/ImageComponent.qml @@ -47,10 +47,13 @@ Item { implicitHeight: mediaSizeHelper.currentSize.height QQC2.Button { + id: hideButton + anchors.right: parent.right anchors.top: parent.top anchors.margins: Kirigami.Units.smallSpacing - visible: !_private.hideImage + // For tiny images, having the button looks super buggy at their size + visible: !_private.hideImage && root.width >= hideButton.width && root.height >= hideButton.height icon.name: "view-hidden" text: i18nc("@action:button", "Hide Image") display: QQC2.Button.IconOnly