简体   繁体   中英

Autolayout and constraints not working, buttons look different in Xcode than they do in IOS SImulator

Both Xcode and the iPhone simulator are set to iPhone 6. The frames are updated. I even changed the simulated metrics under the attributes inspector to iPhone 5.5 inch screen.

I tried adding constraints for the width and height but received an error in Xcode every time I ran the simulator with them on so I took them off.

This seems to happen a lot with buttons and labels. Been stumped for hours, researched all I could, finally decide to post it on here.

I just joined so they won't let me post a pic of my problem because I don't have enough rep points.

iPhone 6s have the option when you first set them up to work in 'zoomed view' or normal view. if the iPhone is set up in display settings to be zoomed, then it will display as though the phone was iPhone 5/SE size, but zoomed in. you should always check your constraint's behavior on all screen sizes, and I'd also confirm if this is an issue by checking your devices' settings.

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