< Previous PageNext Page > Hide TOC

Dock Tile Concepts

The Dock was designed to make the Macintosh easier to use:

A Dock tile is the area that contains the Dock icon and provides users access to the Dock item’s name and contextual menu. When a user rolls the cursor over a Dock tile, the item’s name appears. When the user presses and holds the mouse button while the cursor is on a Dock tile, a contextual menu appears. The following sections describe in more detail the Dock icon and contextual menu.

In this section:

Dock Icon
Dock Menu


Dock Icon

An application's Dock Icon is, by default, its application icon. It is possible for you to modify or replace the default icon with another image that indicates the current state of your application. Figure 1-1 shows an example of an application, Mail, that does just that. The icon for Mail changes when messages are waiting to be read. A badge—the red circle and number in the figure—is overlaid onto Mail’s application icon to indicate the number of unread messages. The number changes each time Mail retrieves more messages.


Figure 1-1  The red badge in the Mail’s Dock tile indicates the number of waiting messages

The red badge in the Mail’s Dock tile indicates the number of waiting messages

A window that is minimized into the Dock also has a Dock tile icon. By default, this is a miniaturized version of the window’s content that is badged with the application's Dock Icon.


Figure 1-2  A Mail window minimized into the Dock.

A Mail window miniaturized into the Dock.

Dock Menu

When the user presses and holds the mouse button while the cursor is over a Dock tile, a contextual menu appears. If your application does nothing to customize the contextual menu, the application Dock tile’s contextual menu contains a list of the application’s open documents (if any), followed by the standard menu items Keep in Dock, Open at Login, Show in Finder, Hide, and Quit.

Note: When your application is not running, a minimal menu will be displayed.

Figure 1-3 shows the application Dock contextual menu for Xcode. Xcode provides a number of custom menu items.


Figure 1-3  XCode’s application Dock contextual menu

Project Builder’s application Dock menu

Custom items that an application adds to its Dock menu appear between the list of open documents and the standard items, as shown in Figure 1-4. The sample application has one window, named Window, open. The menu items Play, Pause, Stop, Next Song, Previous Song, and the Submenu (with its items) are custom items added by the application.


Figure 1-4  Custom items in an application’s Dock menu

Custom items in an application’s Dock menu

Figure 1-4 illustrates that you can further customize menu items—add an icon to an item. A window icon appears next to the window name, the application’s icon appears to the left of the item Play, and a custom icon appears next to Pause. It’s best to use icons that convey meaning to the user. For example, it would be preferable for the sample application to use a standard icon that indicates play for the Play item and pause for the Pause item. See Apple Human Interface Guidelines for additional information on designing and using a menu for the Dock.



< Previous PageNext Page > Hide TOC


© 2009 Apple Inc. All Rights Reserved. (Last updated: 2009-03-04)


Did this document help you?
Yes: Tell us what works for you.
It’s good, but: Report typos, inaccuracies, and so forth.
It wasn’t helpful: Tell us what would have helped.