[Pythonmac-SIG] pyobjc / cocoa

Seth Delackner seth@jtan.com
Wed, 16 Oct 2002 00:13:21 -0700


I was actually more concerned by the syntactic problems with the pyobjc 
system:
Objective-C:						pyobjc:
[ obj method ]						obj.method()
[ obj method: arg ]					obj.method_(arg)
[ obj method: arg1 withOtherArgs: arg2 ]	obj.method_withOtherArgs_
( arg1, arg2 )

I would tend to prefer that the python version be:

def method(arg=0, withOtherArgs=0):

Which makes use of default arguments and labels.  Since Objective-C 
doesn't even HAVE optional arguments, this would work just fine.  
Although I suppose I should just be quiet to avoid a pointless language 
argument.

On Tuesday, October 15, 2002, at 05:32 , Bob Ippolito wrote:

> Well more often than not, view/controller code is generally pretty 
> nasty regardless of API and language anyways.  It is the only way I've 
> seen so far that can harness the power of Interface Builder with 
> Python, and one of the few ways that'll get you a working GUI in OS X 
> sans X11 at all.