Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Kizmar

macrumors newbie
Original poster
Oct 28, 2010
22
0
New to iOS development, as well as Macs... so...

So I started a new project. The first thing I tried to do is set a background image for all views. I haven't been able to figure out how to do this without adding a UIImageView to each view separately, which seems redundant.

The thinking here is that I can set a background image that all views will inherit, then if I want to change it I don't have to do it for each view.

How do I accomplish this, or does it just not work this way?
 
There is no concept of an application background. Depending on your application/view structure you might be able to achieve something similar. For example if all the view controllers inherit from a common base class it can create the UIImageView programatically solving your issue (if the views you layer above it have transparent backgrounds).
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.