• 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: Sorting Attributed Strings w/Bindings
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Sorting Attributed Strings w/Bindings


  • Subject: Re: Sorting Attributed Strings w/Bindings
  • From: "Ian G. Gillespie" <email@hidden>
  • Date: Sat, 20 Nov 2004 23:20:51 -0500


I tried adding a compare: category to NSAttributedString, but then I
got this error:
-[NSConcreteAttributedString _fastCharacterContents]: selector not
recognized

How did you implement 'compare'?

Thanks for replying. I added this a method like this as a category to NSAttributedString. It gets called when I click the table column.

-(NSComparisonResult)compare:(NSAttributedString *)str  {
	NSString *us = [self string];
	NSString *other = [str string];
	return [us caseInsensitiveCompare:str];
}

thx,
Ian

_______________________________________________
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: Sorting Attributed Strings w/Bindings
      • From: Marcel Weiher <email@hidden>
  • Prev by Date: Problems with mouse events
  • Next by Date: Keyed archiver
  • Previous by thread: Re: Sorting Attributed Strings w/Bindings
  • Next by thread: Re: Sorting Attributed Strings w/Bindings
  • Index(es):
    • Date
    • Thread