This is a stupidly large commit. I’m so sorry.

It introduces two new helpers and rejiggers the project to be based around NSWindowControllers.
Merge remote-tracking branch 'github/master'