FreeBSD Manual Pages
XmtDisplayErrorAndAsk(3) Library Functions Manual XmtDisplayErrorAndAsk(3) NAME XmtDisplayErrorAndAsk(), XmtDisplayWarningAndAsk() - display an error or warning message, ask a yes-or-no question and return the user's re- sponse. SYNOPSIS #include <Xmt/Dialogs.h> Boolean XmtDisplayErrorAndAsk(Widget w, String query_name, String mes- sage_default, String yes_default, String no_default, XmtButtonType default_button_default, String help_text_default) Boolean XmtDisplayWarningAndAsk(Widget w, String query_name, String message_default, String yes_default, String no_default, XmtButtonType default_button_default, String help_text_default) ARGUMENTS INPUTS w The shell widget over which the dialog will be displayed, or any descendant of that shell. query_name The name of this instantiation of the dialog, used to look up resources. NULL may be specified, but will result in a dialog that cannot be customized through the resource data- base. prompt_default The prompt message to be displayed in the dialog, unless an overriding value is found in the resource database. yes_default The string to be displayed in the Yes button, unless an overriding value is found in the resource database. NULL may be specified. no_default The string to be displayed in the No button, unless an overriding value is found in the resource database. NULL may be specified. default_button_default The default button (ie. the button that will be activated if the user presses the Return key), unless an overriding value is found in the resource database. Legal values are: XmtYesButton and Xmt NoButton. help_text_default The help text to display when the user clicks the Help but- ton, unless an overriding value is found in resource data- base. NULL may be specified. RETURNS True if the user clicked the Yes button; False if the user clicked the No button. DESCRIPTION XmtDisplayErrorAndAsk() and XmtDisplayWarningAndAsk() are simplified interfaces to XmtAskForBoolean(). They display a modal dialog box dis- playing a warning or error message and asking the user for a yes or no response to a question. Then they enter an internal event loop until the user selects either the Yes or No buttons. They return True if the user answers Yes and False if the user answers with the No button. Unlike XmtAskForBoolean(), which returns False when the user clicks the Cancel button, these functions do not display a Cancel button, so they directly return the user's response to the question. If help text is found in the resource database for this dialog, or if the help_text_default argument is non-NULL, then this text will be dis- played (using XmtDisplayInformation()) when the user clicks on the Help button. If there is no help available for the dialog, then the Help button will be insensitive. If you specify a query_name argument to these functions, then you can customize a number of attributes of the resulting dialogs through the resource database. See XmtAskForBoolean() for more information. Also note that these functions use the same cached dialog widgets that XmtAskForBoolean() does, and you can set resources on them as described for that function. SEE ALSO Chapter 26, Simple Input Dialogs, XmtAskForBoolean(), XmtDisplayErrorMsg(), XmtDisplayErrorAndAsk(), XmtDisplayWarningMsg(), XmtDisplayWarningAndAsk(). Xmt Motif Tools XmtDisplayErrorAndAsk(3)
NAME | SYNOPSIS | ARGUMENTS | DESCRIPTION | SEE ALSO
Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=XmtDisplayWarningAndAsk&sektion=3&manpath=FreeBSD+Ports+15.0>
