Can't handle emoji? Use this to treat them as plain strings, according to the description provided by unicode.
Project description
# Emoji2Text
Take a string with emoji in it. Convert them into their text based names.
```python
from emoji2text import emoji2text
emoji2text("""
Take a 🎁 of emoji like 🥑, 😞 or 🤮
and convert them to 🔠 🔡
and you'll be feeling all
🙌🏾 💪🏻 👩🔬 👨💻 💯 🎊!
""")
# Take a wrapped gift of emoji like avocado, disappointed face or face vomiting
# and convert them to input latin uppercase input latin lowercase
# and you'll be feeling all
# raising hands: medium-dark skin tone flexed biceps: light skin tone woman scientist man technologist hundred points confetti ball!
```
You can also wrap them to help differenciate each emoji like so:
```python
emoji2text("😀😂😂😎", ":")
# :grinning face::face with tears of joy::face with tears of joy::smiling face with sunglasses:
emoji2text("😀😂😂😎", "<", ">")
# <grinning face><face with tears of joy><face with tears of joy><smiling face with sunglasses>
```
Only supports Python 3 and emoji version 5.0 (2017).
If someone is interested in increasing support I'd be happy to look at any PR.
If you spot any errors, please create an issue with a failing input and expected result.
Only possible thanks to the very helpful [grapheme](https://github.com/alvinlindstam/grapheme) module.
Take a string with emoji in it. Convert them into their text based names.
```python
from emoji2text import emoji2text
emoji2text("""
Take a 🎁 of emoji like 🥑, 😞 or 🤮
and convert them to 🔠 🔡
and you'll be feeling all
🙌🏾 💪🏻 👩🔬 👨💻 💯 🎊!
""")
# Take a wrapped gift of emoji like avocado, disappointed face or face vomiting
# and convert them to input latin uppercase input latin lowercase
# and you'll be feeling all
# raising hands: medium-dark skin tone flexed biceps: light skin tone woman scientist man technologist hundred points confetti ball!
```
You can also wrap them to help differenciate each emoji like so:
```python
emoji2text("😀😂😂😎", ":")
# :grinning face::face with tears of joy::face with tears of joy::smiling face with sunglasses:
emoji2text("😀😂😂😎", "<", ">")
# <grinning face><face with tears of joy><face with tears of joy><smiling face with sunglasses>
```
Only supports Python 3 and emoji version 5.0 (2017).
If someone is interested in increasing support I'd be happy to look at any PR.
If you spot any errors, please create an issue with a failing input and expected result.
Only possible thanks to the very helpful [grapheme](https://github.com/alvinlindstam/grapheme) module.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
emoji2text-0.1.2.tar.gz
(39.7 kB
view hashes)
Built Distribution
emoji2text-0.1.2-py3-none-any.whl
(42.6 kB
view hashes)
Close
Hashes for emoji2text-0.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 912d5aa1a7779e542b91b687e4bb25ea5f27e6f4da5029720303b8dab45e4532 |
|
MD5 | 7ef4a337113054185014f2f04ee7e2a2 |
|
BLAKE2b-256 | 970774f826824ffa422b11df1b7b7c52592e5306b912eff3067f33b1e1d1dfd2 |