I set the Core Animation Layer
of NSButton
in the xib file, like below:
I'd like to know how to set it in the code.
Thanks!
Take a looks at the description of setWantsLayer. It explains what to do.
You either want to call setWantsLayer:TRUE, or first call setLayer, then setWantsLayer:TRUE, depending on what you want to do with layers.