X-Git-Url: http://git.shiar.nl/sheet.git/blobdiff_plain/68625510fc0fbda4ecf4739929570d985631a063..bfef771407d10c416bc87505623130f93a04a4be:/unicode.plp diff --git a/unicode.plp b/unicode.plp index b8e16f1..18ed2ce 100644 --- a/unicode.plp +++ b/unicode.plp @@ -2,6 +2,7 @@ use utf8; use strict; use warnings; +no warnings 'qw'; # that's not a comment, it's a NUMBER SIGN use open IO => ':utf8'; our $VERSION = '1.0'; @@ -31,20 +32,33 @@ tbody { h2, h3 { clear: both; } +h2 { + margin: 0 1ex; + font-size: 100%; +} th { text-align: left; font-size: 50%; background: #888; + background: #778; + background: #889; color: #FFF; padding: 0 0.2em; } +th, td { + border-color: #778; + border: 1px solid #888; +} thead td { border: 0; + background: transparent; +} +thead th { + text-align: center; } td { - background: transparent; vertical-align: top; margin: 0; padding: 0; @@ -57,23 +71,24 @@ small { small.digraph { background: #888; color: #FFF; + + background: #000; + color: #FFF; + opacity: 0.3; } small.value { background: #CCC; color: #666; -} -td.empty { - background: #DDD; -} -td.reserved { - background: #BBB; + background: #800; + color: #FFF; + opacity: 0.3; } -

Common Digraphs

+

Common uncommon Unicode

i^k in Vim. Also see the complete digraphs table.

