Re: Gap above NSMenuItem custom view

2010-12-27 Thread Joshua Garnham
kyle.slu...@gmail.com To: Joshua Garnham joshua.garn...@yahoo.co.uk Cc: cocoa-dev@lists.apple.com Sent: Sun, 26 December, 2010 22:04:22 Subject: Re: Gap above NSMenuItem custom view On Sun, Dec 26, 2010 at 4:16 PM, Joshua Garnham joshua.garn...@yahoo.co.uk wrote: I see your point but I just found

Gap above NSMenuItem custom view

2010-12-26 Thread Joshua Garnham
I am using the setView: method on an NSMenuItem to set a custom view. In this custom view there is an image which takes the whole of the view. The NSMenuItem with this custom view is the first in the menu but the problem is it doesn't sit flush with the top of the menu, there is a big gap as

Re: Gap above NSMenuItem custom view

2010-12-26 Thread Kyle Sluder
On Dec 26, 2010, at 11:07 AM, Joshua Garnham joshua.garn...@yahoo.co.uk wrote: Why is this happening and how can I stop it? You can't. Search the archives and you'll see other people have had this same problem. There needs to be a bot that autoreplies to NSView-in-NSMenu questions: If you're

Re: Gap above NSMenuItem custom view

2010-12-26 Thread Kyle Sluder
On Dec 26, 2010, at 12:19 PM, Josh joshua.garn...@yahoo.co.uk wrote: I am sure there is a way, I have been looking in the archives and found mention of changing the metrics for the top of the menu with Carbon. How would they of done this? You have no access to the Menu Manager on the modern

Re: Gap above NSMenuItem custom view

2010-12-26 Thread Joshua Garnham
I see your point but I just found this post on Stack Overflow detailing how someone else has done it. http://stackoverflow.com/questions/4064386/reverse-engineering-an-nsmenu-for-a-status-bar-item However I am having dificulty compiling the code as I get EXC_BAD_ACCESS on the line where the

Re: Gap above NSMenuItem custom view

2010-12-26 Thread Kyle Sluder
On Sun, Dec 26, 2010 at 4:16 PM, Joshua Garnham joshua.garn...@yahoo.co.uk wrote: I see your point but I just found this post on Stack Overflow detailing how someone else has done it. http://stackoverflow.com/questions/4064386/reverse-engineering-an-nsmenu-for-a-status-bar-item However I