Accessibility in iOS

19th of December, 2010

This is an incredible article from Matt Gemmell; it should, along with Apple's Accessibility guidelines, be required reading for all iOS developers.

OAuth Controllers

10th of September, 2010

Useful OAuth Sign-in Controllers from Google. Still, I wish there was a better way to authenticate than throwing up a web view, it's messy as hell on an iPhone.

Think of the Children

9th of September, 2010

The introduction to Apple's published App Store Review Guidlines (requires a paid-up developer account) is kind of hilarious. The highlights:

We have lots of kids downloading lots of apps, and parental controls don't work unless the parents set them up (many don't). So know that we're keeping an eye out for the kids.


We don't need any more Fart apps.

Someone tell that to Phillip Shoemaker!

We have lots of serious developers who don't want their quality Apps to be surrounded by amateur hour.

Really? If apps suck they won't gain any traction and no-one should ever see them; I can't see how this is a problem at all.

Revised App Store Guidelines

9th of September, 2010

Apple has revised the rules by which submitted apps much abide:

In particular, we are relaxing all restrictions on the development tools used to create iOS apps, as long as the resulting apps do not download any code. This should give developers the flexibility they want, while preserving the security we need.

The changes affect the notorious section 3.3.1, along with sections 3.3.2 and 3.3.9. This isn't actually a huge shift — it mainly restores the status quo pre-Flash CS5 — but it does make things a little easier for developers using frameworks like Unity.

Site Updates

8th of September, 2010

Between other projects I (finally!) found the time to update the site. The only visible change is the much more minimalist theme that should look a lot better in crap browsers and mobile devices. The backend is where most of the work went though; I gutted out the old framework which was more or less a patch on Google's webapp framework and replaced it with my own WSGI-based framework. The interfaces between the two are radically different, so this involved tediously updating each request handler.

I also started making use of App Engine's cooler features like the blobstore (which has a miserable API1) and task queue (which has a great API). Almost everything is memcached now so page loading should be much snappier, unless your request happens to spin up a new instance.

There's a little more to come, mainly on the JavaScript front: look out for JSON-fueled asynchronous pagination and forms soon.

  1. It's forgivably bad though, given the environment constraints. Performance is good too.

UIWebView Cache Substitution

7th of September, 2010

On another UIWebView note, Matt Gallagher has a typically excellent post on substituting local data for remote resources using NSURLCache.


7th of September, 2010

This is really cool; dynamic image scaling for mobile devices:

If you're designing web sites for mobile, you need to make sure your graphics work on thousands of differently-sized screens. Let tinySrc take care of the hard work.

