xref: /freebsd-14.2/contrib/dialog/samples/msgbox2 (revision 4c8945a0)
1*4c8945a0SNathan Whitehorn#!/bin/sh
2*4c8945a0SNathan Whitehorn# $Id: msgbox2,v 1.9 2019/12/11 01:56:17 tom Exp $
3*4c8945a0SNathan Whitehorn
4*4c8945a0SNathan Whitehorn. ./setup-vars
5*4c8945a0SNathan Whitehorn
6*4c8945a0SNathan Whitehorn$DIALOG --title "MESSAGE BOX" --trim "$@" \
7*4c8945a0SNathan Whitehorn        --msgbox "Hi, this is a simple message box. You can use this to
8*4c8945a0SNathan Whitehorn                  display any message you like. The box will remain until
9*4c8945a0SNathan Whitehorn                  you press the ENTER key.  This box is being displayed
10*4c8945a0SNathan Whitehorn                  with dialogs default aspect ratio of 9." 0 0
11*4c8945a0SNathan Whitehorntest $? = "$DIALOG_ESC" && exit
12*4c8945a0SNathan Whitehorn
13*4c8945a0SNathan Whitehorn$DIALOG --aspect 12 --title "MESSAGE BOX  aspect=12" --trim "$@" \
14*4c8945a0SNathan Whitehorn        --msgbox "Hi, this is a simple message box. You can use this to
15*4c8945a0SNathan Whitehorn                  display any message you like. The box will remain until
16*4c8945a0SNathan Whitehorn                  you press the ENTER key.  This box is being displayed
17*4c8945a0SNathan Whitehorn                  with an aspect ratio of 12." 0 0
18*4c8945a0SNathan Whitehorntest $? = "$DIALOG_ESC" && exit
19*4c8945a0SNathan Whitehorn
20*4c8945a0SNathan Whitehorn$DIALOG --aspect 6 --title "MESSAGE BOX  aspect=6" --trim "$@" \
21*4c8945a0SNathan Whitehorn        --msgbox "Hi, this is a simple message box. You can use this to
22*4c8945a0SNathan Whitehorn                  display any message you like. The box will remain until
23*4c8945a0SNathan Whitehorn                  you press the ENTER key.  This box is being displayed
24*4c8945a0SNathan Whitehorn                  with an aspect ratio of 6." 0 0
25*4c8945a0SNathan Whitehorntest $? = "$DIALOG_ESC" && exit
26*4c8945a0SNathan Whitehorn
27*4c8945a0SNathan Whitehorn$DIALOG --aspect 6 --cr-wrap --title "MESSAGE BOX aspect=6 with --cr-wrap" \
28*4c8945a0SNathan Whitehorn        --trim "$@" --msgbox " \
29*4c8945a0SNathan Whitehorn           Hi, this is a simple
30*4c8945a0SNathan Whitehorn           message box. You can
31*4c8945a0SNathan Whitehorn          use this to display any
32*4c8945a0SNathan Whitehorn             message you like.
33*4c8945a0SNathan WhitehornThe box will remain until you press the ENTER key.  This box is being displayed with an aspect ratio of 6, and using --cr-wrap.\n" 0 0
34*4c8945a0SNathan Whitehorntest $? = "$DIALOG_ESC" && exit
35