Beveled UITableViewCells

Tariq Zaid
Jan 15, 2010

Recently while working on our upcoming Basecamp iPhone App, I found myself in a situation many iPhone developers can relate to: creating a custom, reusable UITableViewCell with some fancy new style. In our case, we needed a UITableViewCell with a beveled border that works with the grouped tableview style. After an hour or so searching google with limited success and looking at solutions I wasn’t quite satisfied with, I decided to chalk up my own. Here’s the end result:

Beveled UITableViewCells

Beveled UITableViewCells

To achieve the beveled look, we first need to understand how the UITableViewCell renders when it is used with the grouped tableview style. The UITableViewCell has two properties that are of particular importance: backgroundView and selectedBackgroundView. When using the grouped style, the tableview notifies each cell to render these views (mostly likely by setting a flag on the cell) to achieve the nice rounded finish we’re all used to.

So the first step is to create the background views for the custom rounded beveled finish. The bevel effect is achieved by rendering two rounded rectangles. First, draw a rounded rectangle and fill it with a linear gradient (dark gray at the top to white at the bottom). Next, draw a slightly smaller rounded rectangle and fill it with solid colour. Here’s the code to render the background views: (more…)



Development of our Basecamp iPhone App Headquarters

Adam McNamara
Jan 10, 2010

We’ve started developing a Basecamp iPhone app!

Why isn’t the first thing I see when I start a Basecamp app everything that I’m late on, responsible for today, and responsible for in the immediate future?

We’re a goal oriented team.  This means setting clear milestones and todos and attacking them each day.  Headquarters is designed to show you all of that information without having to drill down and search through individual projects.

We’re working hard to make the app fast, intuitive, and unique.  The app incorporates a lot of custom UI code.  The “Headquarters” series of posts will cover code techniques we used in the Headquarters Basecamp app.



An Indie AppStore Section

Adam McNamara
Dec 23, 2009

In October, the lead developer of Tumblr Marco Arment made a very eloquent post about the existence of “Two AppStores.”

AppStore A

Simple, shallow games and apps with mass-market appeal. These live and die by the App Store’s “Top” lists, so success is difficult to achieve and is short-lived at best, but with the largest potential payoff for the lucky few at the top.

AppStore B

Apps and games with more complexity and depth, narrower appeal, longer development cycles, and developer maintenance over the long term. These tend to get little attention from the “Top” lists, instead relying on the much-lower-volume App Store features (e.g. “Staff Picks”), blogs, reviews, and word of mouth. More of their customers notice and demand great design and polish. More sales come from people who have heard of your product first and seek it out by name. Many of these apps are priced above $0.99.

At first glance, this theory makes sense.  But here’s the problem.  Here’s the “Top Paid” section of the AppStore in Canada right now:

(more…)



How Much Does an iPhone App Cost?

Adam McNamara
Dec 21, 2009

One of the most frequent questions we get is “How much does an iPhone App Cost?”  The answer is always “It depends…”  In this post we explain what factors contribute to application development costs.  To be clear, we’re referring to professional software design and development.  There are many alternatives to this approach including freelance iPhone developer boards, but that isn’t our market*.

There are many approaches to software pricing, so in the interest of transparency, here’s what we look at:

1 – Scope

The scope of the project is almost linearly related to its price.  As with any software project, each view requires careful thought and planning, coding, styling, and testing.  As the application gets larger, development costs naturally increase.

2 – Complexity

Do you have something completely revolutionary that you’d like to build?  Loren Brichter created a beautiful application in Tweetie 2.  He went on to call it “deceptively simple”.  Its technical complexities are hidden by its beautiful interface and ease of use.  Exhibit A: Tweetie’s custom tab bar.

Tweetie Custom Tab Bar

(more…)



Linking Objective-C Static Libraries with iPhone 3.0 SDK

Adam McNamara
Dec 21, 2009

With the latest release of the iPhone 3.0 SDK, we’ve been preparing to push out some applications onto the AppStore (which we will discuss and unveil at a later date) however we hit a few small annoying problems. One of these annoying problems was linking our Objective-C static library with our iPhone application. With the 2.2.x SDK, this process was very straight forward and we had assumed that this would be the case with this SDK as well. However, it turns out that there has been a change in the required flags for linking the library properly.

Before, what you would do is simply specify “-ObjC” under “Other Linker Flags” and this would allow you to compile just fine. However, with the latest SDK we found that you must also specify: “-all_load” as well. Oddly enough, without “-all_load” everything will link just fine, however you will receive runtime errors whenever you attempt to invoke functions that were defined within categories.

(more…)



Alternate Views for iPhone Orientations

Adam McNamara
Dec 21, 2009

The iPhone gives you the option to show content in both landscape and portrait modes. As you well know, you can respond to orientation changes using:

-(BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
//do something fancy here...
}

Typically developers show the same view for both orientations. However, sometimes you want to show a different view for an orientation change. For example, have a look at the iPhone Application we developed for Gazaro. Here’s the detail view of a deal on a MacBook:

(more…)



Powered by Olark