Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Apple Human Interface Guidelines.pdf
Скачиваний:
13
Добавлен:
27.03.2015
Размер:
29.57 Mб
Скачать

C H A P T E R 8

User Input

Text. An application considers all text appearing together in a particular context as a block of text—a one-dimensional string of characters. A block of text can range from a single field, as in a dialog, to an entire document, as in a word processor. Regardless of where it appears, text is edited in the same way.

Arrays of fields. A one-dimensional array of fields is a list and a two-dimensional array is a table. Each field contains information such as text or graphics.

Graphics. For the purposes of this discussion, a graphic, or picture, is a discrete object that can be selected individually.

The following sections discuss the general methods of selecting and the specific methods that apply to text, arrays, and graphics.

Selection Methods

This section describes selection techniques.

Selection by Clicking

The most straightforward method of selecting an object is by clicking it once. Icons, for example, are selected in this way in the Finder.

Figure 8-4 Selection of a single item

Selection by Dragging

The user can select a range of some objects by following this procedure:

1.The user positions the pointer at one corner of the range and presses the mouse button. This position is called the anchor point of the range.

2.Without releasing the mouse button, the user moves the pointer in any direction.

As the pointer moves, visual feedback indicates the objects that would be selected if the mouse button is released. For text and arrays, the selected area is continuously highlighted. For graphics, a dotted rectangle expands or contracts to show the selected area. If appropriate, the view should scroll to allow extending the selection beyond a window.

3.When the desired range is selected, the user releases the mouse button. The point at which the button is released is called the active end of the range.

Selecting

109

2008-06-09 | © 1992, 2001-2003, 2008 Apple Inc. All Rights Reserved.

C H A P T E R 8

User Input

Figure 8-5 Selection of a range

Changing a Selection

A user can extend a selection by holding down the Shift key and clicking the mouse button. This action is called Shift-clicking.

In text, if the user Shift-clicks within an already selected range, the new range is smaller than the old range.

In an array, a Shift-click can extend the selected range or it can move the selection from the current cell to wherever the user Shift-clicks.

There are two models for extending a continuous selection using Shift-click. In the additionmodel, new text is added to a current selection. In the fixed-point model, the user can extend the selection on either side of the insertion point. Figure 8-6 illustrates the results of consecutive steps in both models.

Figure 8-6 Shift-clicking in the addition model and the fixed-point model

Step

Addition model

Fixed-point model

1.User sets insertion point by clicking before the word “attention”.

2.User extends the selection to the right by Shift-clicking after the word “behind”.

3.User extends the selection to the left by Shift-clicking before the word “Pay”.

4.User extends the selection to the right by Shift-clicking at the end of the sentence.

When considering which model to use in your application, keep in mind that the addition model provides more flexibility by allowing users to extend a selection in both directions.

A Shift-click should result in a continuousselection—the selection is extended to include everything between the old anchor point and the new active end. A Command-click should result in a discontinuous selection. With discontinuous selection, in which the user can extend a selection by adding nonadjacent objects to already selected objects, the objects between the current selection and the new object are not included in the selection.

110 Selecting

2008-06-09 | © 1992, 2001-2003, 2008 Apple Inc. All Rights Reserved.

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]