Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Emoji support #193

Open
cquencer opened this issue Apr 7, 2012 · 0 comments
Open

Add Emoji support #193

cquencer opened this issue Apr 7, 2012 · 0 comments

Comments

@cquencer
Copy link
Contributor

cquencer commented Apr 7, 2012

Reported by @stipsan

Emoji is now a new standard in Unicode 6.0.
http://en.wikipedia.org/wiki/Emoji
iOS have supported it since iOS 3.0 if you're on a Japanese carrier (or used a hack to enable the keyboard), but now that Emoji is a standard in Unicodes latest specification iOS5 supports it on any carrier and OS X Lion also supports it.

So the idea is to use Emoji when supported, and tag fallbacks for those who don't. So the smiley areas will show as text, like :P before the js replaces them on first load.
Then, a cookie is set, and a session state, that sets wether Emoji is supported or not depending a string length check I came up with.
If the OS supports Emoji, "[insert emoji emoticon here]".length will return 2, while when unsupported it'll return 4 as the length.
This technique is basically the same as the well known technique used to detect wether the OS can support two-byte japanese characters or not, as they would return 1 as the length when supported, 2 when not.

Not only would this feature support converting regular smileys to emoji to reduce bandwidth and increase quality were plausible.
But also ensure that if an iOS device, or a Lion machine can enter Emoji symbols and have them display on devices that actually don't support them by converting them to regular smileys behind the scenes.

Other than that, the Emoji functionality would be hardcoded with only an on/off switch. No need to customize it.
The other smiley functionality we're planning are separate, but would be integrated. So if you have a :) smiley defined, the non-emoji fallback would use your custom smiley over the core one.

This feature is just for kicks, so setting to lowest priority.

Here's something fun to read that's related: http://www.panic.com/blog/2011/07/the-worlds-first-emoji-domain/

Ref: #734

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant