Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Storyboard in Xcode generates unwanted fixedFrame="YES" for all views in a controller

I'm using Git for source control, and it has enabled me to pinpoint exactly why one of my view refuses to position itself correctly. Turns out every view in a single controller has been set to be fixed by the fixedFrame="YES" XML property. I isolated this change from the commit it was written in, and it is now in my working directory. But here's the annoying part. I can revert the Storyboard file and properly, the XML will remove all the fixedFrame attributes. But as soon as I start make a new build for my test devices, the changes are re-applied before compilation, and all the views are set to a fixed width. It's driving me nuts.

I've deleted the derived data, incessantly cleaned the project file, restarted Xcode and my development machine.

I thought maybe the fixedWidth XML attribute was correlated to the Autoresize Subviews IB option, but toggling that has no effect on the generation of the fixed frame stuff. I figure there must be something unexpected in a meta-workspace-data kind of folder.

Really could use some extra help, I've searched for everything I can think of regarding this, and there seems to be no resolution in sight.

like image 875
user Avatar asked May 10 '14 06:05

user


2 Answers

I'm not sure if anyone will run across this problem the same way I did- but the answer is that all my constraints were removed for that Storyboard by some accident and without constraints, the fixedFrame property is automatically set when the Storyboard is generated.

Solution : Trash the commit that caused this, or layout everything manually again.

like image 186
user Avatar answered Sep 21 '22 03:09

user


You can go in and discard the fixedFrame hunks...

Storyboard fixedFrame

Or I have also found that cleaning, deleting derived data, and restarting Xcode can resolve the issue.

like image 29
Scott Gardner Avatar answered Sep 20 '22 03:09

Scott Gardner