Re: [orca-list] contracted braille



For doing the contracted braille in orca, it could use something such as
liblouis (www.jjb-software.com). This can do braille translation in both
directions, has tables for a few braille codes, and also is open source.
I have used it in some of my own projects written in python, and it
seems to work fine. You would need to write a python API for it, I have
done that before using ctypes. The one problem I did have when
interfacing with ctypes, which is relevant to mention here, is that if
someone has compiled python from source with 32-bit unicode then you
will need to convert to 16-bit unicode as that is what liblouis uses. I
don't know of any python function to check if python is using unicode32
or unicode16, but I managed to do it by comparing the results from len
and sizeof from a ctypes unicode buffer (create_unicode_buffer), the
relationship should be a multiple of 2 if unicode16 is used and 4 if
unicode32 is used (one gives the number of characters and the other
gives number of bytes and then you can calculate number of bytes per
character). I may be making more of this than is necessary, but I have
found this to be so in one distro of Linux I have used.

From
Michael Whapples




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]