According to the docs*, the underlying NSCell handles the actual
drawing of the control. When controls want to draw themselves, they
send a drawWithFrame:inView: message to their cell.
Try moving your drawing code to a subclass of NSButtonCell** and
replace NSButton and NSButtonCell with your custom subclasses***. That
should work.
On 20 Ιαν 2008, at 12:07 ΜΜ, [nexUmoja] Fabian Jäger wrote:
With Interface Builder 2 it worked without any problems to use a
Custom View and change its class to my NSButton subclass...
I already tried to change the class of an NSButton in Interface
Builder 3 to my subclass, but unfortunately it does not change its
appearance accordingly. It seems not to change the class of the
button :-(
Fabian
Am 20.01.2008 um 10:49 schrieb Nick Toumpelis:
As far as I can tell, CustomView is only suitable for subclasses of
NSView. NSButton is further down the line of inheritance and IB
doesn't work with it like it does normally ...
What about, starting with NSButton and specifying the Class value
as your own subclass?