(Yup, that's it.)

I've already played around with this by automagically modifying the href attribute of each anchor element in a UIWebView document; works like a charm.

Paypal is the Worst Company in the World

31st of August, 2010

John Cole is the latest in a long list of people to be screwed by Paypal's crazy verification policies.

Usable Financial Reports

25th of August, 2010

Great new Financial Reports module on iTunes Connect.

September 1st

25th of August, 2010

Apple will hold their Autumnal, musically-inclined event on the 1st of September; I expect we'll see the revamped Apple TV, iPods with Retina displays and cameras, and hopefully some cloud-based services like iTunes Live. Also making an appearance: incredible sales numbers for the iPad and iPhone 4, featuring unnecessary hyperbole.

App Store Volume Pricing

10th of August, 2010

Apple have introduced a nifty program where developers can sell their apps to schools and colleges in bulk for a 50% discount:

The App Store Volume Purchase Program makes it easy for education institutions to purchase multiple copies of your app.

You can choose to offer special pricing that is 50% of your list price to education institutions when they purchase 20 or more copies of your app. You have the option to apply this special pricing to all of your applications or only individual applications.

It's a great idea, although I wish they'd give developers a little more flexibility in setting the discount rate. Also, I wonder how they're going to determine what counts as an education institution; typically, Apple use university email addresses for verification but this would be fairly cumbersome for primary and secondary level institutions.

Introducing Stack Up

3rd of August, 2010

For the last couple of months I've been putting together a Stack Exchange client for iPhone using the recently released API. The app, Stack Up, is on sale for $0.99 until the 8th of August; after that, you can get it for $1.99.

For the more information check out the project page, the dedicated site, or the stackapps page.

Xcode 4

23rd of July, 2010

Apple have seeded the Xcode 4 preview shown off at WWDC to developers, and man is it a big update. No word on when the final version will ship, but I expect it'll shown up in November with iOS 4.1.

Lonely at the Top

17th of July, 2010

Matt Drance has an interesting perspective on the iPhone 4 debacle:

Whether you are the CEO of the second largest corporation in the U.S. or a general in the U.S. military, it should be no surprise when the press reports what it sees and hears. If a media outlet reports garbage, then all things being equal, its reputation should pay a price. If it has information that it believes to be both material and credible to a relevant topic, it is not obligated to sugarcoat that information, but to report it.

Antennagate is news exactly because Apple has hit so many home runs—and, by the way, received countless glowing headlines to match. Apple should be nervous when this sort of thing isn't news: it would mean nobody cares anymore.

As I said earlier, I think the press conference was by and large a success; however, Apple will soon run out of goodwill if they continue to respond to criticism the way they did before Friday.


16th of July, 2010

So, Apple will give out free bumpers to iPhone 4 owners, but only until the 30th of September, which strikes me as a cheeky but ultimately cost-effective way of dealing with the problem1. As expected, the New York Times article describing a second software fix was bogus. I was pleasantly surprised by the tone Jobs took, which was notably less combative and much more conciliatory than I expected. In fact, it was downright humble by Cupertino standards which should go along way to sowing some goodwill after the initial “quit holding it wrong” response. Overall, I think it was a very effective presentation by Jobs, and I expect the mania to cool dramatically over the weekend.

  1. I think there's a good chance Apple will continue to ship bumpers with new iPhones after September if they haven't come up with a better solution; Jobs seemed to suggest as much in the post-presentation Q&A.


16th of July, 2010

Every single time the New York Times quotes an anonymous source, they use the exact same phrase somewhere in the text: “agreed to speak on the condition of anonymity because he was not authorized to discuss the matter.” It's difficult to put into words how annoying this is.

Another Software Fix

16th of July, 2010

So says the New York Times:

One person with direct knowledge of the phone's design said Thursday that the iPhone 4 exposed a longstanding weakness in the basic communications software inside Apple's phones and that the reception problems were not caused by an isolated hardware flaw.

The person said the problems were longstanding but had been exposed by the design of the iPhone 4.

I find this hard to believe. An exposed antenna which attenuates when bridged by one's hand is something that really can't be fixed by software1, no matter how often Apple says so.

  1. Unless of course I'm completely missing something, but this just strikes me as implausible no matter which way you look at it.

iPhone Arrow Icons

16th of July, 2010

I couldn't find any decent high-resolution arrow icons on the web suitable for use in a UINavigationBar or UIToolbar, so I put my limited Photoshop skills to the test and created my own. There are eight icons in total: four directions in both standard and high-definition sizes. They're basically a recreation of the up and down arrows found in and the forward and back icons found in Mobile Safari. The images are shared under a Creative Commons license, so you're more or less free to use them however you see fit.

You can grab all eight icons here. Licensed under a Creative Commons Attribution 3.0 License.

The Press Conference

15th of July, 2010

John Gruber thinks something big is going down tomorrow. It's difficult to tell, but I will say this: a press conference to simply push back against industry criticism is not something I would have expected from Apple, who normally only take the stage to announce a product.

Software Fix and a Press Conference

14th of July, 2010

A beta version of iOS 4.1 was seeded to developers today (you'll need an active iPhone Developer account to follow the link), which includes, among other things, the software side of Apple's response to the iPhone 4's reception woes. Apple are also holding a press conference this Friday, presumably to try and put a lid on the whole thing once and for all. I still think it's unlikely they'll go any further than this weak software fix, although there's probably still a slim chance they'll start shipping free bumpers.

Windows Phone Live

13th of July, 2010

I know I sound like a broken record, but I'll say it again: Apple's biggest weakness is in cloud-based services. They do offer MobileMe, but for ~80 a year and with a limited set of features1, most of which are available for free elsewhere. Obviously Google were always going to excel in the cloud so Android outclassing iOS in this area is to be expected, but now Microsoft will offer a free package of tools, predictably dubbed Windows Phone Live, with a panoply of functionality for devices running Windows Phone 7:

A feature we're discussing for the first time today is the new Windows Phone Live companion site that gives people a central place to see pictures they've published, view their Windows Live calendar and contacts, exchange OneNote files and access other information shared between the phone and the Web. The site will offer 25GB of SkyDrive and host the Find My Phone service, which allows people to find and manage a missing phone with map, ring, lock and erase capabilities right from your PC — and all for free.

It looks pretty competitive, certainly better than what either Apple or Google are offering at the moment. It goes without saying that you shouldn't judge a product based on a spec-sheet taken off of a Microsoft website, and it could end up being a UI disaster or plastered with ads like Hotmail, but at the moment it's good stuff.

As John Gruber said a few months ago, Apple doesn't do loss-leaders so I don't really expect them to open up the full MobileMe suite to everyone for nothing. But they certainly could offer some functionality like remote-wipe for all users. Surely they could factor the cost of providing this service into each iPhone, knowing it will only be usable by iPhone owners. In fact, MobileMe may already be heading in this direction; the new account status that began popping up before WWDC would certainly suggest Apple are at least toying with the idea of a tiered pricing structure.

  1. Highly polished features, it must be said.

Rock and a Hard Place

13th of July, 2010

Apple will eventually have to address the reception issue again; once they ship the somewhat silly software update, and all that happens is iPhone users see less reception than before, I can't really believe the dissatisfaction will simply evaporate. They've done themselves no favours by pointing the finger at an algorithm; it only makes it more difficult for them to actually address the hardware issue.

There are no good solutions, at all, from Apple's point of view. A recall is simply out of the question, Apple would never go for it; I think they'd gladly weather the PR storm and hope users start holding the iPhone the right way. I also think they're unlikely to rev the hardware; the backlash would be immense and they'd probably have to accommodate customers wanting to trade in their current iPhone for a revised model. One simple and relatively cost-effective solution would be to ship the currently outrageously over-priced bumpers with new iPhones, for free. This too seems unlikely for a couple of reasons: 1) Apple said they wouldn't, and if they figured it would make the complaints go away they probably wouldn't have come out so forcefully against it, 2) It would be admitting that there really is a hardware issue, something Apple clearly does not want to do, without actually addressing it which creates problems for them down the road, and 3) Gizmodo have been pimping the idea for weeks now, and if Gizmodo wants it chances are Apple won't do it.

