mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-09-04 16:45:12 +00:00
Fix repainting of custom emoji in notifications.
This commit is contained in:
@@ -771,7 +771,10 @@ void Notification::repaintText() {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Painter p(&_cache);
|
Painter p(&_cache);
|
||||||
p.fillRect(_textRect, st::notificationBg);
|
const auto adjusted = Ui::Text::AdjustCustomEmojiSize(st::emojiSize);
|
||||||
|
const auto skip = (adjusted - st::emojiSize + 1) / 2;
|
||||||
|
const auto margin = QMargins{ skip, skip, skip, skip };
|
||||||
|
p.fillRect(_textRect.marginsAdded(margin), st::notificationBg);
|
||||||
paintText(p);
|
paintText(p);
|
||||||
update();
|
update();
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user