Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to switch skins (or design themes) in iOS app?
    text
    copied!<p>I'd like to make my iPhone app to be able to switch between skins (or design theme, or look and feel, such as wooden, metal, earth color, men's, girls, etc...).</p> <p>I'll prepare some sets of skins that contains images for buttons and backgrounds, sounds, and text color, and let the user decide which set of skin they want to use by the application settings.</p> <p>What is the best practice to implement this?</p> <p>The conditions are:</p> <ul> <li>I'd like to use Interface Builder</li> <li>I need to support iOS 3.1.3 and later</li> <li>I want to make the sets of skins downloadable from the internet (I can't bundle all the skins in the app, as one set of skin requires lots of images and the app file size could become huge if I do so... I also don't want to hardcode any information about specific skins.)</li> <li>If a custom skin does not contain one or some elements, (such as an image or sound file), I want it to use the missing element from the default set of skin.</li> <li>I don't want to create Nib files for each skin. The Nib file for one screen should be the only one in the main bundle for easier maintenance.</li> </ul> <p>I'm thinking about making a superclass of all the UIViewControllers in my app and override the part that it loads Nib file, and instead of loading from the main bundle, load the resources from the skin that is saved in the Document directory... but I don't know how to do it... The default behavior of the Nib-loading methods always loads resources from the main bundle and the information about resource file names are lost after reading... :(</p> <p>Thanks in advance for your help.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload