Friday, January 23, 2015

Sizing Subview to Superview Using Autolayout with VFL and Cartography Using Swift

In talking with the Lead Developer of Mitosynth, I got inspired to get deep into Swift, Autolayout, and Cartography. And in the last 24 hours, I've been tearing my hair out with Autolayout in Cocoa using Swift. I finally got it down to a single question on Stackoverflow.

The answer to that question opened my eyes: Cocoa was "automatically adding constraints!" So without further ado, here are all my concepts wrapped up in one. This example uses Autolayout, VFL (using a nice category I made for Swift), and Cartography, too. Whoot!

No comments: