louisHelper module

Helper module to ease communication to and from liblouis.

louisHelper._resolveTableInner(tables: list[str], base: str | None = None) Generator[str, None, None]

Helper function to resolve braille table file names to file paths. This is used by the L{_resolveTable} function to abstract the inner workings from the ctypes related conversion of input and output. :param tables: List of table names. :param base: The base table (e.g. the table that contains include opcodes for the given tables). :returns: A generator that yields the paths for the requested tables.

louisHelper.louis_log(level, message)
louisHelper._isDebug()
louisHelper.initialize()
louisHelper.terminate()
louisHelper.translate(tableList, inbuf, typeform=None, cursorPos=None, mode=0)

Convenience wrapper for louis.translate that: * returns a list of integers instead of a string with cells, and * distinguishes between cursor position 0 (cursor at first character) and None (no cursor at all)