简体   繁体   中英

How to set auto layout on all iOS devices?

So basically I have this problem where all my auto layout constraints look fine on all devices except iPhone 5s and SE. Also, the constraints look different for iPad devices but are generally the same. How do I have it so that the constraints look the same on all devices??

Below shows iPhone 8 vs iPad Pro

iPhone 8

iPad Pro

What you are discussing is possible, it is called Trait Variation that allows you to set up layouts based on different device dimensions and categories.

Here is a tutorial that discusses it and explains how to use it: https://www.techotopia.com/index.php/Using_Trait_Variations_to_Design_Adaptive_iOS_User_Interfaces

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM