Created
August 27, 2013 18:31
-
-
Save steipete/6357231 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PSPDFSetLocalizationBlock(^NSString *(NSString *stringToLocalize) { | |
// This will look up strings in language/PSPDFKit.strings inside your resource folder. | |
return NSLocalizedStringFromTable(stringToLocalize, @"PSPDFKit", nil); | |
// You can also route translation through your default localization: | |
return NSLocalizedString(stringToLocalize, nil); | |
// Or use a custom variant, for example to test if everything is localized: | |
// Please keep in mind that several strings like "Edit" are provided by the system and automatically translated, provided that you have the correct localization resources set. | |
return [NSString stringWithFormat:@"_____%@_____", stringToLocalize]; | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment