Re: [Pyobjc-dev] Class and instance methods of the same name
Brought to you by:
ronaldoussoren
From: Ronald O. <ron...@ma...> - 2010-04-21 10:38:27
|
On Wednesday, April 21, 2010, at 11:48AM, "Greg Ewing" <gre...@ca...> wrote: >The NSGraphicsContext class has class methods called >saveGraphicsState and restoreGraphicsState which can't >be called from Python, because there are also instance >methods with the same names, and PyObjC complains that >you haven't supplied a 'self' argument. > >Is there some other way of calling the class versions >of these methods? Which version of PyObjC? This should just work in PyObjC 2.2 or later (including the version shipped with SL). In earlier version you have to use a crummy way to call methods: NSGraphicsContext.pyobjc_classMethods.saveGraphicsState() Ronald > >-- >Greg > >------------------------------------------------------------------------------ >_______________________________________________ >Pyobjc-dev mailing list >Pyo...@li... >https://lists.sourceforge.net/lists/listinfo/pyobjc-dev > > |