interface-builder

IBAction methods declared in a Protocol are not visible in Interface Builder

Hi, I have defined an objective-c protocol that declares a method that is tagged with IBAction. I implemented a UIViewController that implements the protocol. In Interface Builder I created a nib file with the UIViewController as the file's owner. However the protocol method is not visible under the Received Actions section although it...

How can I view an XIB from an app store app?

I downloaded an app with nice design and unpacked it's contents. I'd like to look at the NIBs to see how the app is put together. I renamed the NIBs to XIB, but Interface Builder won't open them ("Interface Builder was unable to determine the type of PageView.xib"). Is there any way to force it to open the file. Would I be able to see an...

How do I make Interface Builder recognize IBOutlet/IBAction for new languages?

Hi, it's a theoretical question: suppose I come up with an outstanding new scripting language and want to make a Cocoa bridge for that. Is it possible to make Interface Builder recognize the new language and parse the source code automatically so that it can list the IBActions and IBOutlets, just as it already does for Objective-C's .h,...

HTML-like layout in iPhone application

How do I make a resolution-independent iPhone view controller that can stack it's subviews like the browser stacks HTML elements? Here's an example. One UILabel at the top that could contain 1-6 lines of text; two UIButtons in a row right below the label; the left button could have a short or long title. I want the buttons to appear at...

What should I do with default menu items in MainMenu in the new Cocoa application?

When you create new Cocoa application Xcode generates MainMenu.xib for you with the sets of predefined menu items (File, Edit, Format, View, etc.). I make a very simple application. I really don't need menu items Edit, Format, View. What is the best practice in this case. Should I remove or keep them? It's look very strange for me that ...

How do I add an UIView above a TableViewController

Hi I would like to display an UIView above my tableview, for testing purposes I have used a Searchbar (to eliminate any possible problems with my code). My setup: Tab bar controller     MyCustomTableViewController         View             TableView (for customizing cell height)             Searchbar I have positioned the searchbar at...

Interface Builder Lock Item Positions?

When working with UI items in Interface builder is there anyway to lock an items position once you are happy with its placement? I only ask as I keep slightly dragging items when selecting them for edits resulting in having to go back and tweak positions. gary ...

Swing: Dynamically Displaying a Panel

I'm currently making a java swing GUI with the Netbeans GUI builder. I have a bunch of panels that are being replaced on my main JFrame as the user navigates the GUI and a controller class is taking care of this. At one step, however, there is a panel (FilterDefinitionPanel) that contains a combo box as well as a blank inner panel (Query...

How do you set autosizing to flex in Interface Builder?

I have an iPhone project that I started as a Windows-based app and another View-based app. The Window app has a view which I added and I want to make the view fit within the window. In the View app the view is set to stretch. Here is what it looks like when it is off. And here is when it is on. I want to click in the middle of th...

CoverFlow like Slideshow

Hello! I stuck again at a Problem. I want to make a little Slideshow (functionality like CoverFlow -> Thumbnails can scroll horizontally). I have 10 Pictures that should be as Thumbnails in this show. when i "press" a pic, this pic should go fullscreen. Can anyone give me a little help or even a tutorial to do such a thing? Thank You ...

Autosizing boxes and positioning in Cocoa

Hi, I'm creating an application, from which a part looks like this: I all dragged them to a window in IB, but the problem is that the NSImageView, Action Buttons (Suggest, Send, Poke etc...), Information NSBox, and Friends NSTabView can all vary in height. They should always be placed below each other, with a margin of 8px. Just like...

UIView, UIScrollView and UITextFields problem calling Method

I have a view with several embedded UITextFields, this UIView is subordinated to a UIScrollView in IB. Each text field is supposed to invoke a method called updateText defined in the viewcontroller implementation file when the user is done editing the field. For some reason, the method updateText never gets invoked. Anyone have any id...

IPhone Interface Builder: Z-Index, Z-order of a button, image, ui element, etc?

Hi, I'm dragging things around in the Interface Builder... I'd like to specify whether an image is in front (like an indicator) or behind of a button (like a background). I don't see any z-index property as I'm used to seeing on other environments. If there isn't a z-index property what is the best way to go about what I'm trying to a...

iPhone Application Starting Point?

I have a question regarding setting up a simple single view application. From what I can see there are two methods... METHOD_001 Start Xcode and create a "Window Based Application" Start setting up your interface in the MainWindow.xib METHOD_002 Start Xcode and create a "Window Based Application" In Xcode add a UIViewController su...

Create a UIButton with (or without) memory

I'm trying to add a UIButton with code (not Interface Builder). Some examples say you MUST alloc and release memory for the button. Others use buttonWithType and magically create a button without alloc'ing any memory at all. How is that possible? (Both seem to work fine.) Which of the 2 methods do I want to use... and when? Are th...

Blank simulator screen due to file name or name change or neither?

hi; i have a problem, clearly. when i started the project i had stupidly named my [AppName]ViewController just [AppName]Controller. As i went along i could never get iphone simulator to display more than a blank white screen. upon having made all the connections in interface builder and still facing the same problem, i decided my blank ...

Decide in code which class and xib file to load on app launch

Hello, I'm changing my app to add an in app purchase. When I initially set up the app I used interface builder but now i need to decide which class & xib file to load on app launch based on whether or not a user has purchased a feature. My app is set up with a tab bar controller that has a naviagion controller for each tab. Inside ...

How do you get multiple touch buttons to work with touchesBegan/Moved ?

Hi, I have a bunch of buttons that I want to activate in three different ways. Touch Down Touch Down - multiple touch (at the same time) Touch Drag Inside (The same as dragging your finger over a piano) The first two is obviously easy in IB. However many people, including myself, have had trouble with Touch Drag inside. So I ended u...

Interface Builder accessing super class attribute

Hi, I have a class A, and B like these: @interface A : UIViewController <UITableViewDelegate, UITableViewDataSource>{ UITableView tv; } @end @interface B : A { } @end My question is: "In the interface builder, how can I link the table view tv to the nib of class B?" Thanks. ...

How can I programmatically access UI elements in a NIB without 'wiring' them?

Hi - I'm contemplating writing some helper functions to make it easier to do simple changes to the UI elements in my iPhone NIB. Mainly - I want to access a UILabel, or other element, via it's Name in Interface Builder. Is this possible? Is there a smarter approach? Example Say I want to make a super simple iPhone app that displays ...