diff options
author | redsky17 <joedonofry@gmail.com> | 2019-01-26 21:02:22 +0000 |
---|---|---|
committer | redsky17 <joedonofry@gmail.com> | 2019-01-26 21:02:22 +0000 |
commit | f7255b7b495457c169a2f83ffac19c2db0c58473 (patch) | |
tree | 42f668432e568ad0a54438045b0d491a7327dd65 /src | |
parent | Revert "Remove built-in emoji picker" (diff) | |
download | nheko-f7255b7b495457c169a2f83ffac19c2db0c58473.tar.xz |
Restore Emoji Picker, but remove forcing EmojiOne
Restored the emoji picker, but it now falls back to the system instead of forcing Emoji One. The allows users to user the picker for convenience, but doesn't enforce the emoji style on them.
Diffstat (limited to 'src')
-rw-r--r-- | src/emoji/ItemDelegate.cpp | 4 | ||||
-rw-r--r-- | src/timeline/TimelineItem.cpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/emoji/ItemDelegate.cpp b/src/emoji/ItemDelegate.cpp index 50a1b7ed..b79ae0fc 100644 --- a/src/emoji/ItemDelegate.cpp +++ b/src/emoji/ItemDelegate.cpp @@ -41,8 +41,8 @@ ItemDelegate::paint(QPainter *painter, auto emoji = index.data(Qt::UserRole).toString(); - QFont font("Emoji One"); - + // QFont font("Emoji One"); + QFont font; painter->setFont(font); painter->drawText(viewOption.rect, Qt::AlignCenter, emoji); } diff --git a/src/timeline/TimelineItem.cpp b/src/timeline/TimelineItem.cpp index 8d2343d0..1c90eade 100644 --- a/src/timeline/TimelineItem.cpp +++ b/src/timeline/TimelineItem.cpp @@ -708,7 +708,7 @@ TimelineItem::replaceEmoji(const QString &body) for (auto &code : utf32_string) { // TODO: Be more precise here. if (code > 9000) - fmtBody += QString("<span style=\"font-family: Emoji One;\">") + + fmtBody += QString("<span style=\"font-family: emoji;\">") + QString::fromUcs4(&code, 1) + "</span>"; else fmtBody += QString::fromUcs4(&code, 1); |