• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSNumberFormatterSpellOutStyle and localization
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSNumberFormatterSpellOutStyle and localization


  • Subject: Re: NSNumberFormatterSpellOutStyle and localization
  • From: Ricky Sharp <email@hidden>
  • Date: Sat, 30 Jun 2007 07:54:09 -0500


On Jun 30, 2007, at 7:19 AM, Keith Blount wrote:

// Spelled out (lowercase)
numberFormatter = [[NSNumberFormatter alloc] init];
[numberFormatter
setFormatterBehavior:NSNumberFormatterBehavior10_4];
[numberFormatter
setNumberStyle:NSNumberFormatterSpellOutStyle];
autoNumber = 1;
[returnStr replaceCharactersInRange:range
withString:[[numberFormatter
stringFromNumber:[NSNumber
numberWithInt:autoNumber++]] lowercaseString]];

I had assumed that the formatter would automatically
localize the spelling of the numbers to the system's
default language, but some non-English users are
telling me that they are still getting "one, two,
three" etc when they should be getting "ein, zwei" or
"un, deux" etc.

So, does anybody out there know how to localize
NSNumberFormatterSpellOutStyle?

[numberFormatter setLocale:[NSLocale currentLocale]];

___________________________________________________________
Ricky A. Sharp         mailto:email@hidden
Instant Interactive(tm)   http://www.instantinteractive.com

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >NSNumberFormatterSpellOutStyle and localization (From: Keith Blount <email@hidden>)

  • Prev by Date: NSNumberFormatterSpellOutStyle and localization
  • Next by Date: Re: Hide NSMenuItem
  • Previous by thread: NSNumberFormatterSpellOutStyle and localization
  • Next by thread: Re: [SOLVED] bindings with two interdependent NSPopupButtons
  • Index(es):
    • Date
    • Thread