xref: /freebsd/contrib/dialog/samples/msgbox4-8bit (revision 0b3105a37d7adcadcb720112fed4dc4e8040be99)
1#!/bin/sh
2# $Id: msgbox4-8bit,v 1.4 2010/01/13 10:20:03 tom Exp $
3
4. ./setup-vars
5
6. ./testdata-8bit
7
8width=30
9while test $width != 61
10do
11$DIALOG --title "MESSAGE BOX (width $width)" --no-collapse --colors "$@" \
12        --msgbox "\
13This sample uses characters which are non-printing in POSIX locale.
14
15\Z1`./rotated-data 0 $SAMPLE` \Z2`./rotated-data 1 $SAMPLE` \Z3`./rotated-data 2 $SAMPLE` \Z4`./rotated-data 3 $SAMPLE`\Zn
16
17Hi, this is a simple message box.  You can use this to \
18display any message you like.  The box will remain until \
19you press the ENTER key." 22 $width
20retval=$?
21
22case $retval in
23  $DIALOG_CANCEL)
24    echo "Cancel pressed.";exit;;
25  $DIALOG_ESC)
26    echo "ESC pressed.";exit;;
27esac
28
29width=`expr $width + 1`
30
31done
32