April 2020
Intermediate to advanced
528 pages
15h 40m
English
As we mentioned earlier, before Auto Layout iOS applications used another system for managing layout: autoresizing masks. Each view had an autoresizing mask that constrained its relationship with its superview, but this mask could not affect relationships between sibling views.
By default, views create and add constraints based on their autoresizing masks. However, these translated constraints often conflict with the explicit constraints in your layout, which results in an unsatisfiable constraints problem.
To see this happen, comment out the line in loadView() that turns off the translation of autoresizing masks.
segmentedControl.translatesAutoresizingMaskIntoConstraints ...
Read now
Unlock full access