I am working on the project I described in IPhone development: How to build a custom view hierarchy? . I am still struggling with the issues I described in that topic and meanwhile I tried to do something meaningful.
I needed to print a background image in the first view and I wrote the following code in my _MyAppName_ViewController.m class:
self.backGroundImage = [UIImage imageNamed:@"giris.jpg"];
self.view.backgroundColor = [UIColor colorWithPatternImage:self.backGroundImage];
backGroundImage is a property I declared in the header file, in the type of UIImage. giris.jpg is an image with the size of 640x960 but what I see in the simulator is that the upper left 320x480 sized part of the image. I tried to change the IOS Simulator Device type from IPhone to IPhone (Retina 3.5 Inch) and to IPhone (Retina 4.0 Inch) but I get the same results. Is there something I am missing in the code?
giris.jpg
should be 320x480, and you should have also a[email protected]
in your App Bundle. Then UIKit will select the right one for you. – Boris Prohaska