Internationalization and localization tools


Locale-Sensitive Objective-C Method

Foundation NSScanner

NSScanner scannerWithString

Internationalization (I18n) Method Overview

Click here for additional Apple Developer Documentation details.

I18n Issues

Word, line, and sentence breaks should not be implemented in an anglo-centric way using naive tokenization found in NSString/PKTokenizer/NSScanner. Also, decimal and grouping-list-space separators need to be localized.

Resolution: use something more language specific like NSLinguisticTagger or CFStringTokenizer, especially if it needs to work for Chinese, Japanese, or Thai. And NSScanner should always use localizedScannerWithString to allow locale reactivity for decimal values.

Generally one needs to pass in locale, encoding or language to ensure that any culture-dependent conversion is done properly. If you determine that the call is i18n-safe, you can use Globalyzer's Ignore Comment functionality to ensure that it isn't picked up in a subsequent scan.

For information about Objective-C Internationalization, click here.

 

Lingoport internationalization and localization services and software