Re: 3 IB Qs: actions; view tags; NSWindow setFrame
Re: 3 IB Qs: actions; view tags; NSWindow setFrame
- Subject: Re: 3 IB Qs: actions; view tags; NSWindow setFrame
- From: Stéphane Sudre <email@hidden>
- Date: Fri, 21 Feb 2003 18:54:15 +0100
On Friday, February 21, 2003, at 06:18 PM, David Remahl wrote:
fredagen den 21 februari 2003 kl 18.06 skrev Stiphane Sudre:
2) No tags for custom views?
Interface Builder doesn't allow a "tag" value to be assigned to a
custom view.
The Attributes panel is empty and marked as "Not Applicable". Tags
are part of
NSView so it seems that they *could* be applied. Just an oversight?
Report it as a bug with Apple.
A NSView does not have any tag data just a method which returns -1.
Since you're using the NSView inspector in IB for your custom view,
it's correct that the tag part is disabled.
Then why is it in the header? It doesn't serve backwards compatibility
at all to have these:
- (id)viewWithTag:(int)aTag;
- (int)tag;
Some kind of virtual method, I would say. The same applies to the tag
methods for NSCell (a NSImageCell does not handle tag).
Why isn't this API functional in NSView? It wouldn't take a lot of
effort for apple to provide a default implementation and the only
overhead would be the storage for the tag.
Maybe because using tags for NSView is not a so good idea.
_______________________________________________
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.