xib

How to set UITableView to Grouped?

In an iPhone navigation based app, I want to add a second tableview but have its design available in IB. I've added a new empty XIB and dragged a UITableView onto it. I want to setup the layout through IB. I've created a controller for this tableview and set the File's Owner class in IB to this controller. I linked the tableview to F...

Can you reference Xib files from static libraries on the iPhone?

In my app, i currently have all my code separated into a static library, to make it easier to set up the xcode project targets for the actual app and for unit tests for my code. The problem with this is that i want to put most of my xib files in the static library as well, but it seems that when i run my app and try to reference the xib...

Multiple Views within one XIB - iPhone SDK

I have been spending time learning how to use the iPhone SDK. I've read "Beginning iPhone Development: Exploring the iPhone SDK" from cover to cover and I've never seen an example of multiple views within one XIB. To illustrate what I mean, here is a screen shot of a XIB with the simple configuration of what I'm referring to: I figu...

Which "Top-Level Objects" is Apple talking about in the Memory Management Programming Guide?

In the Memory Management Programming Guide for Cocoa Apple talks about Top-Level Objects. They say, that I need an Outlet for each of them. If there are any top-level objects you do not store in outlets, however, you must retain either the array returned by the loadNibNamed:owner:options: method or the objects inside the arra...

Packaging a Bundle with a static library

I have a static library that includes some xibs. These will basically be the same across projects. I'd like to include the xibs as part of the library. I can include their veiwcontrollers, reference these controllers in the calling project but then there isn't a xib to load. When I right click the xib in the library project, it can't...

Does anyone know a good tutorial for Tab bars?

Does anyone know a good tutorial for Tab bars? My app is currently a "view-based" app. I need a tutorial on how to make it so that my main nib loads the view from other nibs, and when I click different tabs, it loads other nibs. Thanks ...

How to separate view from controller without using interface builder

I want to create UI elements programmatically without using xib files. All of the examples I have found (UICatalog, ...) are creating UI elements directly in the controller methods. What is the best practice to keep up with MVC patternn and separate views from controllers? Thanks ...

Exception When Setting the Nib Name field in Interface Builder

Hey Guys, I'm trying to load a view controller from a nib in Interface Builder. My basic setup is this: MainWindow.xib contains: All the usual stuff, the app delegate instance, the Window etc. A UINavigationController which has a UIViewController as it's Root View Controller. The nib name of the UIViewController is set to the name of ...

Loading UINavigationController from another nib automatically by UITabBarController

I think I've found the cause: Document Info window in IB has a warning: "'Selected Navigation Controller (Second)' has nib name property set to 'SecondView.nib', but this view controller is not intended to have its view set in this manner." Bummer. I've built nib in Interface Builder that has UITabBarController at top level and switc...

How are the 2 View Controllers wired to the tabBarController in iPhoneRecipes

I am learning iPhone programming by reviewing the iPhone Recipes sample application. I am puzzled with how the two view controllers are wired to the tab bar. If they are wired in the XIB, can anyone explain how it is done or where I can get more visually aided details on connecting things in the XIBs. This is my starting point in the l...

Not sure why UIView is being nudged up by around 10px

Hi, I've created a simple iPhone app which has two .xib files. In the app delegate at application did finish launching I display the first .xib file by calling: [window addSubview:myView]; and I do the same on an IBAction for a UIButton to change the view to myView2. What I'm finding is that there's a white bar of around 10 pixels wh...

Why doesn't initWithNibName work for my UIViewController subclass?

I have subclassed UIViewController into a new class, PageViewController (I'm writing a simple book app). I want to add a new view loaded from a nib file and am using the following code. It works. PageViewController *viewController1 = [[UIViewController alloc] initWithNibName:@"Page1" bundle:nil]; [viewController1.view setUserInteraction...

Performance penalty for using NIB files?

I am curious to know if anyone has any experience comparing the load time performance of iPhone apps with views laid out in NIBs vs. views laid out entirely programmatically (i.e. instantiating UITextView, adding it to the view, instantiating UIButton, adding it to the view…). If I want a simple app to load lightning fast, would it be b...

Guidelines for creating non-view objects in a XIB file

Interface Builder provides the ability to create non-view/controller objects in a XIB file. In the past I have used this feature to instantiate and wire-up small components that manage view components in the XIB and this seemed a fairly reasonable thing to do. However, I was wondering what other legitimate uses there are for this featur...

iPhone view not displaying

Hi, I am having difficulty geting a very simple view to display. This view has a custom view controller that is manages by a switching view controller. The XIB has one UIViewController component on it with its Image property set. The view controller is as follows: InstructionsViewController.h #import <UIKit/UIKit.h> @interface Instru...

iPhone- Multiple pages

I have a view based app going here with 3 different pages, I can't for the life of me get all the pages linked together correctly or completely. Its just a home page with 2 buttons linking to the first and send page.... then back to the home page. I have a mock up of what I am working with if someone could look at it and tell me what...

Why does Xcode warn me about title shadow offsets in xib files even though I'm targeting iPhone OS 3.0?

When I build my iPhone project, I get warnings from xcode about a few of my xibs saying: Specifying a title shadow offset in Interface Builder is not supported by the iPhone SDK for iPhone OS versions prior to 3.0. Thing is, I'm building for 3.0, and the base SDK is set to 3.0. I've done some poking around and can't find anyt...

setup coredata, before appdelegate loads my mainWindow.xib

Hi, I have setup coredata in my appDelegate, but it first loads the mainWindow.xib and the corresponding controllers+views in that xib file. Those controllers need to have a managedObjectContext to load properly. And after the xib is unarchived it runs the code in my appDelegate. How can i setup my coredata and then load the mainWIndow...

Do I lose perfomance by using .xib files to provide an iPhone app's GUI?

I was wondering if there is a difference between using .xib files for GUI design and doing this programmatically. As it is a compiler I would assume that there is no relevant time lost. Am I wrong? ...

Is it advisable to use the same xib in a UINavigationController view and a modal view?

I have a view (and corresponding view controller) in my iPhone app that allows the user to edit settings for the application. This view is accessible via a menu (a table view). I use pushViewController in my UIViewController subclass to get it shown. When I do this, it appears as I expect - the nav bar appears on top of the xib, and the ...