Anyway, one thing is clear: fairly or unfairly, the perception of the iPhone being a crappy phone but an otherwise great device is pervasive and Apple needs to come up with a real, non-diversionary solution and end the “there is no problem” theatrics if they want to combat this trend.

Marco Arment on the iPhone 4

13th of July, 2010

It can be difficult to acknowledge that a product you otherwise love has a couple of significant flaws. That said, the white-washing of the iPhone 4's reception issues by the company and, much more regrettably, some writers is still disappointing. So, it's extremely refreshing to hear Marco Arment say this:

Apple's arrogance and indifference in issuing this response is offensive, insulting, and disappointing. It's as if they're expecting this issue to go away if they just wait long enough and ship enough iPhones. But it won't. It's only going to get worse as more people try to exchange their iPhones at the Genius Bar for these two issues, thinking it's just a problem with their iPhones, and encounter the same problems with every replacement.

Android Inventor

12th of July, 2010

It's an interesting idea, although the only way it can possibly succeed in driving development on Android is if it functions effectively as a gateway drug to more powerful tools. The next logical step is to facilitate apps written in dynamic languages; a fairly undaunting task given Android's architecture. Learning basic Ruby or Python would be an obvious progression for Inventor veterans, even if only to inject more complex logic into Inventor-based apps.

Remote High-Resolution Images

3rd of July, 2010

Adding high-resolution artwork to an iOS 4 project is extraordinarily easy; all you need to do is add the new files to your project in a particular format (imagename@2x.png alongside an existing imagename.png), and UIImage will automatically load the appropriate file depending on the screen scale.

However, if you're loading images remotely, you'll need to do some of the work yourself. Here's an example of how to fetch a gravatar portrait depending on the device resolution:

float size = 40.f;
if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 4.0) {
    size = size * [[UIScreen mainScreen] scale];

NSString *url = [NSString stringWithFormat:@"", emailHash, size];

NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:url]];
NSURLConnection *connection = [[NSURLConnection alloc] initWithRequest:request delegate:self];

// implement the NSURLConnectionDelegate methods,
// and use the resulting data in [UIImage initWithData:data];

As you can see, it's relatively straightforward: just grab the screen scale from [[UIScreen mainScreen] scale] and use it to determine the resolution of the image you want to download.