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: Vince DeMarco <email@hidden>
- Date: Fri, 21 Feb 2003 10:12:06 -0800
On Friday, February 21, 2003, at 9:18 AM, 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;
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.
The API in NSView is non functional
viewWithTag: works
but tag always returns -1;
Which is why IB always disables, the field. if you want this feature
please file a bug. Enabling the text field in IB is easy, but the
Appkit has to allow setting a tag on an arbitrary view. IE they also
need to add a setTag: method to NSView.
vince
_______________________________________________
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.