A
A
artursk2015-06-02 16:13:38
iOS
artursk, 2015-06-02 16:13:38

How to deal with auto layout in xcode6?

Is it possible in a storyboard, when collecting a 5.5-inch view controller (pictures and buttons are large), to set it up so that the autolayout itself reduces the screen elements in proportion to the size of these screens for smaller screen sizes?

Answer the question

In order to leave comments, you need to log in

4 answer(s)
A
Alexander Shcherbakov, 2015-06-11
@mkll

Now it is very fashionable for designers to make layouts for the iPhone 6 Plus, i.e. for the largest possible screen size. Looks great in presentations and other marketing materials.
But for layout, you need a design for the iPhone 5/5S at least, and preferably also for the iPhone 4S. And "assembling a view controller in a storyboard" is also better under 3.5-4", and not under 5.5".

P
Petrushka, 2015-06-02
@petruska

I myself am fluent in these matters, but you can
propor. First, tie the element to the edges, and then check the Aspect Ratio checkbox (do not touch Width, height)

A
An, 2015-06-03
@Flanker_4

It is possible in different ways
It is possible, as they wrote above, aspect ratio
You can simply nail the object to the edges, and set its GreatOrEqual width/height to some minimum value.
You can also bind the width / height of the view to the width and height of the parent view, but with a fractional multiplier (0.5 there)

D
daspisch, 2015-06-12
@daspisch

In iOS 7 and higher, there is such a thing as Size Classes, which allows you to set different layouts (or values ​​​​of specific constraints) for different screen sizes in one csb. There is a good article in Russian on Habré .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question