summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/TimelineItem.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/TimelineItem.cc b/src/TimelineItem.cc

index 12ebcfde..66c55f0c 100644 --- a/src/TimelineItem.cc +++ b/src/TimelineItem.cc
@@ -44,6 +44,8 @@ void TimelineItem::init() const int baseWidth = fm.width('A'); MessageMargin = baseWidth * 1.5; + EmojiSize = this->font().pointSize() * EmojiFontRatio; + topLayout_ = new QHBoxLayout(this); sideLayout_ = new QVBoxLayout(); mainLayout_ = new QVBoxLayout(); @@ -289,7 +291,9 @@ QString TimelineItem::replaceEmoji(const QString &body) // TODO: Be more precise here. if (code > 9000) - fmtBody += "<span style=\"font-family: Emoji One; font-size: 14px\">" + QString(c) + "</span>"; + fmtBody += QString("<span style=\"font-family: Emoji One; font-size: %1px\">").arg(EmojiSize) + + QString(c) + + "</span>"; else fmtBody += c; }