There are two types of alerts, standard and caution. Most alerts should be standard alerts, which display the application icon of the current application, as shown in Figure 1.
Use a caution alert only to warn the user when a possible side effect of the current task is the inadvertent destruction of data. A caution alert displays a caution icon badged with application icon, as shown in Figure 2.
How you specify the alert type varies according to programmatic interface:
NSAlert. Send setAlertStyle:
to an NSAlert object with an argument of NSWarningAlertStyle
or NSInformationalAlertStyle
to specify a standard alert. Send the same message with an argument of NSCriticalAlertStyle
to specify a caution alert.
Functional API. Use the NSBeginAlertSheet
function to display a standard alert and NSBeginCriticalAlertSheet
to display a caution alert.
Caution alerts should be used only as specified in the “Alerts” in Apple Human Interface Guidelines section of Apple Human Interface Guidelines.
Last updated: 2009-05-04