Christian Correa
Christian Correa

Reputation: 265

Is there a standard, documented, development pattern to create UI layouts similar to iTunes, iCal, iPhoto, etc?

I am new to Cocoa development and I am trying to create UI layouts using what I consider to be the "standard" layout that is shared by apps like iTunes, iCal, iPhoto, Billings, 1Password, Numbers, Delicious Library, etcetera. This typical layout can be described as follows:

Is there a documented pattern that will show best practices on how to "wire" the View and Controller classes for these types of layouts? For instances, how many ViewControllers to use, whether or not using an NSDocument-based approach makes sense, some common pitfalls, etcetera? This layout is so prevalent, that I am surprised that there doesn't seem to be any good reference on it.

Update: I forgot to mention that I have access to the Apple Developer site, and while I can find the library reference for the different classes in Cocoa, I cannot seem to find a good reference for how to bring it all together in the layout I describe.

Books like Aaron Hillegass' and others out there are great to learn the basics on Cocoa and creating simple interfaces (a few controls laid out on an view connected to an NSDocument), but not so great at guiding you to the UI layout I describe.

Thanks.

Upvotes: 1

Views: 450

Answers (2)

Rob Keniger
Rob Keniger

Reputation: 46020

The hierarchical view on the left is called a Source View and you would normally create this with the NSOutlineView class.

Have a look at Apple's SourceView sample code. It implements a source view very similar to the one in the Finder and elsewhere and should give you a big head start.

Upvotes: 3

sosborn
sosborn

Reputation: 14694

The range of applications you mentioned is so wide that it is impossible to give a direct answer.

In general, the item you call a Library is usually an NSOutlineView (for hierarchies) or an NSTableView.

The main panel really depends on the actions contained within, same for the utility panel.

My suggestion is to read Apple's Human Interface Guidelines for OS X. This will give you the best overview of how to do things. Other than that, the actual implementations are too dependent on the individual program.

Upvotes: 1

Related Questions