Re: buttonType in NSButton
Re: buttonType in NSButton
- Subject: Re: buttonType in NSButton
- From: "Adam Lindsay" <email@hidden>
- Date: Wed, 11 Dec 2002 20:33:53 +0000
I believe matt neuburg said this around Wed, 11 Dec 2002:
>
>These different varieties of button are enumerated by NSButtonType within
>
>AppKit/NSButtonCell.h. There is a method to *set* the buttonType, but
>
>there is no supported method to inspect the buttonType. I want to inspect
>
>it, and that's where I'm stumped.
>
>
I think the reason is that a button type is merely a concatention of
>
other features. In other words, you can set a button type because Cocoa
>
then responds by setting the other multiple features that correspond to
>
the HIG standard for that type. But nothing stops you from setting those
>
features yourself in a way that corresponds to no standard type, so it
>
would be meaningless to speak of a "type" in that case. To learn how the
>
button looks and behaves, ask about those other features. m.
Thanks, Matt.
That's pretty much what occurred to me after I worked it out, and is what
I meant when I tried to say, "Don't check for class or type when it's
behavior you really want to know about." The mapping of type to features
is more a collection out of convenience, and not of any intrinsic type.
The mapping doesn't go the other way.
Problem solved, tested, and it works great. I have the majority of
NSControls transparently reporting their contents over the network
through one method, now. World domination isn't far behind. :)
adam
--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Adam Lindsay +44(0)1524 594 537
email@hidden
http://www.comp.lancs.ac.uk/computing/users/atl/
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
_______________________________________________
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.