You have to redraw the entire thing. There is no property, to specifically change the background-color of the NSSearchField. Check out this example:
Edit:
Also what's worth to point out. You should never override the controls drawRect method. You should rather make a subclass of NSSearchFieldCell.