UI items do not show up in interface builder - ios

I have a strange issue here about interface builder.
I added some views, buttons to my view controller and they were displayed well in the interface builder some hours before. But now, they disappeared.
I mean, they are not displayed in the interface builder while showing up perfectly when running. Below images is the view controller in my interface builder.
Here is some other view controller in the same project. Items in it are showing normally.
Could anyone tell me the reason of this ?
EDIT: They disappeared after I installed some libraries using cocoapods. Can it be the reason?

Check the size class,you may add views in one size class and see it in another
Also,selected the hidden view to check if it is installed in this size class

Related

Cant control drag a reference object to the ViewController in Xcode 9.2 (9C40b) iOS project

How to a create an outlet for an iOS control on the storyboard that is connected to my swift ViewController code?
All the tutorials for iOS development show that you can control drag a UI element to your ViewContoller swift code for an outlet. However it never works for me, it shows the blue line from the storyboard, but on the drop it never brings up the dialog to add a new outlet.
Creating a new Action drag and drop works just fine for buttons. I have seen many ask this question and there seems to be no definite answer.
Is there something different with iOS projects?
I tried to set the View Controller custom class to my specific ViewController class, and then I can drag and drop a new outlet. However the project fails to compile.
LaunchScreen.storyboard: error: Illegal Configuration: Launch screens may not set custom classnames
I seem to be missing something here, but all the tutorials I watch/read (none seem to cover Xcode 9 or swift 4) all show this behavior as being the normal way to create an outlet.
Launch screens are not able to have outlets attached to them. They are static. If you'd like to have a "launch screen" that you can manipulate, duplicate your launch screen layout into an initial view controller and do what you like there.
I think this is because you are connecting it from the LaunchScreen.xib instead of the main.storyboard files.

ViewController controls not visible, but present in document guideline

I am newbie in Xamarin iOS development.
I created a storyboard, added few view controllers in it.
I added some controls in one view controller, ran the code and checked the output on simulator. All worked great.
Now after some time I checked my storyboard design. Now the controls are not visible in view controller(in story board), but they are visible in document guideline(view hierarchy).
please let me know what should I do to solve this issue.
Thanks in advance.
The problem was solved by clicking on the Portrait/Landscape icon two times which changed the device width to "Compact" and height to "Regular" an in 5 seconds the controls were visible in the ViewController

Main interface can not be changed to my own storyboard

I'm happy to know that zero code is needed to create interface for iOS app using storyboard somehow, but failed to show my own storyboard by changing 'main interface' of project setting in XCode.
Launching app brought me to a black screen which is expected to be a tableview within a navigation.
Having set Colorboard.storyboard as interface should add a grey arrow line pointing to navigation controller in the storyboard....however there wasn't such line.
Xcode I am using is 6.3...I am wondering if there is something I missed?
As far as I see you didn't set the initial view controller for storyboard.
In Attributes inspector select the param called "Is Initial Controller"
More details in documentation.

UIViewController content not displaying on storybord

All the content of one of my UIViewControllers suddenly stop show in my storyboard, all the objects are grey out in my documents outline and the view controller in question is completely blank, however when I run the code it displays fine in my phone and/or simulator.
I try clean and build the project without any success, any ideas how to fix it?
From your interface builder check the property for specific hidden view as Installed (From Utilities)

UIButton is Filling Screen

I have a problem where the button's I have added to .xib file are filling the screen when I run the application in the iPhone simulator. In Interfacce Builder, the UI appears exactly as I want it. It is added in Interface Builder, and it is correctly linked to the proper view controller. The button is not being manipulated in the code. Code someone point out some settings to check. This is an error that has been there for a few and days, and I can't seem to fix it.
The view hierarchy is (if this helps):
MainWindow
TabController
FirstView
SecondView
ThirdView
In FirstView.xib, in the document outline under objects, there is a root view, which contains the UIButton in question.
One possibility is that the button is added as the view, instead of a subview of the view. It sometimes happens, when you move a button around -- particularly from within the hierarchy list, it accidentally becomes the view (of the viewController) instead of be a subview.
Most probably is that you have not configured correctly the resizing of the button. You can either set it in code or using the interface builder.
For the interface builder solution select the button and open the "Size Inspector". You will see that there is an autosizing feature, adjust to your need and you are done.

Resources