ios - Auto Layout Scale Constraint Prop -


i new swift , trying make resizable view based on device type. using constraints , wondering if possible have horizontal space constraint instead of having constant value, scaled proportionally based on size of device.

right have horizontal space constraint constant value of 56.

i want when device becomes smaller constant value of 56 becomes smaller.

cheers

you need set leading , trailing constraints of view scale horizontally.

select view --> editor --> pin --> leading space superview

and same add trailing space.

you can set other way selecting pin button in right bottom corner: enter image description here


Comments

Popular posts from this blog

node.js - Using Node without global install -

How to access a php class file from PHPFox framework into javascript code written in simple HTML file? -

java - Null response to php query in android, even though php works properly -