libcmml
0.9.1
|
CMML is designed to provide full internationalisation (i18n) support, covering different character sets as well as languages and their differing directionality. Any tag or attribute that could end up containing text in a different language to the other tags may specify their own language.
As a CMML file is an XML file by definition, the xml processing instruction provides for a file-specific specification of the encoding format in its "encoding" tag. A potentially differing character set for an INPUT media file will be specified in the "contenttype" attribute of the source tag as a parameter to the MIME type.
Different languages and their directionality for display purposes are given for every tag that contains human-readable text as a value of either an attribute or a tag. They are specified in the lang and dir attributes.
The root cmml tag's "lang" and "dir" attributes provide the default language for the whole CMML file.
The source tag in the stream tag has i18n support as its "title" attribute may contain human readable text.
The head tag has i18n support to provide a default language to its contained tags such as the title and meta tags. Both of them may incidentally overrun the defaults by having a language specification of their own.
The clip tag again contains a default language for the clip itself. The a, img, desc, and meta tags may each override the default language.
Here is an example of a multi-lingual CMML file:
The document is generally in Polish (see lang attribute of cmml tag). The lang atttribute of the head tag makes all head tags and attributes be English. The lang attribute of the first clip tag makes all of them be German, though this is overrun by the lang attribute of the desc tag, making that one English. The last clip tag is in English, but it has a meta tag in French.