XBMC official translation project for release Frodo is open !

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
alanwww1 Offline
Team-XBMC Member
Posts: 1,299
Joined: Nov 2008
Reputation: 31
Location: Hungary
Post: #31
(2012-06-03 01:43)jmarshall Wrote:  Right - we can't yet replace msgctxt with something useful as we're still using the id's, so this is an interim measure.

Yes, it will only be changeable for regular Gettext calls. But I think using the coinsurance and comment fields we can have what we want.
And those fields are showing up nicely in Transifex as well.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
find quote
takoi Offline
Fan
Posts: 506
Joined: Oct 2009
Reputation: 6
Location: Norway
Post: #32
(2012-06-03 01:05)alanwww1 Wrote:  
(2012-06-03 00:33)jmarshall Wrote:  @takoi: It wouldn't surprise me if it was that high. What would be a huge help is for the contexts to be done for all the strings you found - once the context clearly indicates where it's used, it's both useful to the translator (as you know where to look to see whether things fit etc) and also useful for developers when removing/replacing old strings as they know they are unused now. You can fill in something like "unused" for the ones that aren't done and I'm sure that Jezz_X will be happy to take a hunt through and confirm that they're unused, thus removing them.

Obviously this is a large job, but if everyone pitches in and just does a few each (just let us know which block you're doing), it won't take long before the whole lot are done.

I am planning to write a parser utility to extract at least the occurence of the string calls. The tricky thing is that we have several ways of passing the string id to the localization function. Sometimes it comes from a direct parameter, but sometimes it comes from an xml file or from other indirect calls.
So whenever I have time for it, I'll try do it.
This is a perfect example of why string keys are so important.

If everything is moved to strings (wrapped with direct calls) you have essentially moved from maintaining a .pot file to generating. Like gettext does. The unused string problem is solved. The extract occurrences problem is solved.

Maybe a temporary solution (before the id to string move is done) could be a simple file storing all the id to string mappings. Then, the English .po template is generated by extracting the IDs from source code and looking up the string in that file (since you're planing to write that parser tool anyway)?
find quote
takoi Offline
Fan
Posts: 506
Joined: Oct 2009
Reputation: 6
Location: Norway
Post: #33
So I made a quick script doing a plain text search with these assumptions (tell me if this isn't correct):
- searching only in xbmc and addons subfolder
- searching only h, cpp and xml files

..which found a whopping 448 unused strings. And this is an absolute minimum as there's probably a lot of false positives because it's just a simple substring search.
(This post was last modified: 2012-06-04 16:10 by takoi.)
find quote
alanwww1 Offline
Team-XBMC Member
Posts: 1,299
Joined: Nov 2008
Reputation: 31
Location: Hungary
Post: #34
(2012-06-04 16:09)takoi Wrote:  So I made a quick script doing a plain text search with these assumptions (tell me if this isn't correct):
- searching only in xbmc and addons subfolder
- searching only h, cpp and xml files

..which found a whopping 448 unused strings. And this is an absolute minimum as there's probably a lot of false positives because it's just a simple substring search.

Thanks for the search.
The only thing which needs filtering from the unused strings AFAIK is the weather tokens which are not directly used. The IDs are from Weather.cpp

Code:
#define LOCALIZED_TOKEN_FIRSTID    370
#define LOCALIZED_TOKEN_LASTID     395
#define LOCALIZED_TOKEN_FIRSTID2  1396
#define LOCALIZED_TOKEN_LASTID2   1450
#define LOCALIZED_TOKEN_FIRSTID3    11
#define LOCALIZED_TOKEN_LASTID3     17
#define LOCALIZED_TOKEN_FIRSTID4    71
#define LOCALIZED_TOKEN_LASTID4     89

I am not sure, but also it is possible I think, that third party addons and/or skins are using some strings in the core file which are not in use by xbmc core itself. I need a team member who is better aware of addons to confirm or deny this.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
(This post was last modified: 2012-06-04 17:28 by alanwww1.)
find quote
blittan Offline
Team-XBMC Handyman
Posts: 1,714
Joined: Jun 2004
Reputation: 11
Location: Sweden
Post: #35
the plan for a few years ago was to add regularly used add-on strings to core translation in an effort to ease the burden on the translators. there might still be a few one used there.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
If you don't have the time to read them, please don't take the time to post in this forum!
For troubleshooting and bug reporting please make sure you read this first.
find quote
alanwww1 Offline
Team-XBMC Member
Posts: 1,299
Joined: Nov 2008
Reputation: 31
Location: Hungary
Post: #36
(2012-06-04 19:40)blittan Wrote:  the plan for a few years ago was to add regularly used add-on strings to core translation in an effort to ease the burden on the translators. there might still be a few one used there.

As we have the translation memory working now, I think it is not so a big issue. So if possible, would be good to make a big clean up :-)

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
find quote
takoi Offline
Fan
Posts: 506
Joined: Oct 2009
Reputation: 6
Location: Norway
Post: #37
Ultimately it's a good thing because addons shouldn't be using strings that cant be changed by translations anyway. It creates more problems than it solves.
find quote
ntadej Offline
Member
Posts: 84
Joined: Nov 2011
Reputation: 6
Location: Slovenia
Post: #38
There are problems with touched skin translation (at least for Slovenian translation). All special letters (like č, š, ž) are replaced wih ?. I think this are strings that have already been translated before the import. Could you please look into it.
find quote
alanwww1 Offline
Team-XBMC Member
Posts: 1,299
Joined: Nov 2008
Reputation: 31
Location: Hungary
Post: #39
(2012-06-06 18:52)ntadej Wrote:  There are problems with touched skin translation (at least for Slovenian translation). All special letters (like č, š, ž) are replaced wih ?. I think this are strings that have already been translated before the import. Could you please look into it.

Unfortunatelly it was originally broken in the xml file:

https://github.com/xbmc/skin.touched/blo...trings.xml

Could you please correct it on transifex ?

Thanks

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
(This post was last modified: 2012-06-06 22:45 by alanwww1.)
find quote
ntadej Offline
Member
Posts: 84
Joined: Nov 2011
Reputation: 6
Location: Slovenia
Post: #40
No problem, just wanted to point it out, if there are other problems present.
find quote
Post Reply