You’re previewing Ry’s Cocoa TutorialUI Components

Tab Views

Like Split Views, Tab Views are containers for other UI components. However, instead of dividing a layout into rows and columns, Tab Views are used to paginate an interface. They let you break up your application’s content into separate sections and enable the user to choose which one they want to display.

A Tab View with three pages

Tab Views have all sorts of use cases, from grouping related functionality, to presenting multi-step forms, and even as a sort of “conditional view” that displays different content based on some other state in the application. You can find many real-world examples in the System Preferences app. For instance, energy settings for the battery/power adapter are presented in a Tab View:

Controlling energy saver settings via a Tab View

This chapter teaches you how to configure tabs, define the appearance of each page, and manipulate an NSTabView object programmatically.

Sorry, this is the end of the preview. To read the rest of this chapter, you’ll need to purchase Ry’s Cocoa Tutorial.

Mailing List

Sign up for my low-volume mailing list to find out when new content is released. Next up is a comprehensive Swift tutorial planned for late January.

You’ll only receive emails when new tutorials are released, and your contact information will never be shared with third parties. Click here to unsubscribe.