You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@ltlnx It's because the Emoji support in Guileless Bopomofo is implemented by a dirty hack. To give a fully, well designed implementation, I have to spend time to modify the internal design of libchewing, it's a big challenge for me, frankly speaking I can't promise you a milestone or schedule, but I knew the issue and want to solve it.
This issue is also related to android.widget.TextView#getOffsetForPosition which is have weird difficulty to locate character offset correctly, if there is a string like the example provided which has Emoji(s).
Anyway, to solve this issue, I have to consider the nature of Emoji, that is encoded as variant bytes.
As an example like the following screenshot shown, the "貓咪🐈" pre-edit buffer string is encoded as UTF-8 as 0xe8, 0xb2, 0x93("貓"), 0xe5, 0x92, 0xaa("咪"), 0xf0, 0x9f, 0x90, 0x88("🐈"). We can find that each character has different size of bytes.
When there are Emojis and Chinese mixed in the choosing area, the word-choosing behavior is strange. As in the attachments.
The text was updated successfully, but these errors were encountered: