summaryrefslogtreecommitdiff
path: root/Master/tlpkg/tlperl/lib/Tk/messageBox.pod
diff options
context:
space:
mode:
Diffstat (limited to 'Master/tlpkg/tlperl/lib/Tk/messageBox.pod')
-rw-r--r--Master/tlpkg/tlperl/lib/Tk/messageBox.pod67
1 files changed, 67 insertions, 0 deletions
diff --git a/Master/tlpkg/tlperl/lib/Tk/messageBox.pod b/Master/tlpkg/tlperl/lib/Tk/messageBox.pod
new file mode 100644
index 00000000000..36c147b1180
--- /dev/null
+++ b/Master/tlpkg/tlperl/lib/Tk/messageBox.pod
@@ -0,0 +1,67 @@
+=head1 NAME
+
+Tk::messageBox - pop up a message window and wait for user response.
+
+=for category Popups and Dialogs
+
+=head1 SYNOPSIS
+
+S< >I<$response> = I<$widget>-E<gt>B<messageBox>(I<-option> =E<gt> I<value>, ... );
+
+=head1 DESCRIPTION
+
+This method uses L<Tk::Dialog|Tk::Dialog> to quickly create several
+common dialog boxes. A dialog widget consists of a message, an icon
+and a set of buttons (see the I<-type> option). After the message
+window is popped up, B<messageBox> waits for the user to select one of
+the buttons and return the button text (note that it's best to check the
+returned value in a case insensitive manner). NOTE: unlike
+B<Tk::Dialog> which creates its widget once and can be used many
+times, the B<messageBox> window is created every time it's used.
+
+The following option/value pairs are supported:
+
+=over 4
+
+=item B<-default>
+
+The case-sensitive symbolic name of the default button
+for this message window ('Ok', 'Cancel' and so
+on). See B<-type> for a list of the symbolic names.
+If the message box has just one button it will
+automatically be made the default, otherwise if
+this option is not specified, there won't be any
+default button.
+
+=item B<-icon>
+
+Specifies an icon to display. On X11 any of the builtin Tk bitmaps can
+specified. On Windows only B<error>, B<info>, B<question> or
+B<warning> are supported.
+
+=item B<-message>
+
+Specifies the message to display.
+
+=item B<-title>
+
+Specifies a string to display as the title.
+
+=item B<-type>
+
+Specifies a predefined set of buttons to be displayed. The following
+values are possible: 'AbortRetryIgnore', 'Ok', 'OkCancel',
+'RetryCancel', 'YesNo' or 'YesNoCancel'.
+
+=back
+
+=head1 EXAMPLE
+
+I<$response> = I<$mw>-E<gt>B<messageBox>(-icon =E<gt> 'question', -message =E<gt> 'Hello World!', -title =E<gt> 'My title', -type =E<gt> 'AbortRetryIgnore', -default =E<gt> 'Retry');
+
+=head1 AUTHOR
+
+Stephen.O.Lidie@Lehigh.EDU. 98/05/25
+
+=cut
+