title: NSTextView: Resign First Responder in storyboard app
body: <p>I have a macOS app using storyboards (OSX 10.12; Xcode 9). The view controller I am interested in is embedded in a SplitViewController which is embedded in a SplitViewController which is the main ViewController's contentViewController, so it's sitting three levels deep.</p>
  
  <p>In this view controller, I have an NSTextField ("title") and an NSTextView ("body"). Whatever I do, the NSTextView is the first responder, and I want my NSTextField to be the first item the user types into.</p>
  
  <p>I have tried using  NSApplication.shared.mainWindow?.makeFirstResponder(title)
  in ViewWillAppear (mainWindow is still nil in ViewDidLoad; thanks, Storyboard) but it has no effect whatsoever: after calling this, body remains the first responder.</p>
  
  <p>Using body.resignFirstResponder() or title.becomeFirstResponder() equally have no effect at all (I know the documentation says "Never invoke this method directly", but it had to be tried); the cursor continues to blink happily inside the text view.</p>
  
  <p>I've managed to create a hack by subclassing NSTextView, initially returning false from 'acceptsFirstResponder' and setting it back to 'true' in the viewDidLoad method of my ViewController, but that's ugly and simply sidesteps the responder chain.</p>
  
  <p>What's the correct way of setting my NSTextField as first responder when the NSTextView just does not want to take the hint? </p>