Skip to content

Use less "magic" characters in dtbook2sbsform.xsl and the liblouis tables #1

@bertfrees

Description

@bertfrees

... because it makes the XSLT and the liblouis tables very tied on each other, and hard to understand.

The main purpose of the magic characters (U+256C, U+250B, U+250A, etc.) is to convey the necessary "context information" to the liblouis table, context that would otherwise be lost because text nodes are processed one by one.

A better, more intuitive approach would be to just send the real context to liblouis. This is possible with the latest version of liblouis-core. The following xpath expression translates $text with some context before and after:

louis:translate($table, ($context-before,$text,$context-after))[2]

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions