10 stylesheet => [qw'light circus dark red'],
11 data => [qw'apl.inc.pl'],
14 use Shiar_Sheet::FormatChar;
15 my $glyphs = Shiar_Sheet::FormatChar->new;
17 my @ops = do 'apl.inc.pl';
18 @ops > 1 or die "cannot open operator include: $@\n";
24 <table class="mapped">
25 <col><colgroup span=3><colgroup span=2>
31 <td title="unified/Dyalog key combination">⎈
32 <td><a href="/digraphs" title="digraph">di</a><td>html
33 <td title="…B">monadic
34 <td title="A…B">dyadic
39 my ($chr, $dyad, $monad) = @{$op};
40 ($chr, my $altkey) = split /\n/, $chr;
41 my $codepoint = ord $chr;
42 my $ascii = $codepoint <= 127;
43 my $info = $glyphs->glyph_info($codepoint);
44 my ($class, $name, $mnem, $html, $string) = @{$info};
46 printf '<tr><th title="%2$s">%s', $chr, EscapeHTML($name || '?'), $class;
47 printf '<td class="%s">%s', @{$_} for (
48 [$ascii ? 'l5' : defined $altkey ? 'l4' : 'l3', $altkey],
49 [defined $mnem ? $class =~ /\bu-di\b/ ? 'l4' : 'l3' : $ascii ? 'l5' : 'l1',
50 EscapeHTML($mnem) // sprintf('%s%0*X', $codepoint < 256 ? (x => 2) : (u => 4), $codepoint)],
51 [defined $html ? 'l4' : $ascii ? 'l5' : 'l1', $html // "#$codepoint"],
54 defined $_ ? '<td%s>%s' : '<td class=Xi>',
55 map { !!$_->[1] && qq( title="$_->[1]"), $_->[0] }
56 [map { EscapeHTML($_) } split /\n/, $_, 2]
67 <table class="glyphs"><tr>
68 <td class="X l5">unicode 1.1
69 <td class="X l4">20th century
70 <td class="X l3">in 6.0 (2010)
71 <td class="X l2">recent assignments
72 <td class="X l1">proposed
73 <td class="ex">irregular