Re: NSDateFormatter
Re: NSDateFormatter
- Subject: Re: NSDateFormatter
- From: Bertrand Landry Hetu <email@hidden>
- Date: Tue, 1 Feb 2005 18:37:37 -0800
I thought of doing that. I was just hoping to get it for free... I must
be getting spoiled by Cocoa :).
Anyway, it confirms the way I should be taking. Thanks.
Bertrand.
On Feb 1, 2005, at 6:35 PM, Kevin Ballard wrote:
Make a subclass of NSDateFormatter and override -stringForObjectValue:
to check the object - if it's today, then return @"Today", otherwise,
return the superclass's implementation.
You might also want to support @"Yesterday" and @"Tomorrow" as well.
On Feb 1, 2005, at 9:16 PM, Bertrand Landry Hetu wrote:
I was wondering if there was a way to use NSDateFormatter to format
an NSDate into a string that would say "Today" if NSDate is today or
the usual string if not (just like Mail & Finder)?
I thought setting allowNaturalLanguage to YES would do it but It
seems like it really means that it supports parsing the user's input.
--
Kevin Ballard
email@hidden
http://www.tildesoft.com
http://kevin.sb.org
_______________________________________________
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