Newbie document based application and menus question
Newbie document based application and menus question
- Subject: Newbie document based application and menus question
- From: Sarven Sabunciyan <email@hidden>
- Date: Mon, 10 Mar 2003 01:31:03 -0500
This is a rather simple design question which I haven't been able to
find the answer to. I am writing an application that has an
NSTextView. I want to modify the text in the NSTextView in several
ways and update my menus accordingly (i.e. if all the digits and
white space have been removed from the text, I want the menu item
responsible for this command to be disabled). I've created a
document based applications and have created a NSDocument subclass.
I have written another class (of type NSObject) which handles the
text modification commands. I instantiated this class in the
MyDocument nib file and made an outlet to the NSTextView so that I
can get the string in the view. The problem is since the text
modification class is in the MyDocument nib file I haven't can't
connect to the menus in the mainmenu nib. If I place the text
modification class in the Main Menu Nib then how would I get access
to the string from NSTextview? What is the expected way of doing
this?
Thanks in advance
Sarven
_______________________________________________
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.