|
1 | 1 | 'use strict';
|
2 | 2 |
|
3 | 3 | // From http://www.umich.edu/~archive/apple2/misc/programmers/vt100.codes.txt
|
4 |
| -exports.vt52Codes = { |
5 |
| - A: ['Cursor up'], |
6 |
| - B: ['Cursor down'], |
7 |
| - C: ['Cursor right'], |
8 |
| - D: ['Cursor left'], |
9 |
| - H: ['Cursor to home'], |
10 |
| - I: ['Reverse line feed'], |
11 |
| - J: ['Erase to end of screen'], |
12 |
| - K: ['Erase to end of line'], |
13 |
| - Z: ['Identify'], |
14 |
| - '=': ['Enter alternate keypad mode'], |
15 |
| - '>': ['Exit alternate keypad mode'], |
16 |
| - 1: ['Graphics processor on'], |
17 |
| - 2: ['Graphics processor off'], |
18 |
| - '<': ['Enter ANSI mode'] |
19 |
| -}; |
| 4 | +exports.vt52Codes = new Map([ |
| 5 | + ['A', ['Cursor up']], |
| 6 | + ['B', ['Cursor down']], |
| 7 | + ['C', ['Cursor right']], |
| 8 | + ['D', ['Cursor left']], |
| 9 | + ['H', ['Cursor to home']], |
| 10 | + ['I', ['Reverse line feed']], |
| 11 | + ['J', ['Erase to end of screen']], |
| 12 | + ['K', ['Erase to end of line']], |
| 13 | + ['Z', ['Identify']], |
| 14 | + ['=', ['Enter alternate keypad mode']], |
| 15 | + ['>', ['Exit alternate keypad mode']], |
| 16 | + ['1', ['Graphics processor on']], |
| 17 | + ['2', ['Graphics processor off']], |
| 18 | + ['<', ['Enter ANSI mode']] |
| 19 | +]); |
20 | 20 |
|
21 | 21 | // From http://www.umich.edu/~archive/apple2/misc/programmers/vt100.codes.txt
|
22 |
| -exports.ansiCompatible = { |
23 |
| - '[176A': ['Cursor up Pn lines'], |
24 |
| - '[176B': ['Cursor down Pn lines'], |
25 |
| - '[176C': ['Cursor forward Pn characters (right)'], |
26 |
| - '[176D': ['Cursor backward Pn characters (left)'], |
27 |
| - '[176;176H': ['Direct cursor addressing, where Pl is line#, Pc is column#'], |
28 |
| - '[176;176f': ['Direct cursor addressing, where Pl is line#, Pc is column#'], |
29 |
| - |
30 |
| - 7: ['Save cursor and attributes'], |
31 |
| - 8: ['Restore cursor and attributes'], |
32 |
| - |
33 |
| - '#3': ['Change this line to double-height top half'], |
34 |
| - '#4': ['Change this line to double-height bottom half'], |
35 |
| - '#5': ['Change this line to single-width single-height'], |
36 |
| - '#6': ['Change this line to double-width single-height'], |
37 |
| - |
38 |
| - '[176;176;176;176;176;176;176m': ['Text Styles'], |
39 |
| - '[176;176;176;176;176;176;176q': ['Programmable LEDs'], |
40 |
| - |
41 |
| - '[K': ['Erase from cursor to end of line'], |
42 |
| - '[0K': ['Same'], |
43 |
| - '[1K': ['Erase from beginning of line to cursor'], |
44 |
| - '[2K': ['Erase line containing cursor'], |
45 |
| - '[J': ['Erase from cursor to end of screen'], |
46 |
| - '[0J': ['Same'], |
47 |
| - '[2J': ['Erase entire screen'], |
48 |
| - '[P': ['Delete character'], |
49 |
| - '[0P': ['Delete character (0P)'], |
50 |
| - '[2P': ['Delete 2 characters'], |
51 |
| - |
52 |
| - '(A': ['United Kingdom (UK) (Character Set G0)'], |
53 |
| - ')A': ['United Kingdom (UK) (Character Set G1)'], |
54 |
| - '(B': ['United States (USASCII) (Character Set G0)'], |
55 |
| - ')B': ['United States (USASCII) (Character Set G1)'], |
56 |
| - '(0': ['Special graphics/line drawing set (Character Set G0)'], |
57 |
| - ')0': ['Special graphics/line drawing set (Character Set G1)'], |
58 |
| - '(1': ['Alternative character ROM (Character Set G0)'], |
59 |
| - ')1': ['Alternative character ROM (Character Set G1)'], |
60 |
| - '(2': ['Alternative graphic ROM (Character Set G0)'], |
61 |
| - ')2': ['Alternative graphic ROM (Character Set G1)'], |
62 |
| - |
63 |
| - H: ['Set tab at current column'], |
64 |
| - '[g': ['Clear tab at current column'], |
65 |
| - '[0g': ['Same'], |
66 |
| - '[3g': ['Clear all tabs'], |
67 |
| - |
68 |
| - '[6n': ['Cursor position report'], |
69 |
| - '[176;176R': ['(response; Pl=line#; Pc=column#)'], |
70 |
| - '[5n': ['Status report'], |
71 |
| - '[c': ['(response; terminal Ok)'], |
72 |
| - '[0c': ['(response; teminal not Ok)'], |
73 |
| - '[?1;176c': ['response; where Ps is option present:'], |
74 |
| - |
75 |
| - c: ['Causes power-up reset routine to be executed'], |
76 |
| - '#8': ['Fill screen with "E"'], |
77 |
| - '[2;176y': ['Invoke Test(s), where Ps is a decimal computed by adding the numbers of the desired tests to be executed'] |
78 |
| -}; |
| 22 | +exports.ansiCompatible = new Map([ |
| 23 | + ['[176A', ['Cursor up Pn lines']], |
| 24 | + ['[176B', ['Cursor down Pn lines']], |
| 25 | + ['[176C', ['Cursor forward Pn characters (right)']], |
| 26 | + ['[176D', ['Cursor backward Pn characters (left)']], |
| 27 | + ['[176;176H', ['Direct cursor addressing, where Pl is line#, Pc is column#']], |
| 28 | + ['[176;176f', ['Direct cursor addressing, where Pl is line#, Pc is column#']], |
| 29 | + |
| 30 | + ['7', ['Save cursor and attributes']], |
| 31 | + ['8', ['Restore cursor and attributes']], |
| 32 | + |
| 33 | + ['#3', ['Change this line to double-height top half']], |
| 34 | + ['#4', ['Change this line to double-height bottom half']], |
| 35 | + ['#5', ['Change this line to single-width single-height']], |
| 36 | + ['#6', ['Change this line to double-width single-height']], |
| 37 | + |
| 38 | + ['[176;176;176;176;176;176;176m', ['Text Styles']], |
| 39 | + ['[176;176;176;176;176;176;176q', ['Programmable LEDs']], |
| 40 | + |
| 41 | + ['[K', ['Erase from cursor to end of line']], |
| 42 | + ['[0K', ['Same']], |
| 43 | + ['[1K', ['Erase from beginning of line to cursor']], |
| 44 | + ['[2K', ['Erase line containing cursor']], |
| 45 | + ['[J', ['Erase from cursor to end of screen']], |
| 46 | + ['[0J', ['Same']], |
| 47 | + ['[2J', ['Erase entire screen']], |
| 48 | + ['[P', ['Delete character']], |
| 49 | + ['[0P', ['Delete character (0P)']], |
| 50 | + ['[2P', ['Delete 2 characters']], |
| 51 | + |
| 52 | + ['(A', ['United Kingdom (UK) (Character Set G0)']], |
| 53 | + [')A', ['United Kingdom (UK) (Character Set G1)']], |
| 54 | + ['(B', ['United States (USASCII) (Character Set G0)']], |
| 55 | + [')B', ['United States (USASCII) (Character Set G1)']], |
| 56 | + ['(0', ['Special graphics/line drawing set (Character Set G0)']], |
| 57 | + [')0', ['Special graphics/line drawing set (Character Set G1)']], |
| 58 | + ['(1', ['Alternative character ROM (Character Set G0)']], |
| 59 | + [')1', ['Alternative character ROM (Character Set G1)']], |
| 60 | + ['(2', ['Alternative graphic ROM (Character Set G0)']], |
| 61 | + [')2', ['Alternative graphic ROM (Character Set G1)']], |
| 62 | + |
| 63 | + ['H', ['Set tab at current column']], |
| 64 | + ['[g', ['Clear tab at current column']], |
| 65 | + ['[0g', ['Same']], |
| 66 | + ['[3g', ['Clear all tabs']], |
| 67 | + |
| 68 | + ['[6n', ['Cursor position report']], |
| 69 | + ['[176;176R', ['(response; Pl=line#; Pc=column#)']], |
| 70 | + ['[5n', ['Status report']], |
| 71 | + ['[c', ['(response; terminal Ok)']], |
| 72 | + ['[0c', ['(response; teminal not Ok)']], |
| 73 | + ['[?1;176c', ['response; where Ps is option present:']], |
| 74 | + |
| 75 | + ['c', ['Causes power-up reset routine to be executed']], |
| 76 | + ['#8', ['Fill screen with "E"']], |
| 77 | + ['[2;176y', ['Invoke Test(s), where Ps is a decimal computed by adding the numbers of the desired tests to be executed']] |
| 78 | +]); |
79 | 79 |
|
80 | 80 | // From http://ascii-table.com/ansi-escape-sequences-vt-100.php
|
81 |
| -exports.commonCodes = { |
82 |
| - '[176A': ['Move cursor up n lines', 'CUU'], |
83 |
| - '[176B': ['Move cursor down n lines', 'CUD'], |
84 |
| - '[176C': ['Move cursor right n lines', 'CUF'], |
85 |
| - '[176D': ['Move cursor left n lines', 'CUB'], |
86 |
| - '[176;176H': ['Move cursor to screen location v,h', 'CUP'], |
87 |
| - '[176;176f': ['Move cursor to screen location v,h', 'CUP'], |
88 |
| - '[176;176r': ['Set top and bottom lines of a window', 'DECSTBM'], |
89 |
| - '[176;176R': ['Response: cursor is at v,h', 'CPR'], |
90 |
| - |
91 |
| - '[?1;1760c': ['Response: terminal type code n', 'DA'], |
92 |
| - |
93 |
| - '[20h': ['Set new line mode', 'LMN'], |
94 |
| - '[?1h': ['Set cursor key to application', 'DECCKM'], |
95 |
| - '[?3h': ['Set number of columns to 132', 'DECCOLM'], |
96 |
| - '[?4h': ['Set smooth scrolling', 'DECSCLM'], |
97 |
| - '[?5h': ['Set reverse video on screen', 'DECSCNM'], |
98 |
| - '[?6h': ['Set origin to relative', 'DECOM'], |
99 |
| - '[?7h': ['Set auto-wrap mode', 'DECAWM'], |
100 |
| - '[?8h': ['Set auto-repeat mode', 'DECARM'], |
101 |
| - '[?9h': ['Set interlacing mode', 'DECINLM'], |
102 |
| - '[20l': ['Set line feed mode', 'LMN'], |
103 |
| - '[?1l': ['Set cursor key to cursor', 'DECCKM'], |
104 |
| - '[?2l': ['Set VT52 (versus ANSI)', 'DECANM'], |
105 |
| - '[?3l': ['Set number of columns to 80', 'DECCOLM'], |
106 |
| - '[?4l': ['Set jump scrolling', 'DECSCLM'], |
107 |
| - '[?5l': ['Set normal video on screen', 'DECSCNM'], |
108 |
| - '[?6l': ['Set origin to absolute', 'DECOM'], |
109 |
| - '[?7l': ['Reset auto-wrap mode', 'DECAWM'], |
110 |
| - '[?8l': ['Reset auto-repeat mode', 'DECARM'], |
111 |
| - '[?9l': ['Reset interlacing mode', 'DECINLM'], |
112 |
| - |
113 |
| - N: ['Set single shift 2', 'SS2'], |
114 |
| - O: ['Set single shift 3', 'SS3'], |
115 |
| - |
116 |
| - '[m': ['Turn off character attributes', 'SGR0'], |
117 |
| - '[0m': ['Turn off character attributes', 'SGR0'], |
118 |
| - '[1m': ['Turn bold mode on', 'SGR1'], |
119 |
| - '[2m': ['Turn low intensity mode on', 'SGR2'], |
120 |
| - '[4m': ['Turn underline mode on', 'SGR4'], |
121 |
| - '[5m': ['Turn blinking mode on', 'SGR5'], |
122 |
| - '[7m': ['Turn reverse video on', 'SGR7'], |
123 |
| - '[8m': ['Turn invisible text mode on', 'SGR8'], |
124 |
| - |
125 |
| - '[9m': ['strikethrough on', '--'], |
126 |
| - '[22m': ['bold off (see below)', '--'], |
127 |
| - '[23m': ['italics off', '--'], |
128 |
| - '[24m': ['underline off', '--'], |
129 |
| - '[27m': ['inverse off', '--'], |
130 |
| - '[29m': ['strikethrough off', '--'], |
131 |
| - '[30m': ['set foreground color to black', '--'], |
132 |
| - '[31m': ['set foreground color to red', '--'], |
133 |
| - '[32m': ['set foreground color to green', '--'], |
134 |
| - '[33m': ['set foreground color to yellow', '--'], |
135 |
| - '[34m': ['set foreground color to blue', '--'], |
136 |
| - '[35m': ['set foreground color to magenta (purple)', '--'], |
137 |
| - '[36m': ['set foreground color to cyan', '--'], |
138 |
| - '[37m': ['set foreground color to white', '--'], |
139 |
| - '[39m': ['set foreground color to default (white)', '--'], |
140 |
| - '[40m': ['set background color to black', '--'], |
141 |
| - '[41m': ['set background color to red', '--'], |
142 |
| - '[42m': ['set background color to green', '--'], |
143 |
| - '[43m': ['set background color to yellow', '--'], |
144 |
| - '[44m': ['set background color to blue', '--'], |
145 |
| - '[45m': ['set background color to magenta (purple)', '--'], |
146 |
| - '[46m': ['set background color to cyan', '--'], |
147 |
| - '[47m': ['set background color to white', '--'], |
148 |
| - '[49m': ['set background color to default (black)', '--'], |
149 |
| - |
150 |
| - '[H': ['Move cursor to upper left corner', 'cursorhome'], |
151 |
| - '[;H': ['Move cursor to upper left corner', 'cursorhome'], |
152 |
| - '[f': ['Move cursor to upper left corner', 'hvhome'], |
153 |
| - '[;f': ['Move cursor to upper left corner', 'hvhome'], |
154 |
| - M: ['Move/scroll window down one line', 'RI'], |
155 |
| - E: ['Move to next line', 'NEL'], |
156 |
| - |
157 |
| - H: ['Set a tab at the current column', 'HTS'], |
158 |
| - '[g': ['Clear a tab at the current column', 'TBC'], |
159 |
| - '[0g': ['Clear a tab at the current column', 'TBC'], |
160 |
| - '[3g': ['Clear all tabs', 'TBC'], |
161 |
| - |
162 |
| - '[K': ['Clear line from cursor right', 'EL0'], |
163 |
| - '[0K': ['Clear line from cursor right', 'EL0'], |
164 |
| - '[1K': ['Clear line from cursor left', 'EL1'], |
165 |
| - '[2K': ['Clear entire line', 'EL2'], |
166 |
| - '[J': ['Clear screen from cursor down', 'ED0'], |
167 |
| - '[0J': ['Clear screen from cursor down', 'ED0'], |
168 |
| - '[1J': ['Clear screen from cursor up', 'ED1'], |
169 |
| - '[2J': ['Clear entire screen', 'ED2'], |
170 |
| - |
171 |
| - '[c': ['Identify what terminal type', 'DA'], |
172 |
| - '[0c': ['Identify what terminal type (another)', 'DA'], |
173 |
| - c: ['Reset terminal to initial state', 'RIS'], |
174 |
| - '[2;1y': ['Confidence power up test', 'DECTST'], |
175 |
| - '[2;2y': ['Confidence loopback test', 'DECTST'], |
176 |
| - '[2;9y': ['Repeat power up test', 'DECTST'], |
177 |
| - '[2;10y': ['Repeat loopback test', 'DECTST'], |
178 |
| - '[0q': ['Turn off all four leds', 'DECLL0'], |
179 |
| - '[1q': ['Turn on LED #1', 'DECLL1'], |
180 |
| - '[2q': ['Turn on LED #2', 'DECLL2'], |
181 |
| - '[3q': ['Turn on LED #3', 'DECLL3'], |
182 |
| - '[4q': ['Turn on LED #4', 'DECLL4'] |
183 |
| -}; |
| 81 | +exports.commonCodes = new Map([ |
| 82 | + ['[176A', ['Move cursor up n lines', 'CUU']], |
| 83 | + ['[176B', ['Move cursor down n lines', 'CUD']], |
| 84 | + ['[176C', ['Move cursor right n lines', 'CUF']], |
| 85 | + ['[176D', ['Move cursor left n lines', 'CUB']], |
| 86 | + ['[176;176H', ['Move cursor to screen location v,h', 'CUP']], |
| 87 | + ['[176;176f', ['Move cursor to screen location v,h', 'CUP']], |
| 88 | + ['[176;176r', ['Set top and bottom lines of a window', 'DECSTBM']], |
| 89 | + ['[176;176R', ['Response: cursor is at v,h', 'CPR']], |
| 90 | + |
| 91 | + ['[?1;1760c', ['Response: terminal type code n', 'DA']], |
| 92 | + |
| 93 | + ['[20h', ['Set new line mode', 'LMN']], |
| 94 | + ['[?1h', ['Set cursor key to application', 'DECCKM']], |
| 95 | + ['[?3h', ['Set number of columns to 132', 'DECCOLM']], |
| 96 | + ['[?4h', ['Set smooth scrolling', 'DECSCLM']], |
| 97 | + ['[?5h', ['Set reverse video on screen', 'DECSCNM']], |
| 98 | + ['[?6h', ['Set origin to relative', 'DECOM']], |
| 99 | + ['[?7h', ['Set auto-wrap mode', 'DECAWM']], |
| 100 | + ['[?8h', ['Set auto-repeat mode', 'DECARM']], |
| 101 | + ['[?9h', ['Set interlacing mode', 'DECINLM']], |
| 102 | + ['[20l', ['Set line feed mode', 'LMN']], |
| 103 | + ['[?1l', ['Set cursor key to cursor', 'DECCKM']], |
| 104 | + ['[?2l', ['Set VT52 (versus ANSI)', 'DECANM']], |
| 105 | + ['[?3l', ['Set number of columns to 80', 'DECCOLM']], |
| 106 | + ['[?4l', ['Set jump scrolling', 'DECSCLM']], |
| 107 | + ['[?5l', ['Set normal video on screen', 'DECSCNM']], |
| 108 | + ['[?6l', ['Set origin to absolute', 'DECOM']], |
| 109 | + ['[?7l', ['Reset auto-wrap mode', 'DECAWM']], |
| 110 | + ['[?8l', ['Reset auto-repeat mode', 'DECARM']], |
| 111 | + ['[?9l', ['Reset interlacing mode', 'DECINLM']], |
| 112 | + |
| 113 | + ['N', ['Set single shift 2', 'SS2']], |
| 114 | + ['O', ['Set single shift 3', 'SS3']], |
| 115 | + |
| 116 | + ['[m', ['Turn off character attributes', 'SGR0']], |
| 117 | + ['[0m', ['Turn off character attributes', 'SGR0']], |
| 118 | + ['[1m', ['Turn bold mode on', 'SGR1']], |
| 119 | + ['[2m', ['Turn low intensity mode on', 'SGR2']], |
| 120 | + ['[4m', ['Turn underline mode on', 'SGR4']], |
| 121 | + ['[5m', ['Turn blinking mode on', 'SGR5']], |
| 122 | + ['[7m', ['Turn reverse video on', 'SGR7']], |
| 123 | + ['[8m', ['Turn invisible text mode on', 'SGR8']], |
| 124 | + |
| 125 | + ['[9m', ['strikethrough on', '--']], |
| 126 | + ['[22m', ['bold off (see below)', '--']], |
| 127 | + ['[23m', ['italics off', '--']], |
| 128 | + ['[24m', ['underline off', '--']], |
| 129 | + ['[27m', ['inverse off', '--']], |
| 130 | + ['[29m', ['strikethrough off', '--']], |
| 131 | + ['[30m', ['set foreground color to black', '--']], |
| 132 | + ['[31m', ['set foreground color to red', '--']], |
| 133 | + ['[32m', ['set foreground color to green', '--']], |
| 134 | + ['[33m', ['set foreground color to yellow', '--']], |
| 135 | + ['[34m', ['set foreground color to blue', '--']], |
| 136 | + ['[35m', ['set foreground color to magenta (purple)', '--']], |
| 137 | + ['[36m', ['set foreground color to cyan', '--']], |
| 138 | + ['[37m', ['set foreground color to white', '--']], |
| 139 | + ['[39m', ['set foreground color to default (white)', '--']], |
| 140 | + ['[40m', ['set background color to black', '--']], |
| 141 | + ['[41m', ['set background color to red', '--']], |
| 142 | + ['[42m', ['set background color to green', '--']], |
| 143 | + ['[43m', ['set background color to yellow', '--']], |
| 144 | + ['[44m', ['set background color to blue', '--']], |
| 145 | + ['[45m', ['set background color to magenta (purple)', '--']], |
| 146 | + ['[46m', ['set background color to cyan', '--']], |
| 147 | + ['[47m', ['set background color to white', '--']], |
| 148 | + ['[49m', ['set background color to default (black)', '--']], |
| 149 | + |
| 150 | + ['[H', ['Move cursor to upper left corner', 'cursorhome']], |
| 151 | + ['[;H', ['Move cursor to upper left corner', 'cursorhome']], |
| 152 | + ['[f', ['Move cursor to upper left corner', 'hvhome']], |
| 153 | + ['[;f', ['Move cursor to upper left corner', 'hvhome']], |
| 154 | + ['M', ['Move/scroll window down one line', 'RI']], |
| 155 | + ['E', ['Move to next line', 'NEL']], |
| 156 | + |
| 157 | + ['H', ['Set a tab at the current column', 'HTS']], |
| 158 | + ['[g', ['Clear a tab at the current column', 'TBC']], |
| 159 | + ['[0g', ['Clear a tab at the current column', 'TBC']], |
| 160 | + ['[3g', ['Clear all tabs', 'TBC']], |
| 161 | + |
| 162 | + ['[K', ['Clear line from cursor right', 'EL0']], |
| 163 | + ['[0K', ['Clear line from cursor right', 'EL0']], |
| 164 | + ['[1K', ['Clear line from cursor left', 'EL1']], |
| 165 | + ['[2K', ['Clear entire line', 'EL2']], |
| 166 | + ['[J', ['Clear screen from cursor down', 'ED0']], |
| 167 | + ['[0J', ['Clear screen from cursor down', 'ED0']], |
| 168 | + ['[1J', ['Clear screen from cursor up', 'ED1']], |
| 169 | + ['[2J', ['Clear entire screen', 'ED2']], |
| 170 | + |
| 171 | + ['[c', ['Identify what terminal type', 'DA']], |
| 172 | + ['[0c', ['Identify what terminal type (another)', 'DA']], |
| 173 | + ['c', ['Reset terminal to initial state', 'RIS']], |
| 174 | + ['[2;1y', ['Confidence power up test', 'DECTST']], |
| 175 | + ['[2;2y', ['Confidence loopback test', 'DECTST']], |
| 176 | + ['[2;9y', ['Repeat power up test', 'DECTST']], |
| 177 | + ['[2;10y', ['Repeat loopback test', 'DECTST']], |
| 178 | + ['[0q', ['Turn off all four leds', 'DECLL0']], |
| 179 | + ['[1q', ['Turn on LED #1', 'DECLL1']], |
| 180 | + ['[2q', ['Turn on LED #2', 'DECLL2']], |
| 181 | + ['[3q', ['Turn on LED #3', 'DECLL3']], |
| 182 | + ['[4q', ['Turn on LED #4', 'DECLL4']] |
| 183 | +]); |
184 | 184 |
|
185 | 185 | // From http://ascii-table.com/ansi-escape-sequences-vt-100.php
|
186 |
| -exports.otherCode = { |
187 |
| - 7: ['Save cursor position and attributes', 'DECSC'], |
188 |
| - 8: ['Restore cursor position and attributes', 'DECSC'], |
189 |
| - |
190 |
| - '=': ['Set alternate keypad mode', 'DECKPAM'], |
191 |
| - '>': ['Set numeric keypad mode', 'DECKPNM'], |
192 |
| - |
193 |
| - '(A': ['Set United Kingdom G0 character set', 'setukg0'], |
194 |
| - ')A': ['Set United Kingdom G1 character set', 'setukg1'], |
195 |
| - '(B': ['Set United States G0 character set', 'setusg0'], |
196 |
| - ')B': ['Set United States G1 character set', 'setusg1'], |
197 |
| - '(0': ['Set G0 special chars. & line set', 'setspecg0'], |
198 |
| - ')0': ['Set G1 special chars. & line set', 'setspecg1'], |
199 |
| - '(1': ['Set G0 alternate character ROM', 'setaltg0'], |
200 |
| - ')1': ['Set G1 alternate character ROM', 'setaltg1'], |
201 |
| - '(2': ['Set G0 alt char ROM and spec. graphics', 'setaltspecg0'], |
202 |
| - ')2': ['Set G1 alt char ROM and spec. graphics', 'setaltspecg1'], |
203 |
| - |
204 |
| - '#3': ['Double-height letters, top half', 'DECDHL'], |
205 |
| - '#4': ['Double-height letters, bottom half', 'DECDHL'], |
206 |
| - '#5': ['Single width, single height letters', 'DECSWL'], |
207 |
| - '#6': ['Double width, single height letters', 'DECDWL'], |
208 |
| - '#8': ['Screen alignment display', 'DECALN'], |
209 |
| - |
210 |
| - '5n': ['Device status report', 'DSR'], |
211 |
| - '0n': ['Response: terminal is OK', 'DSR'], |
212 |
| - '3n': ['Response: terminal is not OK', 'DSR'], |
213 |
| - '6n': ['Get cursor position', 'DSR'] |
214 |
| -}; |
| 186 | +exports.otherCode = new Map([ |
| 187 | + ['7', ['Save cursor position and attributes', 'DECSC']], |
| 188 | + ['8', ['Restore cursor position and attributes', 'DECSC']], |
| 189 | + |
| 190 | + ['=', ['Set alternate keypad mode', 'DECKPAM']], |
| 191 | + ['>', ['Set numeric keypad mode', 'DECKPNM']], |
| 192 | + |
| 193 | + ['(A', ['Set United Kingdom G0 character set', 'setukg0']], |
| 194 | + [')A', ['Set United Kingdom G1 character set', 'setukg1']], |
| 195 | + ['(B', ['Set United States G0 character set', 'setusg0']], |
| 196 | + [')B', ['Set United States G1 character set', 'setusg1']], |
| 197 | + ['(0', ['Set G0 special chars. & line set', 'setspecg0']], |
| 198 | + [')0', ['Set G1 special chars. & line set', 'setspecg1']], |
| 199 | + ['(1', ['Set G0 alternate character ROM', 'setaltg0']], |
| 200 | + [')1', ['Set G1 alternate character ROM', 'setaltg1']], |
| 201 | + ['(2', ['Set G0 alt char ROM and spec. graphics', 'setaltspecg0']], |
| 202 | + [')2', ['Set G1 alt char ROM and spec. graphics', 'setaltspecg1']], |
| 203 | + |
| 204 | + ['#3', ['Double-height letters, top half', 'DECDHL']], |
| 205 | + ['#4', ['Double-height letters, bottom half', 'DECDHL']], |
| 206 | + ['#5', ['Single width, single height letters', 'DECSWL']], |
| 207 | + ['#6', ['Double width, single height letters', 'DECDWL']], |
| 208 | + ['#8', ['Screen alignment display', 'DECALN']], |
| 209 | + |
| 210 | + ['5n', ['Device status report', 'DSR']], |
| 211 | + ['0n', ['Response: terminal is OK', 'DSR']], |
| 212 | + ['3n', ['Response: terminal is not OK', 'DSR']], |
| 213 | + ['6n', ['Get cursor position', 'DSR']] |
| 214 | +]); |
0 commit comments