Question

I have a NSToolbar. One of the default items (created by IB, so you can check it out by just adding an NSToolbar to a XIB) is an a NSToolbar item that opens NSColorPanel when clicked. However, I see no way to get a IBOutlet connecting the NSColorPanel to my code- which I need so I can get the NSColor. Obviously I'm missing something. Anybody know how to wire this up?

Was it helpful?

Solution

I figured it out! Yay me! What you need to do is implement -(void)changeColor: in the First Responder. Inside, just type [sender color] to get the color!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top