line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package # hide from PAUSE |
2
|
|
|
|
|
|
|
Term::ReadLine::Simple::Constants; |
3
|
|
|
|
|
|
|
|
4
|
4
|
|
|
4
|
|
20
|
use warnings; |
|
4
|
|
|
|
|
7
|
|
|
4
|
|
|
|
|
168
|
|
5
|
4
|
|
|
4
|
|
21
|
use strict; |
|
4
|
|
|
|
|
7
|
|
|
4
|
|
|
|
|
77
|
|
6
|
4
|
|
|
4
|
|
67
|
use 5.008003; |
|
4
|
|
|
|
|
12
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
our $VERSION = '0.307'; |
9
|
|
|
|
|
|
|
|
10
|
4
|
|
|
4
|
|
20
|
use Exporter qw( import ); |
|
4
|
|
|
|
|
5
|
|
|
4
|
|
|
|
|
744
|
|
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
our @EXPORT_OK = qw( |
13
|
|
|
|
|
|
|
NEXT_get_key |
14
|
|
|
|
|
|
|
CONTROL_A CONTROL_B CONTROL_D CONTROL_E CONTROL_F CONTROL_H CONTROL_K CONTROL_U KEY_BTAB KEY_TAB |
15
|
|
|
|
|
|
|
KEY_ENTER KEY_ESC KEY_BSPACE |
16
|
|
|
|
|
|
|
VK_CODE_END VK_CODE_HOME VK_CODE_LEFT VK_CODE_UP VK_CODE_RIGHT VK_CODE_DOWN VK_CODE_DELETE VK_CODE_PAGE_UP VK_CODE_PAGE_DOWN |
17
|
|
|
|
|
|
|
VK_END VK_HOME VK_LEFT VK_UP VK_RIGHT VK_DOWN VK_DELETE VK_PAGE_UP VK_PAGE_DOWN |
18
|
|
|
|
|
|
|
); |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
our %EXPORT_TAGS = ( |
21
|
|
|
|
|
|
|
rl => [ qw( |
22
|
|
|
|
|
|
|
NEXT_get_key |
23
|
|
|
|
|
|
|
CONTROL_A CONTROL_B CONTROL_D CONTROL_E CONTROL_F CONTROL_H CONTROL_K CONTROL_U KEY_BTAB KEY_TAB |
24
|
|
|
|
|
|
|
KEY_ENTER KEY_ESC KEY_BSPACE |
25
|
|
|
|
|
|
|
VK_END VK_HOME VK_LEFT VK_UP VK_RIGHT VK_DOWN VK_DELETE VK_PAGE_UP VK_PAGE_DOWN |
26
|
|
|
|
|
|
|
) ], |
27
|
|
|
|
|
|
|
linux => [ qw( |
28
|
|
|
|
|
|
|
NEXT_get_key |
29
|
|
|
|
|
|
|
KEY_BTAB KEY_ESC |
30
|
|
|
|
|
|
|
VK_END VK_HOME VK_LEFT VK_UP VK_RIGHT VK_DOWN VK_DELETE VK_PAGE_UP VK_PAGE_DOWN |
31
|
|
|
|
|
|
|
) ], |
32
|
|
|
|
|
|
|
win32 => [ qw( |
33
|
|
|
|
|
|
|
NEXT_get_key |
34
|
|
|
|
|
|
|
VK_CODE_END VK_CODE_HOME VK_CODE_LEFT VK_CODE_UP VK_CODE_RIGHT VK_CODE_DOWN VK_CODE_DELETE VK_CODE_PAGE_UP VK_CODE_PAGE_DOWN |
35
|
|
|
|
|
|
|
VK_END VK_HOME VK_LEFT VK_UP VK_RIGHT VK_DOWN VK_DELETE VK_PAGE_UP VK_PAGE_DOWN |
36
|
|
|
|
|
|
|
) ] |
37
|
|
|
|
|
|
|
); |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
use constant { |
41
|
4
|
|
|
|
|
1526
|
NEXT_get_key => -1, |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
CONTROL_A => 0x01, |
44
|
|
|
|
|
|
|
CONTROL_B => 0x02, |
45
|
|
|
|
|
|
|
CONTROL_D => 0x04, |
46
|
|
|
|
|
|
|
CONTROL_E => 0x05, |
47
|
|
|
|
|
|
|
CONTROL_F => 0x06, |
48
|
|
|
|
|
|
|
CONTROL_H => 0x08, |
49
|
|
|
|
|
|
|
KEY_BTAB => 0x08, |
50
|
|
|
|
|
|
|
KEY_TAB => 0x09, |
51
|
|
|
|
|
|
|
CONTROL_K => 0x0b, |
52
|
|
|
|
|
|
|
KEY_ENTER => 0x0d, |
53
|
|
|
|
|
|
|
CONTROL_U => 0x15, |
54
|
|
|
|
|
|
|
KEY_ESC => 0x1b, |
55
|
|
|
|
|
|
|
KEY_BSPACE => 0x7f, |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
VK_PAGE_UP => 333, |
58
|
|
|
|
|
|
|
VK_PAGE_DOWN => 334, |
59
|
|
|
|
|
|
|
VK_END => 335, |
60
|
|
|
|
|
|
|
VK_HOME => 336, |
61
|
|
|
|
|
|
|
VK_LEFT => 337, |
62
|
|
|
|
|
|
|
VK_UP => 338, |
63
|
|
|
|
|
|
|
VK_RIGHT => 339, |
64
|
|
|
|
|
|
|
VK_DOWN => 340, |
65
|
|
|
|
|
|
|
VK_DELETE => 346, |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
VK_CODE_PAGE_UP => 33, |
68
|
|
|
|
|
|
|
VK_CODE_PAGE_DOWN => 34, |
69
|
|
|
|
|
|
|
VK_CODE_END => 35, |
70
|
|
|
|
|
|
|
VK_CODE_HOME => 36, |
71
|
|
|
|
|
|
|
VK_CODE_LEFT => 37, |
72
|
|
|
|
|
|
|
VK_CODE_UP => 38, |
73
|
|
|
|
|
|
|
VK_CODE_RIGHT => 39, |
74
|
|
|
|
|
|
|
VK_CODE_DOWN => 40, |
75
|
|
|
|
|
|
|
VK_CODE_DELETE => 46, |
76
|
4
|
|
|
4
|
|
20
|
}; |
|
4
|
|
|
|
|
5
|
|
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
|
80
|
|
|
|
|
|
|
1; |
81
|
|
|
|
|
|
|
|
82
|
|
|
|
|
|
|
__END__ |