I want to create a color picker button like Apple does in Pages / Numbers / Keynote :
It has a bezel border like push button, with left part filled by selected color, and right part clickable to show system color picker.
Here are what I tried before:
set
NSButton.wantsLayertotrueand set a background color to layer to show the color. two problems:a. the bezel border is gone
b. I don't know how to add the right part to button
create a new
NSViewand add custom sub views. two problems:a. don't know how to draw bezel border just like push button
b. it's difficult to keep same size with push button
