autoresizingmask

autoresizingMask for fixed margin sizes

In a view containing several subviews, one of the subviews should remain a fixed, non-zero distance from the top and bottom of the superview. In these images, this view is shown in gray: According to the documentation, this view should have a mask of UIViewAutoresizingFlexibleHeight | UIViewAutoresizingFlexibleWidth. However, this c...

Auto Resizing with Interface Builder and Code !

I want to use auto resizing mask in iPhone to adjust view in landscape and portrait mode. The problem is when I apply width spring from Interface builder, the button changes its size proportionally. But when I apply the same spring by code i.e. [self.view setAutoresizesSubviews:YES]; [testButton setAutoresizingMask:UIViewAutoresizing...

How to get the applicationFrame minus the height of the UINavigationBar?

I put this in loadView and it works: CGRect navFrame = [[UIScreen mainScreen] applicationFrame]; navFrame.size.height -= self.navigationController.navigationBar.frame.size.height; UIImageView *imageView = [[UIImageView alloc] initWithFrame:navFrame]; But is there a variable like applicationFrame that gives the applicationFrame minus t...

IPhone : Autoresizing on orientation change doesn't work correctly (sometimes doesn't seem to trigger at all) for some interface elements

I have been pulling my hair out one by one for 3 days now and still can't get the autoresizing on orientation changes to behave correctly :( I will try to describe the whole context, hope I won't forget anything important, if so just ask ! I plan to support all orientations on my App (only for some of the views, not all). So first thin...

UIView and AutoresizingMask ignored

Hi folks. First time posting on stack overflow. I've spent hours scouring over many Google searches and have, at this point, practically memorized the UIView and UIViewController class reference docs. No matter what I do, my app is ignoring my efforts to resize my views on orientation change (or any other frame size modifications for th...

Mistake in autoResizingMask

Hello people, i have implemented a small viewDidLoad() to show an Picture with autoresizing, but it doesn't work, could please someone help me and say what is the mistake in this code in line 3 and 4???? imageView = [[UIImageView alloc] initWithImage:img]; imageView.frame = self.view.frame; imageView.autoresizingMask = UIViewAu...

AutoResizing Image no imageView

Hello People, i am using AFOpenFlow in my app, but now the Problem is, the pictures I use are not the same size because they are from the web! And how can i autoResizing the image at the view of the iPhone??? Here is my code from this method: - (void)viewDidLoad { [super viewDidLoad]; // loading images into the queue loa...

UINavigationController Toolbar and device orientation (rotation)

So I have this iPhone app with a nested setup like this: [RootViewController]->[UITabBarController]->[UINavigationController]->[subViewControllers]. Everything is built programmatically, not in Interface Builder. I'm simply trying to support all device orientations. All of my AutoResizing masks are set up and everything rotates and expa...

Problem setting autosizing in interface builder

I have two viewControllers, one is a subclass of UIViewController (autoresizes correctly), the other one is a subclass of a subclass of UIViewController. I did a layout in Interface Builder, I tested my code in the Simulator and everything works as expected. But if I rotate the device my views don't resize. So I went back to Interface Bu...