X-Git-Url: http://git.shiar.nl/sheet.git/blobdiff_plain/aeb47e7600bf4e34a37f3ebfe0e6edc534d92147..HEAD:/writing.plp diff --git a/writing.plp b/writing.plp index 5c7c982..dfd78a4 100644 --- a/writing.plp +++ b/writing.plp @@ -1,32 +1,32 @@ <(common.inc.plp)><: +my $source = lc $Request || 'phnx'; +$source =~ s/^brah\Kmi$//; +my $include = "writing-$source"; + +my $info = eval { Data($include) } || {}; + Html({ - title => 'writing system inheritance sheet', - version => 'v1.1', - description => [ - "Character comparison,", - "tracking letters as they evolve from Phoenician to modern scripts.", - "Good Unicode test sample.", - ], - keywords => [qw' - script glyph unicode writing comparison character alphabet letter - history phoenician latin sample test language multilingual - '], - stylesheet => [qw'light circus dark red'], - data => [qw'writing-phnx.inc.pl'], + title => $info->{pagetitle} || "$info->{title} scripts comparison sheet", + version => $info->{version} || '0.1', + description => $info->{description}, + keywords => [@{ $info->{keywords} // []}, qw( + writing script glyph unicode character letter comparison history + alphabet sample test language multilingual + )], + stylesheet => [qw'light circus dark red mono'], + data => ["$include.inc.pl"], }); -:> -

Writing systems

- -

-Comparison of Unicode letters in related alphabets. -Also see charsets -and common chars.

+my $rows = $info->{list} or Abort( + "Requested script parent $source not available", + '404 request not found', +); -
+say "

\u$info->{title} scripts

"; +say "

$_

" for $info->{intro} || (); +say '
'; -<: use Shiar_Sheet::FormatChar; my $glyphs = Shiar_Sheet::FormatChar->new; unless (exists $get{v}) { @@ -35,39 +35,19 @@ unless (exists $get{v}) { $glyphs->{style} = 'univer'; } -my $scriptname = do 'writing-script.inc.pl'; -$_ = qq{$_} for $scriptname->{latn} || (); - -for ( - [phnx => 'Phoenician'], - [brah => 'Brahmi'], -) { - my ($source, $title) = @$_; - my @table = do "writing-$source.inc.pl"; - if ($! or $@) { - print "

$title

\n"; - printf "

Table data not found: %s.

\n", $@ || $!; - next; - } - $glyphs->print($title => [map { - my $lead = s/^(-)// && $1; - ref $_ eq 'ARRAY' ? @$_ : map { ".>$lead$_" } - $scriptname->{$source.'_'.$_} || $scriptname->{$_} || $_ - } @table]); -} +my $scriptname = eval { Data('writing-script') }; # optional translations +$_ = showlink($_, "/latin") for $scriptname->{latn} || (); +$_ = showlink($_, "/writing/brahmi") for $scriptname->{brah} || (); -:>
+say $glyphs->table([map { + my $lead = s/^(-)// && $1; + (map { ".>$lead$_" } + $scriptname->{$source.'_'.$_} || $scriptname->{$_} || $_ + ), + @{ $info->{table}->{$_} || [] } +} @{$rows}]); -
+say "
\n"; -
- -
unicode 1.1 - 20th century - in 6.0 (2010) - recent assignments - proposed - irregular -
-
+say for '
', $glyphs->legend;