Is it possible to change the coordinate system in a UIView so that (0,0) will be the top right hand corner?
A:
My answer bars the use of Interface Builder, but I know of no other way.
After initiating the UIView, perform a CGAffineTransform as such:
self.view.transform = CGAffineTransformMakeScale(-1, 1);
Check the documentation for CGAffineTransform. You might also have to translate the view a bit, although I believe it should be good.
The "-1" up there inverts the x coordinate system. Whenever you present a new view programmatically, it will work as you hope.
Cheers!
Jus' Wondrin'
2010-05-11 15:59:57
A:
self.view.transform = CGAffineTransformMakeRotation(90.0*0.0174532925);
self.view.bounds = CGRectMake(0.0f, 0.0f, 480.0f, 320.0f);
should do it for you
Andiih
2010-05-11 16:00:54