Re: Trouble with NSSegmentedControl
Re: Trouble with NSSegmentedControl
- Subject: Re: Trouble with NSSegmentedControl
- From: Seth Willits <email@hidden>
- Date: Mon, 16 Nov 2009 18:44:17 -0800
On Nov 16, 2009, at 2:09 PM, Dave DeLong wrote:
How can I achieve the behavior that I'm looking for (and that is
implied in the documentation)?
NSSegmentedControl, like NSSplitView, leaves *much* to be desired.
Over time, my solution has evolved into an NSSegmentedControl subclass
with a few tweaks (like per-cell actions, and fixing of "selected
cell" value funkiness), and a full custom control with different
styles and behavior.
As for the action firing before the menu is shown, it doesn't look
like my tweaked subclass does what you need it to. I'm sure my
entirely-custom control does, though it's not really in a shareable
state. I think there are little bugs and oddities, and lack of a
standard appearance that would probably make you not want use it.
But....
Is there a way to set a different target and action for each segment?
Yes. This I can help you with. I'll send you the code off-list.
--
Seth Willits
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden