Comment on Emoji Under the HoodparentComments−petepete5yI've never seen them use, have they actually been implemented by any of the creators?−mannerheim5yIf I type the following into ghci, I get the state flag of Texas:putStrLn "\x1f3f4\xe0075\xe0073\xe0074\xe0078\xe007f"The first character is a flag, the last character is a terminator, and in between are the tag characters corresponding to the ASCII for ustx. Just take those characters and subtract 0xe0000 from them, 0x75, 0x73, 0x74, 0x78.https://en.wikipedia.org/wiki/Tags_(Unicode_block)Edit:Just for fun:import Data.StateCodesimport Data.CharputStrLn $ map (map toLower . show . snd) allStates >>=\stateCode -> '\x1f3f4':map (toEnum . (0xe0000+) . fromEnum) ("us" ++ stateCode) ++ "\xe007f"−petepete5yYeah I understand how it works but none of the major vendors have actually implemented the emoji.https://emojipedia.org/flag-for-texas-ustx/−mannerheim5yTouché.−azornathogron5yOh my god they've put terminal escape codes into Unicode.
Comments
I've never seen them use, have they actually been implemented by any of the creators?
If I type the following into ghci, I get the state flag of Texas:
putStrLn "\x1f3f4\xe0075\xe0073\xe0074\xe0078\xe007f"
The first character is a flag, the last character is a terminator, and in between are the tag characters corresponding to the ASCII for ustx. Just take those characters and subtract 0xe0000 from them, 0x75, 0x73, 0x74, 0x78.
https://en.wikipedia.org/wiki/Tags_(Unicode_block)
Edit:
Just for fun:
import Data.StateCodes
import Data.Char
putStrLn $ map (map toLower . show . snd) allStates >>=
\stateCode -> '\x1f3f4':map (toEnum . (0xe0000+) . fromEnum) ("us" ++ stateCode) ++ "\xe007f"
Yeah I understand how it works but none of the major vendors have actually implemented the emoji.
https://emojipedia.org/flag-for-texas-ustx/
Touché.
Oh my god they've put terminal escape codes into Unicode.