I experimented a bit with this and created a subclass of NSViewController with the corresponding XIB file. I can download this download automatically by placing an instance of the NSViewController object in the main XIB file and using the attribute inspector to set the name "Nib" to the XIB file name of the NSViewController subclass. This XIB file also contains, by default, one view object that you can configure in IB, or set a subclass type of a custom view.
However, it still requires one line of code to add the view controller view to the content view of the main window. (I did this as a delegate)
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification
{
[[self.window contentView] addSubview:myVC.view];
}
, NSViewController , XIB , NSViewController.
XIB XIB. , .