iOS: Resizing UIImageView with AutoLayout
autolayout, ios, uiimageview
Solution
- Choose your ImageView in Interface Biulder.
- Press pin button.
- Set the constraints.
Example
Problem
I am new to AutoLayout and struggling with it a bit. I have a `UIImageView` which is part of an UIView. When the app is running on a 3.5 inch device, I want the UIImageView to resize according to the change of the screen size. I am not sure how to achieve this. From what I have seen so far, you can only set a fixed width and height of the views, is it possible to make them dynamically resize ? In other words, how can the `UIImageView` resize accordingly to the super view's height ?