bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSAffineTransform setFrameOrigin broken


From: Nicola Pero
Subject: Re: NSAffineTransform setFrameOrigin broken
Date: Sat, 22 Jun 2002 19:28:46 +0100 (BST)

> While trying to test scaling views,

Do you have tests for scaling / rotated views ?

Can you share them with us ? :-)

I have been reading NSAffineTransform, prompted by your email, and my
feeling is that we still some work to have scaling / rotated views work
properly.

It's a pity we don't have tests for bezier paths and for scaling and
rotating views in the examples/ on CVS.


> I noticed that [NSAffineTransform
> -setFrameOrigin:] is broken if the matrix isn't the identity matrix.
> This causes the _boundsMatrix to become incorrect, and that messes up
> the calculations of _visibleRect and areas to draw.
> 
> Assuming setFrameOrigin: is meant to change the translation so that the
> passed in point is translated to origin, I've attached a patch that
> fixes it. It would be nice if someone else could verify that this is how
> it's supposed to work.

I didn't try out the patch, but your point seems quite reasonable to me.

I personally think it would be best to remove setFrameOrigin: from
NSAffineTransform, and modify the caller to do manually what it needs to
do, by using the standard methods.

I'm a bit confused by these undocumented methods, I'd like if we stick to
the documented ones ... and document carefully any undocumented one we
really need to use.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]