• 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: Ignore accents when comparing strings
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Ignore accents when comparing strings


  • Subject: Re: Ignore accents when comparing strings
  • From: Kevin Ballard <email@hidden>
  • Date: Wed, 5 Jan 2005 19:58:50 -0500

gcc works fine with UTF-8, the problem is @"" is only defined for 7-bit ASCII strings. Try

NSString *mot3 = [NSString stringWithUTF8String:"à"];

On Jan 5, 2005, at 7:22 PM, Andrew Farmer wrote:

Here's a real-life example :

NSString *mot1 = @"arc";
NSString *mot2 = @"a";
NSString *mot3 = @"à";

Unless things have changed recently, GCC isn't UTF-8 aware and may be doing strange things to your text. Try reading your strings in from a file or from the UI and try again.

-- Kevin Ballard email@hidden http://www.tildesoft.com http://kevin.sb.org

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

  • Follow-Ups:
    • Re: Ignore accents when comparing strings
      • From: "Simon alias Trax" <email@hidden>
    • Re: Ignore accents when comparing strings
      • From: Brendan Younger <email@hidden>
References: 
 >Ignore accents when comparing strings (From: "Simon alias Trax" <email@hidden>)
 >Re: Ignore accents when comparing strings (From: Andrew Farmer <email@hidden>)

  • Prev by Date: Re: Cocoa Bindings - nondebuggable, non-obvious, procedural ???
  • Next by Date: Re: Cocoa Bindings - nondebuggable, non-obvious, procedural ???
  • Previous by thread: Re: Ignore accents when comparing strings
  • Next by thread: Re: Ignore accents when comparing strings
  • Index(es):
    • Date
    • Thread