Closed bertfrees closed 4 years ago
For total flexibility it should also be possible to use system: braille-translator in named @text-transform rules.
This has been implemented in https://github.com/daisy/pipeline-modules/commit/210d49d3b9d8c05aea7f5e3adbeb2f9e76bed0e7.
Remaining part fixed in https://github.com/daisy/pipeline-modules/commit/4c46c85f2c3d2818c29c1598595dad8434198e84.
In general, specifying details about the translation in CSS is not such a great idea. Braille translation is typically something that the user may wish to control. It's up to the application to apply the correct translation, based on the locale and on user preferences.
However in certain cases it might actually make sense to specify translation details in CSS, or at least a default that can be overwritten. For example, it would be perfectly acceptable that a CSS style sheet says that the text should by default be transcribed with a certain contraction grade:
Specifying a translator that is specific to the DAISY Pipeline implementation is not advisable because it makes the CSS not portable. But even for this there might be use cases. For example, if for some reason you need to include a Liblouis table inside an EPUB, you could use this CSS:
For total flexibility it should also be possible to use
system: braille-translator
in named@text-transform
rules. Note that named@text-transform
rules are already supported in Pipeline (although none of the default translators do anything with it, and it's not in the braille CSS spec yet). Global@text-transform
rules like in the examples above are something new. They correspond totext-transform: auto
.Below is an example of using
system: braille-translator
in a named@text-transform
rule:Note that this specific rule is already implicitly defined today (implemented here)!