Ans :
Use of multiplier in constraint |
We took 2 views - Orange and Green.
We set orange view's top, leading, trailing constraint to main view as 0.
Same, we set green view's bottom, leading, trailing constraint to main views as 0.
Now,
We select height constraint of orange view equal to main view's height. And set multiplier 0.6. It shows ratio of orange view's height to main view's height. We have set 0.6 = 60/100 . So orange view's height become 60% of main view's height.
Set multiplier of height constraint in size inspector |
Same we have done with green view and set multiplier 0.4 = 40/100 means 40%.
If you have any comment, question, or recommendation, feel free to post them in the comment section below!
No comments:
Post a Comment
Thanks