# How to add emojis as subtitle?

**URL:** <https://forums.unrealengine.com/t/how-to-add-emojis-as-subtitle/429718>\
**Category:** UI\
**Tags:** subtitles, text, unreal-engine, Blueprint, question\
**Created:** [July 18, 2018, 9:38pm UTC](https://forums.unrealengine.com/t/how-to-add-emojis-as-subtitle/429718 "2018-07-18T21:38:25Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_39b86b86](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_39b86b86](https://forums.unrealengine.com/u/anonymous_user_39b86b86)\
**Post date:** [July 18, 2018, 9:38pm UTC](https://forums.unrealengine.com/t/how-to-add-emojis-as-subtitle/429718/1 "2018-07-18T21:38:25Z")

</div>

I would like to display emoji and text when the player coming close to something. But I failed to insert emoji as “text”. How should I fix this problem (with Hub)?

---

<div class="post-metadata">

**Author:** ![Shadowriver](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Shadowriver](https://forums.unrealengine.com/u/Shadowriver)\
**Post date:** [July 19, 2018, 3:43am UTC](https://forums.unrealengine.com/t/how-to-add-emojis-as-subtitle/429718/2 "2018-07-19T03:43:03Z")

</div>

Sadly it seems Slate (UE4 UI system) does not support surrogating in UTF-16 properly (but it display last resort properly for some reason) and can only display 16-bit characters (from 0x0000 to 0xFFFF) while emoji is between 0x1F900 to 0x1F9FF making it technically UTF-32 (beyond 16-bit) characters and in order to access from UTF-16 which encoding that UE4 is using it needs to support surrogate character sequences and Slate seems to not display font with those characters properly, while it seem to detect use of Plane 1 (0x10000-0x1FFFF) and display Plane 1 LastResort character (the squere icon informing there missing font for that character, increase font size UMG editor). There possibility that issue is in font importing rether then displaying

You can try to investigate yourself, in order to even start thinking to display emoji at all you need to get a font that has emoji, you can experiment with Nato Emoji font:

> **[Noto Emoji Font | Google | FontSpace](https://www.fontspace.com/noto-emoji-font-f22283)**
>
> Free download of Noto Emoji Font. Released in 2015 by Google and licensed for personal and commercial-use. Click now to create a custom image with your own words that you can download.

[Importing Fonts in Unreal Engine | Unreal Engine 5.1 Documentation](https://docs.unrealengine.com/en-us/Engine/UMG/UserGuide/Fonts/HowTo/ImportingFonts) - this is info on font importing

This should be enough… but as mentioned above there some issues displaying characters above 0xFFFF range

If current issues you might try using private use range charaters (0xE000-0xF8FF) in early days when emoji was only used in Japan they used that range but you need font that has emoji on that range and you need to convert your subtitles to use them, UE4 should not have problem displaying those.

Here you have some useful links:  
[Character Encoding in Unreal Engine | Unreal Engine 5.1 Documentation](https://docs.unrealengine.com/en-US/Programming/UnrealArchitecture/StringHandling/CharacterEncoding) - overall information about character encoding in UE4

[Universal Character Set characters - Wikipedia](https://en.wikipedia.org/wiki/Universal_Character_Set_characters#Surrogates) - below you have info about private use range

[Full Emoji List, v15.0](https://unicode.org/emoji/charts/full-emoji-list.html) - list of emoji characters in unicode

Also note some mobile OSes consider characters in 16-bit range (0x0000-0xFFFF) range as emoji and display colorful image, most notibly gender symbols, card symbols, arrows, stars, zodiac symbols etc. but those are old characters used in unicode way before emoji became a thing and they should normally be displayed as they sit below 0xFFFF if you have proper font imported to UE4

---

<div class="post-metadata">

**Author:** ![Shadowriver](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Shadowriver](https://forums.unrealengine.com/u/Shadowriver)\
**Post date:** [July 19, 2018, 4:27am UTC](https://forums.unrealengine.com/t/how-to-add-emojis-as-subtitle/429718/3 "2018-07-19T04:27:07Z")

</div>

I submitted a bug with result of my investigation as it seem support of surrogated characters is half way done, so they either need to move that forward or remove sign of support of those that i noticed. I will see what will happen, im unicode maniac myself it would be nice to see support for that ;] But considering it is not that important i would not expect for this to be fixed quick.

---

<div class="post-metadata">

**Author:** ![Shadowriver](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Shadowriver](https://forums.unrealengine.com/u/Shadowriver)\
**Post date:** [July 19, 2018, 11:36pm UTC](https://forums.unrealengine.com/t/how-to-add-emojis-as-subtitle/429718/4 "2018-07-19T23:36:17Z")

</div>

I got this to responce of my bug raport… and it seems they not expected to support surrogates, so only solution would be either what i meantied use of private use zone or try implment something in C++ as with slate you can control widget rendering on quite low level, but as said below it is more preformance heavy task:

> We store our FString characters in 16  
> bits (Essentially UCS-2), so anything  
> outside of the Basic Multilingual  
> Plane will be cut off. You can find  
> more information on our Character  
> Encoding page:  
> [Character Encoding in Unreal Engine | Unreal Engine 5.3 Documentation](https://docs.unrealengine.com/en-us/Programming/UnrealArchitecture/StringHandling/CharacterEncoding#ue4internalstringrepresentation)
> 
> Unicode does provide a block of  
> Surrogate codepoints that can be  
> paired up, so you could detect that a  
> character is out of bounds, but by  
> then you’ve lost the second half.  
> Upping our character type to 32 bits  
> would double the memory footprint of  
> text across the board, which  
> definitely isn’t desirable. UTF-8/16  
> supports codepoints of varying byte  
> length, but the performance hit for  
> decoding it would be untenable. We can  
> definitely render the Symbols  
> ([http://unicode.org/charts/PDF/U2600.pdf](http://unicode.org/charts/PDF/U2600.pdf))  
> block, as long as you use a font that  
> includes those characters.
