• 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: NSButtonCell Ignores Button Type -- A Discovery and Annoyance
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSButtonCell Ignores Button Type -- A Discovery and Annoyance


  • Subject: Re: NSButtonCell Ignores Button Type -- A Discovery and Annoyance
  • From: Ricky Sharp <email@hidden>
  • Date: Tue, 29 Mar 2005 20:53:13 -0600


On Mar 29, 2005, at 6:40 PM, Seth Willits wrote:

When I use my custom cell, I get the toggling behavior like I said above. However if I use a normal NSButtonCell (no custom drawing), it draws and behaves as a normal push button. I add on with a category to NSButtonCell and put a break point in the setState method, and have found out that the NSButtonCell code simply ignores what the state is when drawing, and only uses [self isHighlighted]. Now, I would do this if I could, except that I elsewhere, I *do* want my cells to use a toggling behavior. I *thought* NSMatrix took care of this with the different matrix modes, but it's obvious now that it does not.

One thing you may want to try is not subclassing NSButtonCell, but NSActionCell instead. I swear there's many things under the hood going on when an NSMatrix holds NSButtonCell cells.


___________________________________________________________
Ricky A. Sharp         mailto:email@hidden
Instant Interactive(tm)   http://www.instantinteractive.com

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >NSButtonCell Ignores Button Type (From: Seth Willits <email@hidden>)
 >Re: NSButtonCell Ignores Button Type (From: Stephane Sudre <email@hidden>)
 >Re: NSButtonCell Ignores Button Type (From: Seth Willits <email@hidden>)
 >Re: NSButtonCell Ignores Button Type (From: Seth Willits <email@hidden>)
 >Re: NSButtonCell Ignores Button Type (From: Ricky Sharp <email@hidden>)
 >Re: NSButtonCell Ignores Button Type (From: Ricky Sharp <email@hidden>)
 >Re: NSButtonCell Ignores Button Type (From: Seth Willits <email@hidden>)
 >Re: NSButtonCell Ignores Button Type -- A Discovery and Annoyance (From: Seth Willits <email@hidden>)

  • Prev by Date: Re: Creating a "tool" in objective-C
  • Next by Date: How to code a NSString literal with UTF8?
  • Previous by thread: Re: NSButtonCell Ignores Button Type -- Hacked Solution
  • Next by thread: NSOpenGLView and CustomViews problems
  • Index(es):
    • Date
    • Thread