the next PyHyphen release should contain the following new features
(status report below; docs yet to be updated):
1. Use new C library hyphen-2.7
New C sources are in the hg repo.
ran some tests on Python26 and above,
should work properly on older versions,
but as I cannot compile with Python 2.4 and 2.5. Any compiling help
would be great.
2. Use list of available dicts
As highlighted by someone on this list, the oo team provides a file with
metadate on dictionaries. The current tip revision has the following
additional features:
- hyphen.dictools: new function to download the metadata file from the
oo website or any other specified uri and store it locally in a pickle file
- setup.py: call the previous function to install the metadate at
installation time
- hyphen: try to load the metadate from the pickle file and expose it to
the user
- Hyphenator(): if metadata is available, use it to allow alias names
(e.g. use de_DE instead of de_AT or de_CH), and expose the metadata as
an attribute so apps can build on it.
3. Installation process
There are a number of modifications:
- the code was simplified. setup.py now works both with Python 2.x and
3.x, so no separate scripts are needed. Also, the old hyphen_config
script is gone. Everything is now in setup.py.
- the metadata file is installed at installation time
- hyphenation dictionaries for en_US and the locale language are
installed by setup.py rather than having the dictionary for en_US ship
with the distribution. This is convenient and elegant but may raise
packaging problems.
4. Move to the PEP 384 stable C API
I would like to do this, but don't have time. If someone could jump in
by sending me a patched hnjmodule.c, this would be great.
Leo