Monday, March 2, 2009

Info.plist tricks

Often developers miss out on a couple of tricks that can clean up the way the application looks while launching. Admittedly thse adjustments can be made programatically within an early function such as applicationDidFinishLaunching; however, it's visually appealing to make changes prior to the splash or loading screen. There is only one way to do that and it's the Info.plist file.

Orientation

Usually iPhone / iPod Touch applications launch in a portrait mode. Games and web browsers may instead want to launch into a landscape mode. Most developers use landscape right mode. But it's worth noting that the external speaker is often very easily covered by the right palm when the device is in landscape right mode. It's worth considering landscape left orientation as well.

Edit the Info.plist file. Add a key called UIInterfaceOrientation. Set the value to UIInterfaceOrientationLandscapeRight. Other possible values are UIInterfaceOrientationPortrait, UIInterfaceOrientationPortraitUpsideDown, and UIInterfaceOrientationLandscapeLeft.

Status bar

It's always nice to grab more screen real estate and that little bit at the top that's wasted for the status bar for the time and cellular carrier strength is easy pickin's.

Again, edit the Info.plist file. Add a key called UIStatusBarHidden. Set the value to YES.

It might also be the case that it's appealing to retain the status bar for some reason but the application has a dark color pallet. In this case you won't want the default high brightness white status bar. Edit Info.plist again, this time add a key called UIStatusBarStyle with a value of UIStatusBarStyleBlackOpaque or UIStatusBarStyleBlackTranslucent.

Labels:

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home