Force emoji presentation

Append a variation selector to the Emoji sequences,
to force Emoji presentation. Without this, some
Emoji come out with text presentation by default.

Closes: Pango #334
This commit is contained in:
Matthias Clasen
2018-11-27 18:16:43 -05:00
parent be75460913
commit aac38198a3
2 changed files with 2 additions and 0 deletions

View File

@ -392,6 +392,7 @@ add_emoji (GtkWidget *box,
p += g_unichar_to_utf8 (code, p);
}
g_variant_unref (codes);
p += g_unichar_to_utf8 (0xFE0E, p); /* U+FE0F is the Emoji variation selector */
p[0] = 0;
label = gtk_label_new (text);

View File

@ -474,6 +474,7 @@ get_text (GVariant *emoji_data,
p += g_unichar_to_utf8 (code, p);
}
g_variant_unref (codes);
p += g_unichar_to_utf8 (0xFE0F, p); /* U+FE0F is the Emoji variation selector */
p[0] = 0;
}