/contrib/dialog/samples/msgbox4-eucjp

https://bitbucket.org/freebsd/freebsd-head/ · Shell · 25 lines · 19 code · 4 blank · 2 comment · 2 complexity · 0883bed6ec2452d7b2267c9288444295 MD5 · raw file

  1. #!/bin/sh
  2. # $Id: msgbox4-eucjp,v 1.5 2010/01/13 10:20:03 tom Exp $
  3. . ./setup-vars
  4. width=35
  5. while test $width != 61
  6. do
  7. $DIALOG --title "MESSAGE BOX (width $width)" --clear --no-collapse "$@" \
  8. --msgbox "\
  9. This sample is written in EUC-JP.
  10. There are several checking points:
  11. (1) whether the fullwidth characters are displayed well or not,
  12. (2) whether the width of characters are evaluated properly, and
  13. (3) whether the character at line-folding is lost or not.
  14. ¤¢¤¤¤¦¤¨¤ª¤«¤­¤¯¤±¤³¤µ¤·¤¹¤»¤½¤¿¤Á¤Ä¤Æ¤È¤Ê¤Ë¤Ì¤Í¤Î
  15. £±£²£³£´£µ££·£¸£¹£°£±£²£³£´£µ££·£¸£¹£°£±£²£³£´£µ
  16. £Á£Â£Ã£Ä£Å£Æ£Ç£È£É£Ê£Ë£Ì£Í£Î£Ï£Ð£Ñ£Ò£Ó£Ô£Õ£Ö£×£Ø£Ù
  17. Hi, this is a simple message box. You can use this to \
  18. display any message you like. The box will remain until \
  19. you press the ENTER key." 22 $width
  20. width=`expr $width + 1`
  21. done