-
-
Notifications
You must be signed in to change notification settings - Fork 51
Description
I'm looking at this Neovide issue neovide/neovide#2990. I don't have any idea what the original issue is, but I discovered that we can't render simple emoji presentation sequences correctly https://www.unicode.org/emoji/charts/emoji-variants.html. And that may or may not be the issue.
For example from https://unicode.org/Public/emoji/latest/emoji-test.txt.
Both of these render the same for us
The clustering properly detects the emoji type https://docs.rs/swash/latest/swash/text/cluster/enum.Emoji.html, but CharCluster::map, returns the same char and glyph id. I'm not sure if they should be different or not, I don't know the specification well enough. And also, I don't see any special information that could be used in Shaper::shape_with either.
So, how are we supposed to deal emojis? Or is the swash support still incomplete?
For the reference, our current code is here https://github.com/neovide/neovide/blob/0f25975b8414e38c039b1be8173db59fb6cab7ae/src/renderer/fonts/caching_shaper.rs#L376