Python implementation of kakasi - kana kanji simple inversion library
Project description
=======
Pykakasi
=======
pykakasi is re-imprelemtation of kakasi library by Python.
How To Use pykakasi
==================
::
import pykakasi.kakasi as kakasi
kakasi = kakasi()
kakasi.setMode("H","a") # default: Hiragana -> Roman
kakasi.setMode("K","a") # default: Katakana -> Roman
kakasi.setMode("J","a") # default: Japanese -> Roman
kakasi.setMode("r","Hepburn") # default: use Hepburn Roman table
kakasi.setMode("s", True) # default: Separator
kakasi.setMode("C", True) # default: Capitalize
conv = kakasi.getConverter()
result = conv.do(text)
You can use output `Mode` values from "H", "K", "a" which is each means
"Hiragana", "Katakana" and "alphabet".
For input, you can use "J" that means "Japanese" that is
mixture of Kanji, Katakana and Hiragana.
Also there is values of "H", "K" that means "Hiragana", and "Katakana".
You can use "Hepburn" or "Kunrei" as mode "r", Roman table switch.
Also "s" used for separator switch, "C" for capitalize switch.
Pykakasi
=======
pykakasi is re-imprelemtation of kakasi library by Python.
How To Use pykakasi
==================
::
import pykakasi.kakasi as kakasi
kakasi = kakasi()
kakasi.setMode("H","a") # default: Hiragana -> Roman
kakasi.setMode("K","a") # default: Katakana -> Roman
kakasi.setMode("J","a") # default: Japanese -> Roman
kakasi.setMode("r","Hepburn") # default: use Hepburn Roman table
kakasi.setMode("s", True) # default: Separator
kakasi.setMode("C", True) # default: Capitalize
conv = kakasi.getConverter()
result = conv.do(text)
You can use output `Mode` values from "H", "K", "a" which is each means
"Hiragana", "Katakana" and "alphabet".
For input, you can use "J" that means "Japanese" that is
mixture of Kanji, Katakana and Hiragana.
Also there is values of "H", "K" that means "Hiragana", and "Katakana".
You can use "Hepburn" or "Kunrei" as mode "r", Roman table switch.
Also "s" used for separator switch, "C" for capitalize switch.
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
pykakasi-0.22.tar.gz
(3.6 MB
view hashes)
Built Distributions
pykakasi-0.22-py3.4.egg
(2.6 MB
view hashes)
pykakasi-0.22-py3.3.egg
(2.6 MB
view hashes)
pykakasi-0.22-py2.7.egg
(2.6 MB
view hashes)