unicode: add nintendo/generic console buttons
[sheet.git] / screen.plp
1 <(common.inc.plp)><:
2
3 Html({
4         title => 'screen cheat sheet',
5         version => 'v1.0',
6         description => [
7                 "Interactive cheat sheet for the Screen terminal manager,",
8                 "describing the function of each key.",
9         ],
10         keywords => [qw'
11                 screen sheet cheat reference overview commands keyboard
12                 terminal window manager
13         '],
14         charset => $sign{charset},
15         stylesheet => [qw'light dark circus mono red terse'],
16         keys => 1,
17 });
18
19 :>
20 <h1>Screen cheat sheet</h1>
21
22 <h2>normal mode (default)</h2>
23
24 <ul id="rows">
25
26 <:
27 use Shiar_Sheet::Keyboard 2;
28 my $info = do 'screen.inc.pl' or die $! // $@;
29 my $keys = Shiar_Sheet::Keyboard->new($info);
30 $keys->map($get{map}) or undef $get{map};
31 $keys->print_rows($get{rows});
32 :>
33 </ul>
34
35 <hr>
36
37 <div class="help">
38         <div class="left">
39 <:
40                 $keys->print_legend('legend-types', [map { "g$_" } 0 .. 8]);
41 :>
42         </div>
43
44         <div class="right">
45 <:
46                 $keys->print_legend('legend-options', [qw'arg']);
47 :>
48
49                 <ul class="legend legend-set">
50                 <li>keyboard <strong>map</strong> is
51                         <:= $get{map} ? 'set to ' : '' :><em><:= $keys->{map} :></em>
52                 <li><strong>ascii</strong> mode is
53                         <:= defined $sign{-ascii} && 'forced ' :><em><:=
54                                 $sign{-ascii} ? 'on' : 'off' :></em>
55                 <li><strong>keys</strong> are
56                         <em><:= $showkeys ? 'always shown' : 'hidden if unassigned' :></em><:=
57                                 !defined $showkeys && ' by default' :>
58                 <li>default <strong>style</strong> is
59                         <:= defined $get{style} && 'set to ' :><em><:= $style :></em>
60                 </ul>
61         </div>
62 </div>
63