User Interface
Creating Circular and Infinite UIScrollViews
Editor’s Note: This post was written by Jacob Haskins, Director of Mobile Development at Accella. Thanks to Jon Stroz of Accella for reaching out to me to share this idea. When creating paging functionality for iPhone apps, there may be times that an infinite page loop would be desired. For example, if you have a [...]
Screen Capture using UIGetScreenImage
Editor’s Note: I read today (7/22/2010) that Apple is no longer approving applications using UIGetScreenImage. I haven’t been able to find an official Apple announcement on this – however, please give this consideration before using this method in your apps. As talked about on TUAW, among other popular blogs, Apple has opened up the API [...]
Showing Activity Indicator (spinner) in Table Cells
Following are two ways to display UIActivityIndicatorViews in a cell of a table view (UITableView). The first will add a spinner as an accessory view, which will display the spinner on the right of the cell. The second approach will add a spinner as a subview in the cell. The primary advantage of using a [...]
Adding an Activity Indicator (Spinner) to Navigation Bar
In addition to the standard buttons that you can place on a navigation bar (UINavigationBar), adding an activity indicator (UIActivityIndicator) can be helpful when you need a standard location to indicate some type of action is underway, for example downloading a file, performing a search… You add an activity indicator through a custom view as [...]
Validate User Input in UITextField, with Smarts to Properly Manage Copy and Paste
I’ve written a short character validation method that you can use as a starting point for validating characters against a character set. For devices running iPhone OS 3.x and thus support copy/paste, this code will also validate characters pasted into a textfield, and if invalid characters are found in the buffer, the input is not [...]
UIAlertView without Buttons – Please Wait Dialog
If you’ve ever wanted to show a simple “please wait” dialog without resorting to a custom view, UIAlertView is a good option, and is even more appropriate if you customize the alert such that no buttons are shown. In the figure below you can see how a simple alert can be shown (sans buttons) while [...]
Rotate an Image or Button with Animation – Part 2
In a previous post Rotate an Image with Animation – Part 1 I wrote a short code block using CGAffineTransform to rotate an image. Problem is, if you want to rotate an image 360 degrees, or repeat a rotation a specified number of times, you’ll need to take a different approach, which is the focus [...]
Detect Taps on UITabBarController and Determining Class Type
I’ve been working on an application which uses a UITabBarController as the primary means of navigation. One of the tabs leads one to a UIViewController that displays a UIWebview as the main user interface. The browser based navigation in the webview is based on a legacy (read WAP) website that has a great deal of [...]
Fade Transition – Fade Images In and Out
Although the iPhone includes a number of effects designed for transitioning between views, sometimes a simple fading effect of one image to another, within the same view, is all you need. For example, in a recent application during the application startup, I wanted the splash image to fade away, and another image of the primary [...]


