considering my last question just above, if you choose the <tag> only version , xml might look like this:
HTML Code:
<?xml version="1.0" encoding="utf-8"?>
<i18n>
<Main_Script>
<Globals>
<Good_Morning>
<en-GB>Good Morning</en-GB>
<fr-FR>Bonjour</fr-FR>
</Good_Morning>
<What_Is_Your_Name>
<en-GB>What is your name?</en-GB>
<fr-FR>Quel est votre nom?</fr-FR>
</What_Is_Your_Name>
</Globals>
<!-- <some comment to translators> -->
<#1#_Is_My_Name>
<en-GB>{1} is my name.</en-GB>
<fr-FR>Je m'appelle {1}.</fr-FR>
</#1#_Is_My_Name>
</Main_Script>
<Include_myIncludedFile>
<Dialogs>
<Dialog_Title>
<en-GB>Dialog title</en-GB>
<fr-FR>Titre de la fenêtre</fr-FR>
</Dialog_Title>
</Dialogs>
<Menu>
<Close_all_files>
<en-GB>Close all files.</en-GB>
<fr-FR>Fermer tous les fichiers.</fr-FR>
</Close_all_files>
</Menu>
</Include_myIncludedFile>
</i18n>
or if we keep a symmetry list between xml's tags and the string passed to i18n it could even be simplier:
' Symmetry list
' syntax : [tag] [i18n submitted string]
' * tag could be zero padded to keep alignment
'
1 "Good Morning"
2 "What is your name?"
3 "{1} is my name."
4 "Dialog title"
5 "Close all files."
HTML Code:
<?xml version="1.0" encoding="utf-8"?>
<i18n>
<Main_Script>
<Globals>
<1>
<en-GB>Good Morning</en-GB>
<fr-FR>Bonjour</fr-FR>
</1>
<2>
<en-GB>What is your name?</en-GB>
<fr-FR>Quel est votre nom?</fr-FR>
</2>
</Globals>
<!-- <some comment to translators> -->
<3>
<en-GB>{1} is my name.</en-GB>
<fr-FR>Je m'appelle {1}.</fr-FR>
</3>
</Main_Script>
<Include_myIncludedFile>
<Dialogs>
<4>
<en-GB>Dialog title</en-GB>
<fr-FR>Titre de la fenêtre</fr-FR>
</4>
</Dialogs>
<Menu>
<5>
<en-GB>Close all files.</en-GB>
<fr-FR>Fermer tous les fichiers.</fr-FR>
</5>
</Menu>
</Include_myIncludedFile>
</i18n>
XML files attached : v3.zip
memo:the built xml can be written to be human readable and contain script-unused informations.
Bookmarks