• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: [Leopard] Spotlight/Help-like menu item
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Leopard] Spotlight/Help-like menu item


  • Subject: Re: [Leopard] Spotlight/Help-like menu item
  • From: Eric Schlegel <email@hidden>
  • Date: Sat, 26 Jan 2008 21:59:46 -0800


On Jan 26, 2008, at 8:45 PM, Pierre Bernard wrote:

Trouble starts when I want my view to draw a background (like the blue background used by Spotlight), I find that there remains a white area above and below my view which is drawn by the menu itself. What I am after is a way to get rid of that border.

The Help menu removes that white border by installing a Carbon event handler for kEventControlGetFrameMetrics on the menu content view (HIMenuGetContentView) and returning a top metric of zero pixels. Unfortunately there's no public way to get the MenuRef from an NSMenu, so I'm not sure this approach is viable if you only want to use public API.


-eric

_______________________________________________

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


References: 
 >[Leopard] Spotlight/Help-like menu item (From: Pierre Bernard <email@hidden>)
 >Re: [Leopard] Spotlight/Help-like menu item (From: Ron Fleckner <email@hidden>)
 >Re: [Leopard] Spotlight/Help-like menu item (From: Pierre Bernard <email@hidden>)

  • Prev by Date: Re: [Leopard] Spotlight/Help-like menu item
  • Next by Date: Re: Getting the content-type in a HTTP response
  • Previous by thread: Re: [Leopard] Spotlight/Help-like menu item
  • Next by thread: NSNumberFormatter 10.0+ vs. 10.4+
  • Index(es):
    • Date
    • Thread