In user interface design, a modal window (often called modal dialog because the window is almost always used to display a dialog box) is a child window which requires the user to interact with it before they can return to operating the parent application. Modal windows are commonly used in GUI systems to command user awareness and to display emergency states.
Frequent uses of modal windows:
- drawing attention to vital pieces of information. This use has been criticised as ineffective.
- blocking the application flow until information required to continue is entered.
- collecting application configuration options in a centralized dialog.
- warning that the effects of the current action are not reversible. This is a frequent interaction pattern for modal dialogs, but it is also criticised by usability experts as being ineffective for its intended use (protection against errors in destructive actions) and for which better alternatives exist.
Relevancy and use
Modal windows are more common in the Microsoft Windows world, where modal windows frequently are an element of Multiple Document Interface applications, than in that of Mac OS, Unix-derivates, and the X Window System. In these OS's, many features that would be represented by modal windows in Windows are instead implemented as transient windows. Transient windows behave similarly to modal windows—they are always on top of the parent window and are not shown in the window list, but they do not disable the use of other windows in the application.
A modal window blocks all other work-flow in the program until the modal window is closed. Users may not recognize that a modal window requires their attention, leading to confusion about the main window being non-responsive, or causing loss of the user's data input (see Mode error).
Sentiments against modal windows inspired some of the primary guidelines in early human-computer interface work. Microsoft's use of wizards for example, was seen as excessive in Windows 95.
Still, modal windows are an integral part of common GUI toolkits and are frequently used when designing user workflow. Believing that too many active modeless dialogs can lead users into confusion, proponents of modal windows advocate reducing the amount of user input at a given time. This, they argue, can reduce user confusion, while minimizing the likelihood of an error as a result of having too many modeless windows open concurrently.
Usability practitioners counter these claims arguing that trying to restrict user actions for the sake of usability is an error, since this leads to user frustration for no benefit. User input is necessarily entered at one place at a time, as it requires conscious attention anyway. Users can handle complex amounts of information, given that it's presented in a well-structured and logical design, by performing a preliminary general scanning and then centering their attention in the tool required to complete a goal; complex goals will often require switching attention from one point to another.
Thus, the proposed correct solution to the problem would be to design every input element as a small, self-contained, task-oriented interaction (i.e. guided by the data dependencies required to complete a goal, not the interface states hardwired by the coder). This way, presenting several simultaneous input elements would be a benefit to the user, since she could switch easily from one to another following her flow of consciousness instead of being coerced into a predefined programmed path.