convert unicode characters to visibly similar ascii characters

Peter Bulychev peter.bulychev at gmail.com
Wed Jul 2 10:27:46 EDT 2008


Thank you.

That is exactly what I was looking for.

2008/7/2 Jim <jim.hefferon at gmail.com>:

> Peter Bulychev wrote:
> > I want to convert unicode character into ascii one.
> You have to make some arbitrary choices of what to translate.  Based
> on some materials on  effbot's site, and a recipe, I made
>  ftp://alan.smcvt.edu/hefferon/unicode2ascii.py
> which has at least some of what you are looking for.
>  $ grep HYPHEN unicode2ascii.py
>    u'\N{SOFT HYPHEN}':u'-',
>    u'\N{HYPHEN}':u'-',
>    u'\N{NON-BREAKING HYPHEN}':u'-',
>    u'\N{SOFT HYPHEN}': '-',
> No doubt I have some terrible gaffes and some things missing.
> Corrections appreciated.
>
> Jim
> --
> http://mail.python.org/mailman/listinfo/python-list
>



-- 
Best regards,
Peter Bulychev.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20080702/73dd151c/attachment-0001.html>


More information about the Python-list mailing list