1991-2016—25 years of Art & Logic

A Cocoa Color Mystery

A Cocoa Color Mystery

The Problem

A project for an image processing Cocoa app last year ran into some difficulty when images produced had small color differences compared to the results of previous versions. We had changed most of the infrastructure as we ported this former Photoshop plug-in. We had to consider many systems as possible culprits. Did the colors shift on loading? During format conversion? During processing? Converting for display? Or when saved to disk? Did the format of the image file matter? Did Photoshop do something Cocoa wasn’t doing? It was a slog, but that last one proved to be the right question.

(more…)

Learning Auto Layout for iOS, tvOS, and OS X

Learning Auto Layout for iOS, tvOS, and OS X

iPadPro10-ApplePencil-SmartKeyboard-Splitview_PR-PRINTWith the release of the iPhone SE and the iPad Pro, along with the expectation that iPad apps will include support for slide over and split screen mode it’s now clear that Auto Layout is here to stay. If you’re not already developing apps using Auto Layout and Size Classes now is a great time to learn more about them and prepare yourself for any updates to the APIs that Apple introduces at WWDC in June.

Fortunately there’s a lot of great resources to quickly get up to speed and learn the best way to support a variety of devices and size classes in your next app.

(more…)

2014 Review: Day 3

As 2014 winds down, we’ll take an opportunity to look back at some of our most-read posts from this year, in case you missed them the first time. 

 

4319953731_fa8659d820_b

 

Steve Huey took us on a quick tour of a key/value store for iOS that’s built on top of the ubiquitous Sqlite:

(more…)

YapDatabase – A Great SQLite-Based Alternative to Core Data

Synchronization and Core Data in Modern iOS Apps

I’m working on an iOS project that synchronizes a lot of data between a web service and an iPad app. We’ve relied on the advice and research in the fantastic issues of objc.io on Core Data and Syncing Data along with performance recommendations from Florian Kugler’s research into Core Data stack configuration and overall the solution is working pretty well for us at this point, but it hasn’t been without its challenges.

4319953731_fa8659d820_bThroughout the project I’ve been trying to follow industry news and research to keep up with best practices, interesting sync experiments, and usage of Core Data in iOS 7. A recurring question in much of this is whether to use Core Data at all, and if not what you give up and what can you possibly gain in the process?

Brent Simmons’ series of Vesper Sync Diary posts (linked to below) cover this design and decision process in incredible detail and are well worth the read, culminating with his Hard Core post where he ultimately decides to go ahead with a SQLite based solution instead of using Core Data. When using SQLite the go to solution for Mac or iOS is Gus Mueller’s excellent fmdb framework, however another SQLite based solution with a higher level API and different approach has emerged that is well worth a look too, called YapDatabase. (more…)