From 63bc7055c29ca56d7108ceb4f6b59bbbdc0a9b08 Mon Sep 17 00:00:00 2001 From: Joshua Goins Date: Sat, 16 Nov 2024 16:12:56 -0500 Subject: [PATCH] Default to a more sensible sticker size If we do not set the width/height for stickers (which don't have any) then the height is okay, but the message has the maximum width which looks odd. Instead, let's limit all stickers to 256px and it makes them look much nicer in chat. --- src/timeline/ImageComponent.qml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/timeline/ImageComponent.qml b/src/timeline/ImageComponent.qml index 0e8dfa592..3cc90b012 100644 --- a/src/timeline/ImageComponent.qml +++ b/src/timeline/ImageComponent.qml @@ -184,8 +184,8 @@ Item { MediaSizeHelper { id: mediaSizeHelper contentMaxWidth: root.maxContentWidth - mediaWidth: root?.mediaInfo.width ?? 0 - mediaHeight: root?.mediaInfo.height ?? 0 + mediaWidth: root?.mediaInfo.isSticker ? 256 : (root?.mediaInfo.width ?? 0) + mediaHeight: root?.mediaInfo.isSticker ? 256 : (root?.mediaInfo.height ?? 0) } QtObject {