Re: determine which NSTextView is sending to delegate?
Re: determine which NSTextView is sending to delegate?
- Subject: Re: determine which NSTextView is sending to delegate?
- From: John James <email@hidden>
- Date: Sat, 6 Nov 2004 09:30:04 -0500
This is what I was looking for. But -setTag does not seem to be
available on a NSTextView or rather NSView. According to the
documentation you must subclass to set the tag.
NSView: tag
- (int)tag
Returns the receiver’s tag, an integer that you can use to identify
view objects in your application. NSView’s implementation returns –1.
Subclasses can override this method to provide individual tags,
possibly adding storage and a setTag: method (which NSView doesn’t
define).
I see no mention of tag in NSTextView.
Maybe there is something I missed?
Now I have switched to a set of NSTableView's which allows setting the
tag value in IB allowing me to use the switch as you suggested. (My
app could really use the table instead of requiring me to parse the
text to get the values I want.)
So all is well.
Thanks
On Nov 5, 2004, at 9:46 AM, Rainer Brockerhoff wrote:
I find that setting each view to a different tag value is easier, and
you can check them in a switch statement instead of a long list of
if/then/else lines...
--
_______________________________________________
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