-
Notifications
You must be signed in to change notification settings - Fork 6
Description
I noticed that SQF has language support. People love their own language. There're a couple of things that I was missing:
- You can mark sqf:description of sqf:title with a language, but you cannot add more than 1. I lean towards making sqf:description repeatable for a multi lingual fix, rather than sqf:title, so I can have proper sqf:p text associated. However: then I do not see the point of having @xml:lang on nodes under sqf:description.
- I also lean towards letting the sqf processor decide on fallback when the UI language of choice is not available, but by convention you could say the first available sqf:description is the default.
This would do it for my purposes:
<sqf:fix id="addHyphen">
<sqf:description xml:lang="en-US">
<sqf:title>Add Hyphen</sqf:title>
</sqf:description>
<sqf:description xml:lang="de-DE">
<sqf:title>Bindestrich hinzufügen</sqf:title>
</sqf:description>
<sqf:description xml:lang="nl-NL">
<sqf:title>Hyphen toevoegen</sqf:title>
</sqf:description>
<sqf:replace match="@Prefix" target="prefix" node-type="attribute">
<sch:value-of select="concat(.,'-')"/>
</sqf:replace>
</sqf:fix>
We deploy a solution that generates Schematron with localized asset/report texts. As far as we know Schematron itself only does 1 language per file hence either English, German or Dutch. In principle this means that we only need one sqf language at a time, but we always wished we did not have to generate multiple instances of the Schematron and with sqf it seems within reach through the descriptions.