TheJoyOfHack

For people who like to make things

Rotation and Adaptive Layouts

Another in a series of posts documenting my process of updating an aging app.

For this rewrite of Qur’an Memorizer I’m using Auto Layout. This is the first time I’ve used Auto Layout for this app. You know when the Apple Engineers said Auto Layout makes things easy? They weren’t kidding. Even though Qur’an Memorizer has some unique behaviors for autorotation, I was able to implement this in a few hours with Auto Layout and about 25 lines of code. Read on to see what I did.

more ...

Code Coverage Without Pod Files

Another in a series of posts documenting my process of updating an aging app.

I noticed that the code coverage reports from XCode 8 recently started showing me coverage for .m files that were in the CocoaPods that I’m using. In this post I document how I fixed that.

more ...


Evolution of Objective C Database Code

First

One of the features of Qur’an Memorizer, my first iOS app, is the ability to highlight a verse (ayah) when it’s tapped. To do this I access a database of verse x and y locations and retrieve the 4 coordinates I need to draw the resulting polygon.

The first version of the code released to the App Store looked a little bit like this:

more ...