美文网首页
the Principle of Least Astonishm

the Principle of Least Astonishm

作者: one_zheng | 来源:发表于2018-07-24 10:18 被阅读12次

    Principle of least astonishment

    From Wikipedia, the free encyclopedia

    Jump to navigationJump to search

    The principle of least astonishment (POLA) (alternatively "principle/law/rule of least astonishment/surprise")[1][2] applies to user interface and software design.[3] A typical formulation of the principle, from 1984, is: "If a necessary feature has a high astonishment factor, it may be necessary to redesign the feature."[4]

    In general engineering design contexts, the principle means that a component of a system should behave in a way that users expect it to behave; that is, users should not be astonished by its behavior.[citation needed]

    Contents

    [hide]

    Formulation[edit]

    A textbook formulation is: "People are part of the system. The design should match the user's experience, expectations, and mental models."[5]

    The choice of "least surprising" behavior can depend on the expected audience (for example, end users, programmers, or system administrators).[1]

    In more practical terms, the principle aims to leverage the pre-existing knowledge of users to minimize the learning curve, for instance by designing interfaces that borrow heavily from "functionally similar or analogous programs with which your users are likely to be familiar".[1] User expectations in this respect may be closely related to a particular computing platform or tradition. For example, Unix command line programs are expected to follow certain conventions with respect to switches,[1]and widgets of Microsoft Windows programs are expected to follow certain conventions with respect to keyboard shortcuts.[6]In more abstract settings like an API, the expectation that function or method names intuitively match their behavior is another example.[7] This practice also involves the application of sensible defaults.[4]

    When two elements of an interface conflict, or are ambiguous, the behavior 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 behavior that is natural from knowing the inner workings of the program.[4]

    Examples[edit]

    A web site could declare an input that should autofocus when the page is loaded,[8] such as a search field (e.g., Google.com), or the username field of a login form. Sites offering keyboard shortcuts often allow pressing <kbd class="keyboard-key nowrap" style="font-family: inherit; white-space: nowrap; border: 1px solid rgb(170, 170, 170); border-radius: 0.2em; box-shadow: rgba(0, 0, 0, 0.1) 0.1em 0.1em 0.2em; background-color: rgb(249, 249, 249); background-image: linear-gradient(rgb(238, 238, 238), rgb(249, 249, 249), rgb(238, 238, 238)); padding: 0.1em 0.3em; font-size: 0.85em;">?</kbd> to see the available shortcuts. Examples include Gmail[9] and Jira.[10]

    The <kbd class="keyboard-key nowrap" style="font-family: inherit; white-space: nowrap; border: 1px solid rgb(170, 170, 170); border-radius: 0.2em; box-shadow: rgba(0, 0, 0, 0.1) 0.1em 0.1em 0.2em; background-color: rgb(249, 249, 249); background-image: linear-gradient(rgb(238, 238, 238), rgb(249, 249, 249), rgb(238, 238, 238)); padding: 0.1em 0.3em; font-size: 0.85em;">F1</kbd> Function key in Windows operating systems is almost always for opening a help program associated with an application, and similarly for some of the Linux desktop environments. The corresponding key combination in Mac OS X is <kbd class="keyboard-key nowrap" style="font-family: inherit; white-space: nowrap; border: 1px solid rgb(170, 170, 170); border-radius: 0.2em; box-shadow: rgba(0, 0, 0, 0.1) 0.1em 0.1em 0.2em; background-color: rgb(249, 249, 249); background-image: linear-gradient(rgb(238, 238, 238), rgb(249, 249, 249), rgb(238, 238, 238)); padding: 0.1em 0.3em; font-size: 0.85em;">⌘ Command</kbd>+<kbd class="keyboard-key nowrap" style="font-family: inherit; white-space: nowrap; border: 1px solid rgb(170, 170, 170); border-radius: 0.2em; box-shadow: rgba(0, 0, 0, 0.1) 0.1em 0.1em 0.2em; background-color: rgb(249, 249, 249); background-image: linear-gradient(rgb(238, 238, 238), rgb(249, 249, 249), rgb(238, 238, 238)); padding: 0.1em 0.3em; font-size: 0.85em;">⇧ Shift</kbd>+<kbd class="keyboard-key nowrap" style="font-family: inherit; white-space: nowrap; border: 1px solid rgb(170, 170, 170); border-radius: 0.2em; box-shadow: rgba(0, 0, 0, 0.1) 0.1em 0.1em 0.2em; background-color: rgb(249, 249, 249); background-image: linear-gradient(rgb(238, 238, 238), rgb(249, 249, 249), rgb(238, 238, 238)); padding: 0.1em 0.3em; font-size: 0.85em;">/</kbd>. Users expect a help screen or similar help services popup when they press this key. Software binding this key to some other feature is likely to cause astonishment if no help appears. Malicious programs are known to exploit users' familiarity with regular shortcut keys.[11]

    In programming, a good example of this principle is the common ParseInteger(string, radix) function which exists in most languages and is used to convert a string to an integer value. The radix is usually an optional argument and assumed to be 10 (representing base 10). Other bases are usually supported (like binary or octal) but only when specified explicitly; when the radix argument is not specified, base 10 is assumed. Notably JavaScript did not originally adopt this behaviour, which resulted in developer confusion and software bugs.[12]

    相关文章

      网友评论

          本文标题:the Principle of Least Astonishm

          本文链接:https://www.haomeiwen.com/subject/ankemftx.html