Some of that is just getting to know the libraries, of course, and a lack of howtos for the things I'm trying to do.
--Dethe
On 27-Jan-05, at 12:57 PM, Bob Ippolito wrote:
On Jan 27, 2005, at 15:24, Dethe Elza wrote:
FYI, once I updated PyObjC from svn, my example code worked, thanks again Ronald....class NSImage(Category(NSImage)):
def rect(self): return (0,0),self.size()
@classmethod # for Python2.3 replace with read_ = classmethod(read_)
def read_(cls, filepath):
return NSImage.alloc().initWithContentsOfFile_(filepath)
Just a nit here, you should probably call this imageWithFilePath_ to follow convention. "read:" is a really confusing name for an initializer.
-bob
"...coding isn't the poor handmaiden of design or analysis. Coding is where your fuzzy, comfortable ideas awaken in the harsh dawn of reality. It is where you learn what your computer can do. If you stop coding, you stop learning." Kent Beck, Smalltalk Best Practice Patterns
smime.p7s
Description: S/MIME cryptographic signature_______________________________________________ Pythonmac-SIG maillist - Pythonmac-SIG@python.org http://mail.python.org/mailman/listinfo/pythonmac-sig