latin: format tap code with multiline bullets
[sheet.git] / latin.plp
1 <(common.inc.plp)><:
2
3 Html({
4         title => 'latin alphabet cheat sheet',
5         version => 'v1.1',
6         description => [
7         ],
8         keywords => [qw'
9                 latin roman alphabet script letter unicode font glyph abc
10                 writing comparison character sample test language spelling
11                 cursive fraktur blind deaf
12         '],
13         stylesheet => [qw'light dark red'],
14         data => ['writing-latn.inc.pl'],
15 });
16
17 :>
18 <style>
19         @font-face {
20                 font-family: Suetterlin; /* R. G. Arens */
21                 src: url("/suetterlin.ttf");
22         }
23         .glyphs tr:first-child+tr td { font-family: Suetterlin }
24 </style>
25
26 <h1>Latin alphabet</h1>
27
28 <p>Also see <a href="/writing">other alphabets</a>
29 and <a href="/unicode">common chars</a>.</p>
30
31 <div class="-diinfo">
32
33 <:
34 use Shiar_Sheet::FormatChar;
35 my $glyphs = Shiar_Sheet::FormatChar->new;
36 unless (exists $get{v}) {
37         $glyphs->{unicode}--;
38         $glyphs->{anno}  = [];
39         $glyphs->{style} = 0;
40 }
41
42 my %scriptname = (
43         latn     => 'Latin',
44         latfsuet => 'Sütterlin',
45         asl      => '<abbr title="American Sign Lanugage">ASL</abbr>', # American manual alphabet
46         brai     => 'Braille',
47         morse    => 'Morse',
48         tap      => 'Tap code',
49         ics      => 'Maritime flags', # International Code of Signals
50 );
51
52 my @table = do 'writing-latn.inc.pl';
53 if ($! or $@) {
54         printf "<p class=error>Table data not found: <em>%s</em>.</p>\n", $@ || $!;
55 }
56 else {
57         print $glyphs->table([map {
58                 ref $_ ne 'ARRAY' ? ".>$scriptname{$_}"
59                         : exists $get{uc} ? map {uc} @$_ : @$_
60         } @table]);
61 }
62
63 print "</div>\n";
64