font: link digraph column header to digraphs page
[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 <:
25 use Shiar_Sheet::Keyboard 2;
26 my $info = do 'screen.inc.pl' or die $! // $@;
27 my $keys = Shiar_Sheet::Keyboard->new($info);
28 $keys->map($get{map}) or undef $get{map};
29 $keys->print_rows($get{rows});
30 :>
31
32 <hr>
33
34 <div class="help">
35         <div class="left">
36 <:
37                 $keys->print_legend('legend-types', [map { "g$_" } 0 .. 8]);
38 :>
39         </div>
40
41         <div class="right">
42 <:
43                 $keys->print_legend('legend-options', [qw'arg']);
44 :>
45
46                 <ul class="legend legend-set">
47                 <li>keyboard <strong>map</strong> is
48                         <:= $get{map} ? 'set to ' : '' :><em><:= $keys->{map} :></em>
49                 <li><strong>ascii</strong> mode is
50                         <:= defined $sign{-ascii} && 'forced ' :><em><:=
51                                 $sign{-ascii} ? 'on' : 'off' :></em>
52                 <li><strong>keys</strong> are
53                         <em><:= $showkeys ? 'always shown' : 'hidden if unassigned' :></em><:=
54                                 !defined $showkeys && ' by default' :>
55                 <li>default <strong>style</strong> is
56                         <:= defined $get{style} && 'set to ' :><em><:= $style :></em>
57                 </ul>
58         </div>
59 </div>
60