Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xcode 6.1: UIViews disappearing in interface builder when adjusting frames

I'm fairly new to Interface Builder and I'm trying to practice it with a very simple view. Basically, I have 3 UIViews on my view controller. The problem I am having is that whenever I adjust the frame of 1 of the UIViews, the other 2 will disappear.

Here is a short 7 second video of the problem: https://vine.co/v/OMlbMIdWMe5

If I run the app on my device, I only see 1 of the views (the 1 I was adjusting) - the other 2 remain hidden.

I am using Xcode 6.1 . What could be causing this?

***EDIT: If I add 1 constraint to a view, it won't disappear when I readjust the frame of the other view. That is:

Add a constraint to ViewOne then readjusting size of ViewTwo will only cause ViewThree (without any constraints) to disappear.

So the solution is to add constraints to all 3 views before readjusting the frame of any of them. But still, what could be causing this issue?

like image 673
Lneuner Avatar asked Jul 03 '26 23:07

Lneuner


1 Answers

This is an issue with Xcode 6.1, and has been reported to apple. A similar post can be found here.

WORKAROUND: I have found that you can edit the constraints in the right hand pane of the storyboard editor, in the size inspector. It actually does not prove that tedious.

like image 192
Sean O'Bannon Avatar answered Jul 05 '26 16:07

Sean O'Bannon



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!