The XIB file is basically the original document of the NIB file, the XIB can almost always be edited in Xcode (unless they are obsolete or corrupt). while newer NIBs are compressed and not applicable, older NIBs are packages that can be viewed with Xcode, The Bundled NIBs contain some source / archive files that include designable.nib , which is often just a renamed XIB file .
NIB = N xt I nterface B uilder (NXT = NextStep = NS)
XIB = X ml I nterface B uilder
Although the new NIB archive files are not available for most applications, including Xcode, they can still be unlocked. I found this free application called NibUnlocker on a CharlesSoft Web site that can potentially parse compressed Nib and export it as an XIB document. This application is still pretty buggy, but sometimes it is very accurate based on Nib content.
(NibUnlocker is a very inaccurate name, Nibs are not blocked, they are archived)
Click to download NibUnlocker
If you want to know a little more, you can read the additional information presented below regarding the NIB and XIB formats :
Nxt Interface Builder Anatomy:
Archived NIB s
A Compressed NIB file is a complex file to analyze, but it is not possible. The structure of these files is based on a list of compressed properties (starts with "bplist00"), and part of its contents is archived through NSKeyedArchiver. Since the NIB is formatted as a list of properties, this allows you to make a small hack: if you really change the Nib extension to .plist, for example. ArchivedNib.nib to ArchivedNib.plist In fact, you can open it in Xcode by treating it as a List of properties. When you look at Nib as a list of properties, you are likely to get some basic properties like $ version, $ objects, $ archiver and $ top.
Useful notes
A The CFKeyedArchiverUID object is actually a redirector; in {value = xx}, the value is the offset for the element in the $ objects array from the beginning of the array. eg. <CFKeyedArchiverUID 0x60800002bc20 [0x7fffef6b8c30]>{value = 29} , value = 29, the result will be the 29th element in the $ object array. In Objective-C, you can get this value from NSArray using this method:
+ (NSUInteger)valueForKeyedArchiverUID:(id)keyedArchiverUID { void *uid = (__bridge void*)keyedArchiverUID; NSUInteger *valuePtr = uid+16; return *valuePtr;}
(I myself understood this using the Internet, and later used Hopper to parse NibUnlocker , and I noticed in its source code that it uses the same method, loading the NIB in NSDictionary and looking through all its connections, objects, etc. and writes new XIB )
as if it helped; -)