interface-builder

UINavigationBar vs UIToolbar vs UITabBar in iPhone

Let me know which one should be used in what case. What are differences among them? What are the advantage and disadvantage of each component? Thanks ...

Reducing differences in xibs

I've been noticing superfluous changes in my xib files with Interface Builder 3.2.1. Here are a few of them: - <reference key="NSNextResponder"/> + <nil key="NSNextResponder"/> - <reference key="NSSuperview"/> - <array class="NSMutableArray" key="IBDocument.EditedObjectIDs"> - <integer value="6"/> - </array...

"Unknown class <MyClass> in Interface Builder file" error at runtime

Even though Interface Builder is aware of a MyClass, I get an error when starting the application. This happens when MyClass is part of a library, and does not happen if I compile the class directly in the application target. ...

NSViewController and multiple subviews from a Nib

I'm having a difficult time wrapping my head around loading views with Interface Builder and NSViewController. My goal is to have a view which meets the following description: Top bar at the top (like a toolbar but not exactly) which spans the entire width of the view, and a second "content view" below. This composite view is owned by m...

Weak linking with Interface Builder

Application uses 3.x SDK feature, but needs to run in 2.x devices. The solution seems to be using "weak linking", which I did, but app still fails to * compile * for iPhone 2.2.1: "Framework not found MapKit". Compile for target "Device 3.0 - Debug" is ok, even installs on my iPod Touch running 2.2.1! Runs ok as long as I don't activate...

setOrientation problem

I have a really strange orientation issue. I have a sequence of view controllers under a navigation controller. One of them can take any orientation. When I'm leaving the orientation I have to use setOrientation. The funny thing is the rotation takes place as the transition occurs to the next page. This isn't normally a problem exce...

Setting the image of a UIImageView in Interface Builder

When ever I set an image for a UIImageView in IB and simulate the interface the buttons and stuff show up but the image view doesn't. ...

Can't connect IBOutlet in Interface Builder

I'm having a weird experience. I create any type of iPhone application, add a UIViewController with Xib file. I can edit the xib file with controls and see them rendered if I run. Now i'm trying to add a few IBOutlets to the controller, so I add them to the .h file, synthesize on the .m file. Then i head over to Interface Builder to conn...

Nesting Custom Classes/XIB's with Interface Builder

I'll try to make this as short as I can. I wrote a custom class that extends UIView with a couple of IBOutlet properties, and it has a XIB associated with it where those IBOutlets are linked to. I then want to take that class, embed it in some other XIB (for example, a table cell), and just have it work. It seems that when I embed tha...

NSTextFieldCell vertical alignment, solutions seem to squash the horizontal alignment.

I have a NSTextFieldCell that I wish to display with middle vertical alignment. Thanks to an older question here and a blog entry I have two working solutions. However, both solutions seem to squash my ability to set the cell as right aligned. Can anyone help me make either of these solutions support both forms of alignment? Here i...

How to find the NIBs in a project that use a specific class?

Suppose I have a view derived class named MyView. In the same Xcode project MyView is defined, I have many NIBs. Some of the NIBs have a Custom View with the class set to MyView. Now suppose I want to change the name MyView to something else or rename an outlet. I need to find all NIBs using MyView so I can update them. My question is:...

How to create a NSMatrix of NSImageCell in Interface Builder in 10.6

How can I create a matrix (NSMatrix object) of NSImageCell cells (usually located in an NSImageView) in Interface Builder 3.2.1 (i.e. the one made for Snow Leopard?) In the "old days", you would drag an NSImageView, and then option-drag the corner of the control. It seemed to have stopped working in 3.2.1... Is there another way? Am I d...

Cocoa Key Value Bindings: What are the explanations of the various options for Controller Key?

When I bind a control to an NSArrayController using Interface Builder, there are a variety of options under the "Controller Key" field in the bindings inspector. I understand what "arrangedObjects" is, and I semi-understand what "selection" is, but I'd love to see a really nice explanation of all the options and when to use each one. Th...

Interface Builder doesnt show some of my resource images

I have almost 20 images in PNG format added to my current project on Xcode (under the proper group, Resources). Unfortunately, library window's Media tab doesnt show some of them. And if I create an UIImageView and set one of these invisible images from code, nothing shows up. I also tried from IB with adding a UIImageView and set its so...

Apple Interface Builder warning "This windows content rectangle dows not lie entirely on the screen with the menu bar and may not be completely visible for all screen resolutions and configurations."

A warning comes up in a MainMenu.XIB dialogue box. It says Object: window(window) ID: 371 Type: Illegal Configuration Issue: This windows content rectangle dows not lie entirely on the screen with the menu bar and may not be completely visible for all screen resolutions and configurations. I saw something related to this issue on sta...

Interface Builder won't connect button, but the tutorial says it should work...

I've been trying to learn Core Data, and browsing through questions on Stack Overflow lead me to a recommendation that I try the tutorial on Core Data over at Cocoa Dev Central (Link). Everything is making sense so far in the tutorial, but when I got to step 16, it wouldn't let me connect the + button to the Posts array controller. I'v...

Notifying cocoa bindings system when code changes a property by instead of the interface

I'm writing a countdown timer and instead of calling -[NSTextField setDoubleValue:secondsRemaining] on each tick, I'd like to bind the secondsRemaining property to an interface element via an object controller. The problem with this is that secondsRemaining is modified by code on each tick, not by the interface, so the change is doesn't...

How can I use iphone playback control images as buttons in my own app?

OK, you know the playback controls in the iPod app. They are simple Play/Pause, FFW, REW image buttons, but when touched upon, they show a glow effect. I want to use them in my own app, so it will have the same look and feel: w/ the same glow effect. Surely I could recreate all of them in PS with the glow effect image added to UIControlS...

iPhone UITextView scrollable but not editable

How can I get a textview to be able to scroll without the keyboard poping up for edit when clicked on? I am pretty new to iPhone programming and I've tried several different combinations in Interface Builder, but can't seem to get any to work. Also I am having trouble when I have two textviews on the screen where only one of them will sc...

BaseTen Framework newbie question

Hi folks, I am a newbie in Cocoa and, while waiting for my copy of Aaron Hillegas book, I thought I'd give BaseTen framework a try. I am currently following the tutorial provided online but have struck a problem. In the tutorial I'm supposed to be able to enter the URI/connection string as an attribute of the BXDatabaseContext object. ...