Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
621 views
in Technique[技术] by (71.8m points)

layout - iOS: autolayout for multiple button

In my app I have a view for 4 inch screens in this way:

enter image description here

And then I want to reduce the size of my buttons when the app is running on an iPhone with a 3.5 inch screen, so I set my layout in this way:

enter image description here

but finally I obtain a view in this way

enter image description here

In this way the size of my button are ok but they are not aligned, so in this situation, what's the way to have aligned buttons?

thanks

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Hi as per your question i've created demo similar to the layout for which you need the controls need to set. I've added images for single control and made video this using multiple controls to set the layout which you retrying to set.

enter image description here enter image description here



link: https://www.youtube.com/watch?v=Nl2iMF0yKW8&list=PLXCowKcXAVgrxHKLWTa4HxNPrSmTj3D-_
Hope this will solve your issue.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...