Principle of least astonishment
Appearance
This article is written like a personal reflection, personal essay, or argumentative essay that states a Wikipedia editor's personal feelings or presents an original argument about a topic. (May 2010) |
The Principle of Least Astonishment (POLA/PLA) applies to user interface design, software design, and ergonomics. It is also known as the rule- or law of least astonishment, or -of least surprise.
The POLA states that, when two elements of an interface conflict, or are ambiguous, the behaviour should be that which will least surprise the user; in particular a programmer should try to think of the behavior that will least surprise someone who uses the program rather than that which is natural from knowing its innards.
For example:
- A user interface may have the behaviour that pressing Ctrl+Q causes the program to quit. The same user interface may have a facility for recording macros, a sequence of keystrokes to be played back later, intended to be able to control all aspects of the program. The user may want to record a keystroke sequence that includes Ctrl+Q as part (most likely the last part) of the macro. The principle says that pressing Ctrl+Q while recording a macro should not quit the program (which would surprise the user), but rather should record the keystroke.
This practice also involves the application of sensible defaults.
See also
- DWIM
- Editor war
- Occam's razor
- Law of Demeter (also known as the principle of least knowledge)
External links
- "Applying the Rule of Least Surprise" from The Art of Unix Programming by E.S. Raymond
- Principle of Least Astonishment at Portland Pattern Repository
- Principle of least astonishment on UXPassion.com
- Law of Least Astonishment from The Tao of Programming by Geoffrey James