It is very simple. You just need to understand what a machine is.
Here's how it works. Limitations are just a list of instructions; they themselves do nothing. There is a system message layoutSubviews , which is sent when you are not in control, so you have to imagine that it can be sent at any time. When layoutSubviews actually sent, constraints are constrained and respected (by doing exactly what you will do, i.e. the runtime sets the frame or bounds and center each view).
This way you can change the frame view, but keep in mind that if layoutSubviews sent and the constraints do not match the set frame , the view will return to where the constraints say, to express it.
source share