Open cloudjanak opened 10 years ago
It detects the current language automatically, using the current Locale, like every iOS app does automatically (even when you don't use OHAutoNIBi18n; that's the way iOS localization system works), as suggested by Apple's Coding Guidelines.
In fact, OHAutoNIBi18n
does exactly the same as if you called NSLocalizedString
manually on all your strings (well on the ones intended for UI). Except that it does this automatically, avoiding the need to have an IBOutlet on every single UI element just to call NSLocalizableString
on it. But otherwise it has the exact same behavior has normal iOS localization when you do it manually, using the NSLocalizedString
macro (or using Xcode's Base Localization). It let iOS detect the user language and choose the correct Localizable.strings
file to pick localizations from according to,the user's current locale.
We could imagine to add the feature of forcing the locale to a custom one instead of being the user's locale (even if it's not recommended in iOS guidelines and for a good UX), but this is not a feature anyone has requested so far. If you feel like implementing it, don't hesitate to submit a Pull Request.
See also #4
In this file from where it will detect tha language settings..?? can we give our own language in this file ..? mean force to use this specific translation..