On xib, dragging view will automatically go inside a bigger view

82 views Asked by At

In my xib I have one UIView and one UIImageView. The UIView covers all the xib, the UIImageView one is much smaller. If I drag the UIImageView, it snaps automatically inside the view.

It drives me insane because I never want that. I just want to change its position and the only way I can do that is from the Utilities/Size Inspector. But is very frustrating when I have a lot of objects and I can't use drag & drop to move things around.

Is there a way to prevent/disable this, please?

Thank you.

3

There are 3 answers

2
sohil On

you can do that with use of click on size inspector. First you can select UIImageView and then goto the size inspector and change x and y.

2
tailec On

You can use arrow keys on your keyboard or set it in size inspector pane.

2
Inder Kumar Rathore On

The easiest way is to uncheck the installed checkbox of larger view while you are moving/adding another view

enter image description here