Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Примеры брендбуков / apple_osx-aqua-human-interface.pdf
Скачиваний:
17
Добавлен:
16.02.2016
Размер:
8.01 Mб
Скачать

C H A P T E R 5

Windows

Opening and Naming Windows

Your application should open a document window when a user does any of the following:

double-clicks a document icon in the Finder

selects the document in the Finder and chooses open from the File menu (or selects the document and presses Command-O in the Finder)

chooses a file from within an Open dialog

chooses the New command from the File menu

clicks the application icon in the Dock when no documents are open

When your application displays a new document window, name it “untitled”; leaving it lowercase makes it more obvious that the window doesn’t have a name and encourages people to save the document. If the user chooses New again before saving the first untitled window, name the second window “untitled 2,” and so on. Add numbers to window titles only when there is more than one open untitled window. Don’t put a “1” on the first untitled window, even after the user opens other new windows.

Figure 5-5 Appropriate titles for a series of unnamed windows

If the user dismisses all untitled windows by saving or closing them, then the next new document should start over as “untitled,” the next should be “untitled 2,” and so on. If a user has chosen to display filename extensions in Finder Preferences, the extension should appear on the title of a new untitled window (“untitled.rtf,” for example).

74Window Appearance and Behavior

Apple Computer, Inc. June 2002

C H A P T E R 5

Windows

Figure 5-6 Examples of correct and incorrect window titles

When the user opens an existing document, make sure its title is the display name, which reflects the user’s preference for showing or hiding its filename extension. For more information, see “Naming Files and Showing Filename Extensions” (page 249). Don’t display pathnames in document titles (see “Displaying Pathnames” (page 251)).

Window Appearance and Behavior

75

Apple Computer, Inc. June 2002

C H A P T E R 5

Windows

Positioning Windows

Whenever your application displays a window, you must decide where to put it and how big to make it.

New document windows should open horizontally centered, as shown in Figure 5-7, and should display as much of the document content as possible. The top of the document window should butt up against the menu bar (or the application’s toolbar, if one is open and positioned below the menu bar). Subsequent windows are moved to the right 20 pixels and down 20 pixels. Make sure that no part of a new window is obscured by the Dock.

Figure 5-7 Position of new document window

76Window Appearance and Behavior

Apple Computer, Inc. June 2002

C H A P T E R 5

Windows

For nondocument windows, the preference is to open new windows horizontally centered as shown in Figure 5-8. Vertical position should be visually centered: the distance from the bottom of the window to the top of the Dock should be approximately twice the distance as that from the bottom of the menu bar to the top of the window. Subsequent windows are moved to the right 20 pixels and down 20 pixels. Make sure that no part of a new window is obscured by the Dock. (See “The Dock’s Onscreen Position” (page 41).)

Figure 5-8 “Visually centered” placement of new nondocument window

Y

X

2Y

Horizontally

X

 

 

centered

Window Appearance and Behavior

77

Apple Computer, Inc. June 2002

 

C H A P T E R 5

Windows

If a user changes a window’s initial size or location, maintain the user’s choices the next time the window opens. If a user opens, moves, and closes a document window without making any other changes, save the new window position but don’t modify the file’s date stamp.

Before reopening a window, make sure that the size and state are reasonable for the user’s current monitor setup, which may not be the same as the last time the document was open. Try to maintain the window’s previous location (the top-left corner of the window) and, if possible, its size. If you can’t replicate both, maintain the location and reduce the window’s size. If that is not possible, try to keep the window on the same monitor, open the window so that as much of the content as necessary is visible, and follow the guidelines for opening a new window, as described previously.

For example, if a user opens a document to full size on a wide aspect-ratio display, then next opens the file on an iMac, open the document in a window sized for the smaller monitor, rather than the saved size. For more information on appropriate window size, see “Resizing and Zooming Windows” (page 80).

On a computer with more than one monitor, display the first new window visually centered in the screen containing the menu bar. If the user doesn’t move that first window, display each additional window below and to the right of its predecessor. If the user moves the window, display each additional window on the screen that contains the largest portion of the frontmost window, as shown in Figure 5-9. For example, if the user creates a window, drags it completely to a second monitor, and then creates a new window, display the new window on the second screen. If there is sufficient room on the screen, display subsequent windows to the lower right of the frontmost window. If there isn’t enough room on the screen, display subsequent windows starting in the original visually centered position, and then continue to display additional windows slightly offset to the lower right.

If the user moves a window so that it is entirely positioned on a second monitor, then opens the window on a single-monitor system, respect the window’s previous size, if possible.

78Window Appearance and Behavior

Apple Computer, Inc. June 2002

Соседние файлы в папке Примеры брендбуков