Search code examples
objective-cmacoscocoapyobjcobjective-c-runtime

PyObjC: how to create a simple dummy app without nib-file


For various reasons, I cannot/want not use a NIB-file (or any other external resources).

How can I create a simple dummy app (e.g. some simple menu, some empty window) with PyObjC, i.e. with pure Python code?


Solution

  • One very helpful introduction with sample code was the Introduction to PyObjC and Cocoa on lethain.com with some sample code here (and related files).

    I also have an own project now (a music player) where I construct the whole Cocoa GUI dynamically. The main code of that part is here.