xcode 6.2. view controllers greyed out, locked - ios

I have a xcode project with buttons and other objects in it. But the objects are all greyed out in my view now. The project still compiles and shows the buttons fine. I saw posts about using auto-layout, changing size-classes, and modifying the IB. But whenever I make any of those changes, a lock icon shows on the screen and nothing changes. I can go back to an old version of my code, but I'd rather find out what will fix the issue.
What was I doing to break it? I was just exploring through the different xcode windows and views, and don't know exactly when the viewcontroller objects became affected.

Related

Xcode Project Settings Preventing TabBar at Bottom of iPhone X Models?

I have an old project that I've been working on and off on for about 4 years now - the project has gone through many upgrades of XCode versions from 6 to 10 (I'm now using XCode 10.2.1 with 12.2 SDK). The main problem I'm having with it is that it utilizes a Tab View Controller to switch tabs, and no matter what I do, I cannot get the tab bar to appear on the bottom of an iPhone X family device correctly: it appears much higher than it should.
To try and finally narrow down the problem, I've essentially temporarily "replaced" all code and storyboard items from the project to see if anything will move the tab bar to where it's supposed to (if I just create a blank new project with a tab bar controller, the tab bar does appear where it should). I created a test storyboard with just a Tab Bar Controller going to one navigation controller (no constraints have been put in). There is no viewController codes attached to them. I've replaced the app delegate with a "blank" app delegate so there are essentially no extraneous code or restraints there at all. And I still get the tab bar moved:
This happens on the simulator and the device, and there is no code or storyboard setting that's doing this (this same setup on a new project puts the tab bar in the right place).
I've looked around in the Build Settings and other properties that I may have missed to see if I constrained something years ago that may affect this, and didn't see anything.
Is there anything I should be looking for in the project settings that would do this?
I don't want to rebuild the project in a new project - there are many linked libraries, certificates, cocoapods, storyboard items, and I know it would be horrible to try and put it all back in one piece.
My Deployment Target is set to iOS 11, Devices: iPhone, Base SDK: iOS
Any help would be greatly appreciated!
This is usually caused by not having a correct launch image for the iPhone X. The easiest way to fix this is to tell the app target not to use launch images (from the app bundle or from the asset catalog) but to use the LaunchScreen.storyboard instead. (If you don't have one, make one; be sure to set it as a launch screen storyboard by clicking Use As Launch Screen and configure your target to point to it. Examine a plain vanilla new project to see what I mean.) You might not want to keep things that way in the long term but at least it will allow your app to launch to the correct size on all devices.

Solid blue rectangle on XCode Tab Bar View Controllers that won't go away?

I recently looked at my app's main.storyboard and realized that there is a big, blue, rectangular box covering half of some of my viewcontrollers (image is pasted here). Only the UIViewControllers connected to the UITabBarController are affected. I did not even realize that this had happened, despite having moved to xCode7 a while ago. It is a bit annoying since dropping any UI element into the view controller causes that element to 'go behind' this blue region and so I can't see them. It is not that the default color is set to blue or anything; it is not a clickable object to even set display parameters to. Anybody have any ideas how to fix this... or even what it is?
Edit: This is not a problem singular to this particular XCode project. Any new project I create and insert a TabBarViewController has this issue.
Edit 2: Problem disappeared then came back. Posted the problem (which persists on for even a brand new xcode project with tab bar view controller). It is at https://github.com/AlekPiasecki/XcodeProblems
Edit 3: To anybody that has the same issue: This is almost certainly due to hardware. I have the latest version of XCode (the XCode 8 beta) and OS Sierra installed on my computer. The github post continues to have the same issue for me, but it appears fine on computers which do not have these betas installed. As far as fixing the problem now that I am stuck with these Xcode and OS versions... I still have no idea.
Adding an image to the TabBarViewController fixes this issue. The blue box goes into whatever size the image is, so making the image really small (like, say, a pixel) shrinks the blue box so that is invisible (essentially). This works in practice as a solution, but don't know how to truly permanently get rid of it.
This is a Xcode error that will be fixed in 8.2 release.
This is the Apple official note about this problem.
Look in the link for Interface Builder > Resolved Issues > UITabBarController
https://developer.apple.com/library/prerelease/content/releasenotes/DeveloperTools/RN-Xcode/Introduction.html

Storyboards constraints suddenly all misplaced

I am using XCode 6.4. I have quite a big Storyboard, and sometimes, when I open it, lots of warnings appear out of the blue, saying I have misplaced views, without touching anything. Everything was fine before, and the misplaced views are in every single viewcontroller. I add most of the constraints manually.
Any ideas what I might be doing wrong, or why suddenly everything moves?
EDIT
I pull from the repo, open XCode, and then all the warnings appear. If I git status, the storyboard has changed.
The difference between the versions is on the systemVersion attribute on the Storyboard. That change probably happens automatically when someone else with another configuration opens the project and then commits the changes.
This (long) question is related: Xcode changes unmodified storyboard and XIB files. However, my problem is not on the class attribute, but on the systemVersion

All of my objects disappear in my iOS simulator, why is that?

I'm currently working with one navigation controller, and 3 view controllers. when i run my program, everything runs smooth, but none of my objects on my second and third view controller appear in the simulator ( labels, buttons, text fields etc.), how ever the navigation bar is there. why is that? how do i fix it?
For me, the issue was that I had added the button to the LaunchScreen.storyboard, instead of the Main.storyboard.
Credit to this post: http://discourse.djp3.net/t/first-ios-app-button-and-label-disappear-in-simulator/104/13?u=drazisil
Apparently it was an auto layout error. I removed auto layout and disabled size classes from my project and the simulator showed every object within the interface. I then enabled both auto layout and size classes once again & manually added my constraints instead of allowing Xcode to do it for me. Worked out fine once i ran the simulator again. I think this is a bug in Xcode's iOS sim.

How to correct changes to my app made by an xcode freak-out?

I have an xcode project for an app I am in the middle of developing. Recently I saved my xcode project, and then moved a single button using the arrow keys, somehow causing xcode to crash. Several re-opening attempts failed, as I saved just prior to the crash, and xcode would then simply crash upon opening.
After restarting the computer to no avail, I opened the project in xcode 5 developer preview, didn't upgrade the app to xcode 5, and then was able to open it in xcode 4 again. However, for some reason a bunch of IULabel I had created with important text were missing. After closer inspection, I found that I had some UITextFields that were also missing. When I inspected the connection in my header file, I could right click the outlet and select the UITextField. It turns out the X coordinate was set to -345, so it was missing because it was out of my view.
I suspect all of my missing UILabels are similarly out of my view, but since they aren't explicitly connecting to my header, I have no way of selecting them manually, and I can find any way of searching for them or selecting them, since they are out of my view.
Does anyone know how I might be able to select these missing UILabels so that I can change their faulty X coordinates?
Thanks!
All UI elements you have used in your storyboard/xib should be available in the left sidebar of the interface editor.
If the sidebar is not visible you have to click the little round button at the bottom.

Resources