Develop and Download Open Source Software

Browse Subversion Repository

Contents of /branches/ttcomtester/tests/unicodebuf-decsel.sh

Parent Directory Parent Directory | Revision Log Revision Log


Revision 10521 - (show annotations) (download) (as text)
Fri Jan 20 16:03:38 2023 UTC (13 months, 2 weeks ago) by zmatsuo
File MIME type: text/x-sh
File size: 937 byte(s)
add communication test tool
1 #!/bin/sh
2
3 CSI() {
4 printf "\033[%s" "$1"
5 }
6
7 DECSCA() {
8 case "$1" in
9 off|0) ch=0;;
10 on|1) ch=1;;
11 esac
12 CSI ${ch}\"q
13 }
14
15 Line() {
16 CSI "$1;1H"
17 }
18
19 SetLine() {
20 DECSCA off
21 printf "********************"
22 DECSCA on
23 printf "########################################"
24 DECSCA off
25 printf "********************"
26 CSI 40G
27 }
28
29 InitScreen() {
30 CSI "8;24;80t" # 端末サイズを 80x24 に変更
31 CSI "2J" # 画面消去
32 CSI "1;1H" # カーソルを画面左上に移動
33 }
34
35 ICHtest() {
36 SetLine
37 CSI "?0K"
38 printf "\n"
39
40 SetLine
41 CSI "?1K"
42 printf "\n"
43
44 SetLine
45 CSI "?2K"
46 printf "\n"
47 }
48
49 ret=0
50
51 InitScreen
52
53 ICHtest
54
55 cat <<_EoF_
56
57 === 正しい出力は以下 ===
58
59 ********************########################################
60 ########################################********************
61 ########################################
62
63 _EoF_

Properties

Name Value
svn:executable *

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26