Questions tagged [nib]

NIB files are similar to XIB files (XCode Interface Builder), with the difference being XIB files are modified during development and NIB files are created during the build process. NIBs store static information about the interface as well as any behavior that has been implemented.

Storyboards have since succeeded NIB/XIB files as the latest UI interface tool.

1152 questions
82
votes
6 answers

Creating a reusable UIView with xib (and loading from storyboard)

OK, there are dozens of posts on StackOverflow about this, but none are particularly clear on the solution. I'd like to create a custom UIView with an accompanying xib file. The requirements are: No separate UIViewController – a completely…
Ken Chatfield
  • 3,277
  • 3
  • 22
  • 27
60
votes
5 answers

Uncaught exception: This class is not key value coding-compliant

I'm following a tutorial titled "Swift Tutorial for iOS : NSFileManager Persisting Data", and I've encountered an error around or after the 29 minute mark. When I try running it on the iOS simulator, I receive the error: Terminating app due to…
marked-down
  • 9,958
  • 22
  • 87
  • 150
59
votes
2 answers

Prototype Cells in a nib instead of a storyboard

For better re-usability I want to create a table view outside of my Storyboard. Now when I create a UITableView based ViewController with Nib in Xcode I get the default TableView in the nib file. However, I am not able in Interface Builder to add…
Besi
  • 22,579
  • 24
  • 131
  • 223
59
votes
20 answers

NSInternalInconsistencyException', reason: 'Could not load NIB in bundle: 'NSBundle

In my AppDelegate there is a problem I do not understand. RootViewController initially called ViewController and I changed it name. The application is formed by many ViewController then I have introduced a UINavigationController. Why this error…
Ortensia C.
  • 4,666
  • 11
  • 43
  • 70
49
votes
21 answers

Could not load the "" image referenced from a nib

I have no images called "" (nothing). I've gone through the .xib file of the screen where this pops up and can't find anything that would cause this. Anybody who have had the same issue? Here is the full warning: Could not load the "" image…
BlueVoodoo
  • 3,626
  • 5
  • 29
  • 37
48
votes
3 answers

Set size of view in NIB / XIB file

In Xcode 4, there was a never-quite-fixed bug where Xcode prevented you from resizing views (some silly "Design feature") - you had to make sure you set all the topbar/statusbar/navbar/tabbar to "none" before it would unlock the controls. XCode 5…
Adam
  • 32,900
  • 16
  • 126
  • 153
48
votes
4 answers

What is the File's Owner (in Interface builder)?

I am new to Cocoa and I don't understand the concept of File's Owner of a .nib file. Here is the way I would see things : Consider a file myNibFile.nib file that describes how a window looks. Now, I want to connect an actual window to this .nib…
Colas
  • 3,473
  • 4
  • 29
  • 68
45
votes
8 answers

Xcode 4.5 corrupting XIBs?

i am using the new xcode 4.5, i have this lines of code on some view controller: DiscoverCell* cell=[table dequeueReusableCellWithIdentifier:@"DiscoverCell"]; if(cell==nil){ NSArray *nib = [[NSBundle mainBundle] loadNibNamed:@"DiscoverCell" …
Dima
  • 8,586
  • 4
  • 28
  • 57
42
votes
4 answers

What's up with the .NIB -> .XIB?

What's up with the NIB->XIB change somewhere between XCode 3.0 to 3.1? Is there any difference with this name change that I should know while I go through tutorials that mention nothing but the .nib file?
Devoted
  • 177,705
  • 43
  • 90
  • 110
38
votes
2 answers

How to disable Interface Builder document versioning from auto updating?

This question is still getting a lot of upvotes. So look at Update3. once you have upvoted, commented, answered, please please please file a radar Viewing a nib / xib, modifies the file, forcing me to either commit the change or undo the change.…
Nitin Alabur
  • 5,812
  • 1
  • 34
  • 52
36
votes
6 answers

IBOutlet properties nil after custom view loaded from xib

Something strange going on with IBOutlets. In code I've try to access to this properties, but they are nil. Code: class CustomKeyboard: UIView { @IBOutlet var aButt: UIButton! @IBOutlet var oButt: UIButton! class func keyboard() ->…
Gralex
  • 4,285
  • 7
  • 26
  • 47
36
votes
2 answers

wrong frame size in viewDidLoad

Possible Duplicate: Why am I having to manually set my view’s frame in viewDidLoad? I have universal app for iphone and ipad, two storyboards, if I run my app on the iphone simulator in viewDidLoad every frame of each element in nib is correct.…
Oleg
  • 1,027
  • 1
  • 8
  • 18
35
votes
7 answers

Cannot zoom in and out of nib in the new Interface Builder

Have I missed something obvious or is it not possible to zoom freely in and out of an open nib file, within the integrated Interface Builder of Xcode 4?
Luke
  • 11,426
  • 43
  • 60
  • 69
35
votes
5 answers

Easiest way to support multiple orientations? How do I load a custom NIB when the application is in Landscape?

I have an application in which I would like to support multiple orientations. I have two .xib files that I want to use, myViewController.xib and myViewControllerLandscape.xib. myViewController.xib exists in project/Resources and…
Peter Hajas
  • 4,011
  • 4
  • 25
  • 28
34
votes
2 answers

Loading custom UIView from nib, all subviews contained in nib are nil?

I have a custom UIView object with a nib that defines the view/subview layout. My outlets are connected, and when I init the object from initWithFrame: everything is in order. The problem I'm having is when I'm using IB to embed the UIView into…
strahlr
  • 343
  • 1
  • 3
  • 7
1
2 3
76 77