Skip to content
This repository was archived by the owner on Apr 29, 2021. It is now read-only.

Commit a69d0b0

Browse files
author
Yuncong Zhang
committed
Fix single char emoji range issue.
1 parent c6f829c commit a69d0b0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Runtime/ui/txt/emoji.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -255,11 +255,11 @@ public static Rect getUVRect(int code) {
255255
}
256256

257257
public static bool isSingleCharEmoji(int c) {
258-
return (0x2100 <= c && c < 0x3300) || isEmptyEmoji(c);
258+
return emojiLookupTable.ContainsKey(c) || isEmptyEmoji(c);
259259
}
260260

261261
public static bool isSingleCharNonEmptyEmoji(int c) {
262-
return 0x2100 <= c && c < 0x3300;
262+
return emojiLookupTable.ContainsKey(c);
263263
}
264264

265265
public static bool isEmptyEmoji(int c) {

0 commit comments

Comments
 (0)