[iOS] NSUserDefaults best practices

2011-02-05 Thread Philip Vallone
Hi, After some reading I understand that when creating a Settings Bundle for by iOS app, that I need to explicitly set the defaults. I was wondering if anyone had a preference for where you are setting the defaults. For example in the App Delegate. I decided to use a singleton to set my

RE: NSBitmapImageRep with floating point values

2011-02-05 Thread Paul Morel
Hi, thank you very much for the idea! I'll try that! Paul Date: Fri, 4 Feb 2011 21:07:10 -0800 Subject: Re: NSBitmapImageRep with floating point values From: kenfe...@gmail.com To: david.dun...@apple.com CC: elbomber...@hotmail.com; cocoa-dev@lists.apple.com On Thu, Feb 3, 2011 at 2:37 PM,

Re: Identify key colour in video/photo

2011-02-05 Thread douglas welton
Is this what you're looking for... http://developer.apple.com/library/mac/#samplecode/CIChromaKeyFilter/Introduction/Intro.html On Feb 4, 2011, at 9:17 PM, Michael Hanna wrote: A few years back there was a sample code app that would use a key colour(like bright pink) found in a movie frame

Re: [iOS] NSUserDefaults best practices

2011-02-05 Thread Fritz Anderson
On 5 Feb 2011, at 6:33 AM, Philip Vallone wrote: After some reading I understand that when creating a Settings Bundle for by iOS app, that I need to explicitly set the defaults. I was wondering if anyone had a preference for where you are setting the defaults. For example in the App

Re: [iOS] NSUserDefaults best practices

2011-02-05 Thread Chris Parker
On 5 Feb 2011, at 4:33 AM, Philip Vallone wrote: After some reading I understand that when creating a Settings Bundle for by iOS app, that I need to explicitly set the defaults. I was wondering if anyone had a preference for where you are setting the defaults. For example in the App

Re: [iOS] NSUserDefaults best practices

2011-02-05 Thread Jerry Krinock
On 2011 Feb 05, at 12:24, Chris Parker wrote: Usually, you construct a dictionary plist in your application bundle which contains the key/value pairs you wish to use as your backstop defaults. I call them default defaults. Then, you can read that dictionary from the plist in the bundle on

Re: [iOS] NSUserDefaults best practices

2011-02-05 Thread Matt Neuburg
On Sat, 05 Feb 2011 07:33:08 -0500, Philip Vallone philip.vall...@verizon.net said: Hi, After some reading I understand that when creating a Settings Bundle for by iOS app, that I need to explicitly set the defaults. You don't *have* to; the settings bundle itself specifies your default

Re: Common Font Style Names

2011-02-05 Thread Matt Neuburg
On Fri, 04 Feb 2011 13:00:56 -0600, Gordon Apple g...@ed4u.com said: This used to work, but not under iOS 4. - (NSString*)styleNameForIndex:(NSUInteger)index inFontFamily:(NSString*)famName { NSString* fontName = [[UIFont fontNamesForFamilyName:famName] objectAtIndex:index]; CTFontRef

Re: [iOS] NSUserDefaults best practices

2011-02-05 Thread Philip Vallone
Thanks Matt and thanks to all the others that replied. Regards, Phil On Feb 5, 2011, at 5:46 PM, Matt Neuburg wrote: On Sat, 05 Feb 2011 07:33:08 -0500, Philip Vallone philip.vall...@verizon.net said: Hi, After some reading I understand that when creating a Settings Bundle for by iOS

Understanding CoreData

2011-02-05 Thread Jean Cencig
Hi, New to Cocoa, I have a simple CoreData document based test project with: - a subclass of the NSArrayController, - an entity with one string attribute and the corresponding subclass of NSManagedObject, - a window with Add and Remove buttons and the TableView. It fully works, I try to

Re: Understanding Cocoa (Was: Understanding CoreData)

2011-02-05 Thread Jerry Krinock
On 2011 Feb 05, at 15:45, Jean Cencig wrote: How can [my subclasses of NSManagedObject and NSArrayController] work without being inited? Well, they cannot. Possibly they are being instantiated as base class, i.e. NSManagedObject and NSArrayController, objects, and that this behavior is

Re: NSUndoManager retain/release of arguments - ad infinitum

2011-02-05 Thread John Bartleson
Sorry, I was busy and couldn't reply. Now it's time to finish this thread. Graham Cox said: In the middle step, why should YOU worry about whether the undo manager has retained 'descriptorsCopy'? It's not your responsibility how that object works. It might have retained the object,

Re: NSUndoManager retain/release of arguments - ad infinitum

2011-02-05 Thread Graham Cox
On 06/02/2011, at 11:37 AM, John Bartleson wrote: A lot of the confusion comes about because of poor documentation. Apple's Introduction to Undo Architecture doesn't clearly explain that the sequence beginning with prepareWithInvocationTarget: results in NSUndoManager effectively taking

Triggering a Core Data Store action ...

2011-02-05 Thread thx316
Hello. How do I trigger a Core Data Store action when importing the contents of a standard .txt file into an NSTextView via NSOpenPanel? This is how I write the contents of a file to the textView. The text does not remain associated with the sourceView entry, and I cannot save this contents

Re: NSUndoManager retain/release of arguments - ad infinitum

2011-02-05 Thread Jerry Krinock
On 2011 Feb 05, at 16:37, John Bartleson wrote: A lot of the confusion comes about because of poor documentation. That's one of the main reasons for using Graham's open-source GCUndoManager. whatever, could issue a command like Track someObjectName. During execution, I'd see the following:

Re: NSUndoManager retain/release of arguments - ad infinitum

2011-02-05 Thread Charles Srstka
On Feb 5, 2011, at 6:37 PM, John Bartleson wrote: Let me make one final point: this topic would have never come up if I had had a tool that would let me track the lifetime of an object. Very hypothetically, suppose I could write my code, execute it, and then, in the debugger or whatever,