On 07/04/14 17:48, Martijn Kaijser wrote:

That makes no difference at all as this will not work for the Settings.xml so you will still need to use the strings.po for starters.

Ah OK I didn't realise you wanted xml strings translated too. But it makes sense.

Also I see no advantages using the Python tools with taking into account you still need to get the set xbmc gui language which the build in method auto handles.


I can pull the language out with xbmc.getLanguage(), so I don't think that's an issue.

The advantage is that you have code that looks like this:

    Dialog.ok(_('Press OK to format your hard drive'))

and not this:

    Dialog.ok(xbmc.getLocalizedString(54353))

I know which I prefer.

In the second case, anyone reading over the code will have no idea what the user is agreeing to. To find out they have to either a) rummage through .po files. b) run the code to find out. Putting a comment above the line itself is a mediocre solution, the code should be self-explanatory.


Paul

On 7 Apr 2014 18:41, "Paul Backhouse" <[email protected] <mailto:[email protected]>> wrote:

    On 07/04/14 13:45, Martijn Kaijser wrote:
    > >which tools?

    https://docs.python.org/2/library/gettext.html



    
------------------------------------------------------------------------------
    Put Bad Developers to Shame
    Dominate Development with Jenkins Continuous Integration
    Continuously Automate Build, Test & Deployment
    Start a new project now. Try Jenkins in the cloud.
    http://p.sf.net/sfu/13600_Cloudbees_APR
    _______________________________________________
    Xbmc-addons mailing list
    [email protected]
    <mailto:[email protected]>
    https://lists.sourceforge.net/lists/listinfo/xbmc-addons


------------------------------------------------------------------------------
Put Bad Developers to Shame
Dominate Development with Jenkins Continuous Integration
Continuously Automate Build, Test & Deployment 
Start a new project now. Try Jenkins in the cloud.
http://p.sf.net/sfu/13600_Cloudbees
_______________________________________________
Xbmc-addons mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xbmc-addons

Reply via email to