[Pyobjc-dev] Problems with 1.1a0 and NSImageView.setFrameSize_ ()
Brought to you by:
ronaldoussoren
From: Francesco P. <fpi...@no...> - 2004-02-05 20:39:53
|
Hi, I have an application that works great with PyObjC 1.0 but hangs with 1.1a0. It turns out that this line of code self.setFrameSize_ (new_size) just hangs under 1.1a0. Some background: I have a NSImageView subclass (MyImageView). In a method of this subclass (zoom_to_fit ()), I set up an affine transformation: self.transformation = NSAffineTransform.transform () self.transformation.scaleBy_ (self.fb.zoom) (where self.fb.zoom is a float), I then use the transformation to scale the current frame buffer size: (w0, h0) = (self.fb.width, self.fb.height) new_size = self.transformation.transformSize_ ((w0, h0)) (w0 and h0 are, again, floats) and then resize the view's frame: self.setFrameSize_ (new_size) With 1.1a0, new_size is a Foundation.NSSize. I also tried self.setFrameSize_ ((new_size.height, new_size.width)) without luck. Any idea of what could be going wrong? I am clueless... Thank you fra P.S. when the app hangs, these are the values that get used: self.fb.width = 512.0 self.fb.height = 512.0 self.fb.zoom = 1.0 |