@@ -108,16 +123,29 @@ sub table { $colspan++; next; } - elsif ($cell =~ s/^-//) { - $class = 'empty'; + + my $code = join '', map { $di{ord $_} || '' } split //, $cell; + my $name = $diinfo->{$code}->[1]; + + if ($cell =~ s/^-//) { +# $class = 'Empty'; } elsif ($cell eq '=') { - $class = 'reserved'; + $class = 'Reserved'; $cell = ''; } - - my $code = join '', map { $di{ord $_} || '' } split //, $cell; - my $name = $diinfo->{$code}->[1]; + elsif ($cell =~ /[ -~]/) { + $class = 'Ascii'; + } + elsif (not $code) { + $class = 'DiNone'; + } + elsif ($diinfo->{$code}->[2] =~ /\bXz\b/) { + $class = 'DiProp'; + } + else { + $class = 'Di'; + } $rows[-1] .= sprintf('%s%s', defined $name ? qq{ title="$name"} : '', @@ -135,7 +163,7 @@ sub table { if ($colheads) { unshift @rows, sprintf '%s', join '', - map { sprintf '%s', split(/:/, $_, 2) } + map { sprintf '%s', split(/:/, $_, 2), '', '' } @$colheads } @@ -153,30 +181,44 @@ print table(@$_) for ( print "

Arrows

\n\n"; print table(@$_) for ( [ 4 => [qw{. ↖ ↑ ↗ ↔ . ← - → ↕ . ↙ ↓ ↘ -}]], - [ 4 => [qw{. ⇖ ⇑ ⇗ ⇔ . ⇐ - ⇒ ⇕ . ⇘ ⇓ ⇙ -}]], + [ 4 => [qw{. ⇖ ⇑ ⇗ ⇔ . ⇐ - ⇒ ⇕ . ⇙ ⇓ ⇘ -}]], [ 3 => [qw{. ◤ ▲ ◥ . ◀ ◆ ▶ . ◣ ▼ ◢}]], [ 3 => [qw{. ◸ △ ◹ . ◁ ◇ ▷ . ◺ ▽ ◿}]], ); print "

Line drawing

\n\n"; print table(@$_) for ( - [ 4 => [qw{. ┌ ┬ ┐ ─ . ├ ┼ ┤ │ . └ ┴ ┘ -}]], - [ 4 => [qw{. ┏ ┳ ┓ ━ . ┣ ╋ ┫ ┃ . ┗ ┻ ┛ -}]], + [ 4 => [qw{. ┌ ┬ ┐ . ├ ┼ ┤ . └ ┴ ┘}]], + [ 4 => [qw{. ┏ ┳ ┓ . ┣ ╋ ┫ . ┗ ┻ ┛}]], [ 3 => [qw{. ┍ ┯ ┑ . ┝ ┿ ┥ . ┕ ┷ ┙}]], [ 3 => [qw{. ┎ ┰ ┒ . ┠ ╂ ┨ . ┖ ┸ ┚}]], -# [ 4 => [qw{. ╔ ╦ ╗ ═ . ╠ ╬ ╣ ║ . ╚ ╩ ╝ -}]], -# [ 3 => [qw{. ╒ ╤ ╕ . ╞ ╪ ╡ . ╘ ╧ ╛}]], -# [ 3 => [qw{. ╓ ╥ ╖ . ╟ ╫ ╢ . ╙ ╨ ╜}]], + [ 4 => [qw{ + . ╴ ─ ╌ ┄ ┈ ╶ ╾ + . ╸ ━ ╍ ┅ ┉ ╺ ╼ + . ╵ │ ╎ ┆ ┊ ╷ ╿ + . ╹ ┃ ╏ ┇ ┋ ╻ ╽ + }]], + [ 1 => [qw{. ╱ ╳ ╲ }]], + [ 4 => [qw{. ╔ ╦ ╗ ═ . ╠ ╬ ╣ ║ . ╚ ╩ ╝ - }]], + [ 3 => [qw{. ╒ ╤ ╕ . ╞ ╪ ╡ . ╘ ╧ ╛ }]], + [ 3 => [qw{. ╓ ╥ ╖ . ╟ ╫ ╢ . ╙ ╨ ╜ }]], ); -print "

Signs

\n\n"; +print "

Blocks

\n\n"; print table(@$_) for ( - [ 3 => [qw{. ▘ ▀ ▝ . ▌ █ ▐ . ▖ ▄ ▗ . ░ ▒ ▓}]], + [ 3 => [qw{. ▘ ▀ ▝ . ▌ █ ▐ . ▖ ▄ ▗ }]], + [ 3 => [qw{. ░ . ▒ . ▓ }]], + [ 2 => [qw{. ▛ ▚ ▟ . ▙ ▞ ▜ }]], + [ 2 => [qw{. ▁ ▂ ▃ ▄ ▅ ▆ ▇ ▔ . ▏ ▎ ▍ ▌ ▋ ▊ ▉ ▕ }]], [ 3 => [qw{. □ ▣ ■ . ▤ ▦ ▥ . ▧ ▩ ▨}]], - [ 4 => [qw{. ♠ ♡ ♢ ♣ . ♤ ♥ ♦ ♧}]], - [ 5 => [qw{. ☼ ☿ ♀ ♁ ♂ ♃ ♄ ♅ ♆ ♇}]], # solar -# [12 => [qw{. ♈ ♉ ♊ ♋ ♌ ♍ ♎ ♏ ♐ ♑ ♒ ♓}]], # zodiac +); + +print "

Signs

\n\n"; +print table(@$_) for ( [ 8 => [qw{. ¤ ¢ ₥ € £ ₨ $ ¥ . ₫ ₭ ₦ ₱ ₧ ₮ ₩ ₪}]], + [ 4 => [qw{. ♠ ♡ ♢ ♣ . ♤ ♥ ♦ ♧}]], + [ 5 => [qw{. ☉ ☿ ♀ ♁ ♂ ♃ ♄ ♅ ♆ ♇}]], # solar + [12 => [qw{. ♈ ♉ ♊ ♋ ♌ ♍ ♎ ♏ ♐ ♑ ♒ ♓}]], # zodiac ); print "

IPA

\n\n"; @@ -231,3 +273,75 @@ print table(@$_) for ( ], ); +print "

Japanese

\n\n"; +print table(@$_) for ( + [ + 1 => [qw{ + . あ い う え お = + . か き く け こ = + . さ し す せ そ = + . た ち つ て と = + . な に ぬ ね の ん + . は ひ ふ へ ほ = + . ま み む め も = + . や = ゆ = よ = + . ら り る れ ろ = + . わ ゐ = ゑ を = + }], + ['', qw{K S T N H M Y R W}], + [qw{A I U E O}, ''], + ], + [ + 1 => [qw{ + . が ぎ ぐ げ ご + . ざ じ ず ぜ ぞ + . だ ぢ づ で ど + . ば び ぶ べ ぼ + . ぱ ぴ ぷ ぺ ぽ + }], + [qw{G Z D B P}], + [qw{A I U E O}], + ], + [ + 1 => [qw{ + . ア イ ウ エ オ ー + . カ キ ク ケ コ = + . サ シ ス セ ソ = + . タ チ ツ テ ト = + . ナ ニ ヌ ネ ノ ン + . ハ ヒ フ ヘ ホ = + . マ ミ ム メ モ = + . ヤ - ユ - ヨ = + . ラ リ ル レ ロ = + . ワ ヰ - ヱ ヲ = + }], + ['', qw{K S T N H M Y R W}], + [qw{A I U E O}, ''], + ], + [ + 1 => [qw{ + . ガ ギ グ ゲ ゴ + . ザ ジ ズ ゼ ゾ + . ダ ヂ ヅ デ ド + . バ ビ ブ ベ ボ + . パ ピ プ ペ ポ + . ヷ ヸ ヴ ヹ ヺ + }], + [qw{G Z D B P V}], + [qw{A I U E O}], + ], +); + +:> + +