• 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: Overriding NSMenuItem's drawing
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Overriding NSMenuItem's drawing


  • Subject: Re: Overriding NSMenuItem's drawing
  • From: Peter Ammon <email@hidden>
  • Date: Wed, 17 Feb 2010 15:33:19 -0800

On Feb 17, 2010, at 8:30 AM, Tom Davie wrote:

> I need an NSMenuItem that rather than drawing an NSImage in it's cell draws
> *part* of an NSImage, is it possible to override NSMenuItem's drawing in any
> way to achieve this?  I don't see the relevant methods.

Can't you just make a different NSImage containing part of the original?  If you are worried about performance, you can make a custom NSImageRep that references the original image.

_______________________________________________

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: 
 >Overriding NSMenuItem's drawing (From: Tom Davie <email@hidden>)

  • Prev by Date: Re: “EXC_BAD_ACCESS” on Custom TableView with custom NSCell when clicking.
  • Next by Date: Re: Debugging "NSManagedObject with ID has been invalidated"
  • Previous by thread: Re: Overriding NSMenuItem's drawing
  • Next by thread: Debugging "NSManagedObject with ID has been invalidated"
  • Index(es):
    • Date
    • Thread