A ctypes-based OpenCC converter for Chinese.
Project description
An OpenCC converter for Python.
Installation
You should install OpenCC (1.0.x) library first.
Install the python library with pip:
$ pip install OpenCC
Features
Compatible with CPython and PyPy (c-types)
Cython implementation (TODO)
Usage
This library has only one method:
>>> import opencc
>>> opencc.convert('乾坤一擲')
>>> opencc.convert('乾坤一掷', config='s2t.json')
Config
Convert method accepts an additional config parameter. Available configs:
hk2s.json s2hk.json s2t.json s2tw.json s2twp.json t2s.json tw2s.json tw2sp.json
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file OpenCC-0.2.tar.gz.
File metadata
- Download URL: OpenCC-0.2.tar.gz
- Upload date:
- Size: 6.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bfca25fb46add057454075ba4c4dfed51c19c09944a960e3920ac22ba24097e2
|
|
| MD5 |
047bd2d40643177282b0662ea1fc1476
|
|
| BLAKE2b-256 |
56fb5a7224ede65ac6271d163fcee81d4cb84f42a40667271f970faab97840df
|
File details
Details for the file OpenCC-0.2-py2-none-any.whl.
File metadata
- Download URL: OpenCC-0.2-py2-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 2
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c845abfcd6936ea110ff19de0da85e5ed99953cb03836be975bd0d5b163618e1
|
|
| MD5 |
72108fec8308b89b0158f7ed6cd2e9b5
|
|
| BLAKE2b-256 |
0818951a89e4638db357184d0acf338a89b7b8e48cf6c242243fe193d201dc5c
|