Re: Trying to read selection states
Re: Trying to read selection states
- Subject: Re: Trying to read selection states
- From: Esteban Uribe <email@hidden>
- Date: Fri, 3 May 2002 12:07:52 -0700 (PDT)
On Friday, May 03, 2002, at 03:07PM, John Kundert-Gibbs <email@hidden> wrote:
>
Hi, all,
>
>
and sorry for such a newbie question, but the Objective-C documentation
>
in the SDK is not searchable(!)
>
There's a couple of dev tools that let you search through the docs, one of my favorites is Cocoa Browser. It doesnt exactly search them but it does sort them out in a nice way, and its a lot quicker than loading up the docs in a web browser.
>
Hopefully this is just an easy call, like the one above, and returns a 1
>
or 0 for its state.
>
You can set your controller as delegate of both fields and implement any of the following
- textDidBeginEditing:
- textDidChange:
- textDidEndEditing:
in your controller.
I'd go for textDidEndEditing, when that gets called in the delegate of the NSTextField you can find out which text field it was by providing an outlet from the controller to the text fields.
Then when textDidEndEditing gets called you can do your stuff. Asumming an enter key pressed means end editing on your NSTextField (check its info in interface builder), textDidEndEditing will get called at which point you do your conversion.
you'll probably have to tweak this a bit, so that it works when you click on the convert button.
-Esteban
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.