4 title => 'unicode glyph cheat sheet',
7 "Common Unicode characters with digraph or code point, layed out for quick location.",
8 "Includes general symbols, arrows, drawing characters, and IPA letters.",
11 unicode glyph char character reference common ipa symbol sign mark table digraph
13 data => [qw( unicode-table.inc.pl data/unicode-char.inc.pl )],
17 <h1>Common Unicode</h1>
20 Glyphs are followed by
21 <a href="/digraphs">digraph</a> or <a href="/charset">code point</a>,
22 i^k or i^vu respectively in <a href="/vi">Vim</a>.
28 use Shiar_Sheet::FormatChar;
29 my $glyphs = Shiar_Sheet::FormatChar->new;
31 if (exists $get{di}) {
32 $glyphs->{anno} = [ (!defined $get{di} || $get{di}) && 'di', 'hex' ];
37 if (exists $get{html}) {
38 $glyphs->{anno} = ['html', 'xml'];
39 $glyphs->{style} = 'html';
42 our $verbose = exists $get{v};
48 symbols/binary?symbols/binary=-5
123 splice @config, 4, 2, qw(
124 latin/vowels=-5?latin/vowels
127 ) if exists $get{html};
129 $_ and m{/*+(.+)} and @config = split /[ ]/, $1 for $Request, $get{q};
131 my $tables = Data('unicode-table');
134 $_ = /(.*)\?(.*)/ ? ($verbose ? $2 : $1) : $_;
144 $group = $1 if s{^([^/]+)/}{};
145 my @select = s/=(.*)// ? split(/=/, $1) : ();
146 my $table = $tables->{$group}->{$_}
147 or Abort("Unknown table specified: $group/$_", 404);
151 for ($rowlen = 1; $rowlen <= $#$table; $rowlen++) {
152 last if $table->[$rowlen] =~ /\./;
156 my $end = (s/-(.+)?// ? ($1 // @$table / $rowlen - 1) : $_) + 1;
157 $_ * $rowlen .. $end * $rowlen - 1;
159 $table = [ @$table[@cells] ];
167 say for $glyphs->legend;
170 <script type="text/javascript" src="/clipboard.js"></script>