Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

kev786

macrumors newbie
Original poster
Jan 5, 2010
9
0
Hi ,
I want replace draw method for pop up menu in NSPopUpButton, more exactly replace default gray background on different
Which function I need override ?
Thanks
 

kainjow

Moderator emeritus
Jun 15, 2000
7,958
7
You need to subclass NSPopUpButton and NSPopUpButtonCell, which manages the drawing. Look at the three drawing methods used in NSButtonCell for what you need to override (or just the generic NSCell one).

If you're trying to customize the actual menu items that show, there's not a lot you can do other than providing your own view and doing all the drawing yourself.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.