Skip navigation.
 
mlRe: Internationalization: How to bring the locale in line with the language?
FROM : Jonathon Mah
DATE : Wed Nov 03 20:52:53 2004

On 4 Nov 2004, at 02:15, Uli Zappe wrote:

>>> So is there no way to bring the locale in line with the language in
>>> time?

>>
>> Did you try changing the default before NSApplicationMain() was
>> called?

>
> No, but there I would have a hard time finding out what the used
> language will be. I don't want to hardcode the locale (then I could
> obviously simply not use localized methods in my app), but bring it in
> line with the language the app actually uses depending on the user's
> preferences and the available localized NIB files.


You could put each locale in the localized .strings file, and then set
the setting to whatever NSLocalizedString() returns. That way, it'd be
in English if it were using English strings, etc.

(I'm assuming that the application is set-up enough to use
NSLocalizedString() before NSApplicationMain() is called — I haven't
tried that yet.)


Jonathon Mah
<email_removed>

Related mailsAuthorDate
mlInternationalization: How to bring the locale in line with the language? Uli Zappe Nov 3, 10:44
mlRe: Internationalization: How to bring the locale in line with the language? Uli Zappe Nov 3, 16:45
mlRe: Internationalization: How to bring the locale in line with the language? Jonathon Mah Nov 3, 20:52
mlRe: Internationalization: How to bring the locale in line with the language? Uli Zappe Nov 4, 02:59
mlRe: Internationalization: How to bring the locale in line with the language? M. Uli Kusterer Nov 5, 00:58
mlRe: Internationalization: How to bring the locale in line with the language? Uli Zappe Nov 5, 03:01