From 96398daa783da04d57aadfb16a5a7f2f0f3423f2 Mon Sep 17 00:00:00 2001 From: John Preston Date: Fri, 29 Nov 2024 11:25:29 +0400 Subject: [PATCH] Beta version 5.8.5: Fix build with Xcode. --- Telegram/SourceFiles/ui/chat/chats_filter_tag.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Telegram/SourceFiles/ui/chat/chats_filter_tag.cpp b/Telegram/SourceFiles/ui/chat/chats_filter_tag.cpp index 3e799aa02..aa1b4bff2 100644 --- a/Telegram/SourceFiles/ui/chat/chats_filter_tag.cpp +++ b/Telegram/SourceFiles/ui/chat/chats_filter_tag.cpp @@ -29,14 +29,15 @@ QImage ChatsFilterTag(QString roundedText, QColor color, bool active) { auto emojiLength = 0; if (const auto emoji = Ui::Emoji::Find(ch, end, &emojiLength)) { const auto factor = style::DevicePixelRatio(); - emojiReplacements.emplace_back( - Ui::Emoji::SinglePixmap( + emojiReplacements.push_back({ + .pixmap = Ui::Emoji::SinglePixmap( emoji, st::normalFont->height * factor).scaledToHeight( roundedFont->ascent * factor, Qt::SmoothTransformation), - ch - roundedText.constData(), - emojiLength); + .from = int(ch - roundedText.constData()), + .length = emojiLength, + }); ch += emojiLength; } else { ch++;