-
Notifications
You must be signed in to change notification settings - Fork 291
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added the ability to set a Default Language from the Localization Editor #1290
Conversation
So thanks for this contribution it looks pretty good, couple of comments relating to usability. The default dropdown has no default, as this doesn't currently exist 'none' as the ticked default option would be okay however probably makes more sense for 'English' to be default? Optional |
As I'm sure that "None" doesn't exist as real language, I use this value to detect if the user doesn't want to set a default language OR if he want to remove it. I mean he could choose "Spanish" as default language and after he only wants to remove this default language setting -> he only needs to choose "None" and so no default language will appear into the file Strings.ccbLang. Just for information, if you remove a language, and this language is the default language, so the default language setting will be removed too (so it will display "None"). SO if we want to remove "None" and keep "English" as default value for the "default language" selector... we need to force the user to have the "English" language & translations (he won't be able to remove this language). I prefer to let the user choose his default language in the list of his existing languages & translations. [Optional] -> Currently, all the localised labels (CCLabelTTF, CCLabelBMFont) in the scenes of sprite builder have the check box "Localize" to say it's localised labels. So the textFields (just above the check box "Localize") of these labels will always contain the translation keys (example: intro_mainTitle). So I guess you mean, IN THE PREVIEW AREA of the scene, if the label is localised, it would be great if instead of displaying the translation key it would display the default translation for this key. That's correct ? |
Makes sense that 'None' is the default (and ticked) in dropdown. Issue was visually when you open the Language editor the selection is blank. Yes on second part, for example I added a label HELLO_LABEL, localised it and it defaults to English regardless of settings. So it displays 'Hi', if I add Spanish and then change default language to be Spanish in settings. When I go back to Editor would be nice if that label changes to use the Spanish translation and displays 'Hola' However appreciate the work you have done so far, I can always raise an Issue for the last part as an enhancement. |
…language when opening his project. If the user changed the default language, use the new value to set the editor current language.
Ok. I did the enhancement in my last commit ;) |
Thanks, I'll check it again later. |
…lank if the i18n editor was opened before to open the project.
I identified and fixed: "Issue was visually when you open the Language editor the selection is blank." |
Done :) |
Excellent, works well now. @vlidholt Please can you have a quick look over the UI changes to the Language Editor Window. Thanks |
You can see the thread (on the forum) about this feature here:
http://forum.spritebuilder.com/t/i18n-default-language/2723/4
The other pull request (into cocos2d to use this default language):
cocos2d/cocos2d-objc#1158