Re: Localizable.strings in frameworks?
Re: Localizable.strings in frameworks?
- Subject: Re: Localizable.strings in frameworks?
- From: Chris Suter <email@hidden>
- Date: Tue, 26 Sep 2006 14:58:12 +1000
The problem is that NSLocalizedString uses [NSBundle mainBundle]
which will give you the wrong bundle.
What you have to do is use
NSLocalizedStringFromTableInBundle
and pass in the framework bundle.
We solved it by redefining NSLocalizedString within our private
frameworks. We did think about making a new macro but then you have
to pass different arguments to genstrings (which isn't a major issue
admittedly). A bit of a hack, but it works well enough.
- Chris
On 26/09/2006, at 2:47 PM, email@hidden wrote:
I have an app that I am localizing. This app contains a private
framework. In the framework is a .nib file, localized for German
and English. So far so good! But what about the frameworks
localized.string file? Do I put the framework text to be localized
in the app's localized.strings file, or does the framework contain
the localized.strings file? I tried using a localized.strings file
in the frameworks, but it did not work as expected.
Any help would be appreciated!
-Bill
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
systems.com
This email sent to email@hidden
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden