Some Examples

Suppose you are developing an MDI program. Whenever you run the program, you always maximize the main window first. Then you usually load the last document that was accessed. And then you maximize the document window to fill all the available space within the MDI frame. Now suppose that not just you but all of your users typically follow a similar sequence of actions when they start your program. Why? Should it be necessary to perform these steps every time?

Now suppose that your program performs these three steps by default or, better yet, if these steps were performed the last time the user ran the program. Now the program is launched maximized and the last document accessed is automatically loaded into a maximized window. You've done the user a big favor. But what is the downside? The downside is that the user might occasionally use the program in a slightly different way from what you expect. In this example, probably the worst case is that the user will have to close a window he really didn't want to use. Assuming the document loading process is fast, this is not a significant drawback.

TIP
A program should restore itself to the state it was in when last quit.

Let's look at a variety of techniques used by Microsoft Windows programs to eliminate unnecessary repetitive tasks.

General Windows

  • Automatically saving and restoring user preferences.
  • Automatically saving and restoring window sizes and locations.
  • Automatically saving and restoring the last document used or all previously opened documents, and possibly restoring the previous scroll positions.
  • Maintaining a list of the most recently used documents.
  • Automatically selecting appropriate defaults in dialog boxes to reduce the effort required to use them.
  • Automatically displaying the last page used in a property sheet.
  • Providing property sheets with an Apply button. The Apply button eliminates the user having to display a properties dialog box, making a change, clicking the OK button, checking the results, and repeating the process until satisfied.
  • Making lists and combo box drop-downs that are long enough to eliminate unnecessary scrolling. If a list or combo box has only a few items that can easily be viewed all at once, the control should be long enough to not need the scroll bar.
  • Automatically expanding an unexpanded node in a tree control when you drag and hold an object over the node for more than two seconds.
  • Quickly finding files by providing shortcuts to the My Documents folder.
  • Providing file browse buttons so that the user doesn't have to type in the name and path of existing files.

Microsoft Word

  • Automatically checking for spelling and grammatical errors as you type, eliminating the need to perform these checks manually. Microsoft Word makes the bold assumption that users want to write documents without errors.
  • Automatically placing the most recently selected fonts at the top of the Font combo box, eliminating the need to perform a lot of scrolling to find a font.
  • Providing the Format Painter feature to copy the format of text or an object and directly apply it to other text or another object. Totally cool!
  • Providing the AutoCorrect feature to automatically fix many common spelling errors, such as replacing hte with the. AutoCorrect even detects accidental usage of the Caps Lock key. For example, if Caps Lock is on, Word replaces tHE with The and turns off Caps Lock. I really like this feature because my usage of Caps Lock, as well as Num Lock and Scroll Lock, is always accidental.
  • Providing the AutoFormat feature to automatically capitalize the first word in a sentence, automatically create numbered and bulleted lists when you start a list with a number or an asterisk, automatically create borders when you type three or more consecutive hyphens in a row and press Enter, automatically format ordinal numbers and fractions (for example, 1st becomes 1st and 1/4 becomes ¼), automatically turn networks and Internet paths into hyperlinks, and automatically convert "+----+----+" patterns into tables with a column for each pair of plus signs.
  • Providing the AutoComplete feature to automatically suggest the rest of the word or phrase that you are typing. To accept the suggestion, you press Enter and Microsoft Word makes the substitution.
  • Providing templates and document wizards to save time in creating many common types of documents.
  • Using the first line of a document as the default filename when the document is first saved.
  • An example of where Microsoft Word fails to eliminate an unnecessary task: Every time I create a new document, I select the default font to be 10 pt. Arial, not 10 pt. Times New Roman. I do this every time—I have to since Word isn't smart enough to give it to me by default. Yes, I know, I can change the default font by changing the default document template, but Word ought to be smart enough to at least ask me if that is what I want to do and then do it automatically.

Two important details contribute to the successful implementation of the automatic features supported by Microsoft Word. First, you can turn the features off or fully customize them. While the features help most users in most situations, of course there are situations in which they get in the way. Second, these features monitor the user and perform a correction only once. To use my earlier example again, if I type hte, Word automatically replaces it with the. But if I then replace the with hte, Word leaves it alone. Alternatively, I can have Word bail out of any automatic change with the Undo command. Word's automatic features are intended to help the user, but ultimately the user, not the program, is in control. (This is where the designers of HAL 9000 really blew it!)

TIP
Allow the user to fully customize automatic features and include the ability to turn them off.

TIP
Use automatic features to help the user, but leave the user in control.

Microsoft Visual C++

Microsoft Outlook

Windows Explorer

Microsoft Internet Explorer

The Find Utility

Hardware

These features have a tremendous range—some are very simple, some are very complex, but they all have one thing in common. They are all totally cool because they help users get their work done without fooling around. Features like these are among my favorites.

These features all show different ways that a program can eliminate unnecessary repetitive tasks. By performing tasks automatically, they all run a slight risk in performing a task in a way that the user doesn't want, but this risk is small and the advantages greatly outweigh the disadvantages. They also demonstrate another important principle: good programs go out of their way to help users get their work done.

TIP
The best programs go out of their way to help users get their work done.



Developing User Interfaces for Microsoft Windows
Developing User Interfaces for Microsoft Windows
ISBN: 0735605866
EAN: 2147483647
Year: 2005
Pages: 334
Authors: Everett N McKay
BUY ON AMAZON

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net