• 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: NSPopUpButton setPreferredEdge
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSPopUpButton setPreferredEdge


  • Subject: Re: NSPopUpButton setPreferredEdge
  • From: Francisco Tolmasky <email@hidden>
  • Date: Sun, 29 Jun 2008 23:07:44 -0700

Thanks Peter, that makes sense, although if that is the case they should really just deprecate the method.

Francisco

On Jun 26, 2008, at 7:30 PM, Peter Ammon wrote:


On Jun 26, 2008, at 5:49 PM, Francisco Tolmasky wrote:

I'm attempting to make a pop up button that pops its menu to the left of itself. However, setting setPullsDown:YES and setPreferredEdge:NSMinXEdge does not appear to work. In fact, setPreferredEdge seems to be largely ignored, whether I set it in code or even quickly testing it in IB. Am I forgetting some sort of step?

Hi Francisco,

This isn't supported on OS X. The preferred edge is ignored for menu positioning, because the standard UI is to show the menu below the control.

If you want the menu to pop up somewhere else, you will have to override mouseDown: and pop up the menu manually. However, it's normally best to follow Macintosh conventions and let the frameworks worry about menu positioning.

-Peter


_______________________________________________

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: 
 >NSPopUpButton setPreferredEdge (From: Francisco Tolmasky <email@hidden>)
 >Re: NSPopUpButton setPreferredEdge (From: Peter Ammon <email@hidden>)

  • Prev by Date: Re: CALayer and View Scaling
  • Next by Date: [MEET] CocoaHeads Mac Developer Meetings
  • Previous by thread: Re: NSPopUpButton setPreferredEdge
  • Next by thread: subclassing CAAnimation
  • Index(es):
    • Date
    • Thread