Translate chinese word to bopomofo
Project description
Translate 漢字 to ㄅㄆㄇㄈ, based on lxneng/xpinyin.
Install
pip install bopomofo
Usage
>>> from bopomofo import to_bopomofo
>>> to_bopomofo(u'注音')
'ㄓㄨˋ ㄧㄣ'
>>> to_bopomofo(u'注音', tones=False)
'ㄓㄨ ㄧㄣ'
>>> to_bopomofo(u'注音', u'、')
'ㄓㄨˋ、ㄧㄣ'
>>> bopomofo.to_bopomofo(u'注音', first_tone_symbol=True)
'ㄓㄨˋ ㄧㄣˉ'
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
bopomofo-0.1.2.tar.gz
(5.1 kB
view hashes)
Built Distribution
Close
Hashes for bopomofo-0.1.2-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9c41576f36ce4452f7351007254e99fbe1d172e969c3d73c5bf04727e054854d |
|
MD5 | 3941aaa45f10866f5e700818dd0ac236 |
|
BLAKE2b-256 | 4031bc958570dc714573b7d906f9ab97d27d9a96ec523659f91fd605b8441b53 |