X-Git-Url: http://git.shiar.nl/sheet.git/blobdiff_plain/d41fb64d4655e00ef12972ae3eda386e53446594..21a93def2665aa147da1a9acd03b644e59b74f5c:/latin.plp?ds=sidebyside
diff --git a/latin.plp b/latin.plp
index 89afb61..578d858 100644
--- a/latin.plp
+++ b/latin.plp
@@ -2,39 +2,121 @@
Html({
title => 'latin alphabet cheat sheet',
- version => 'v1.0',
+ version => '1.7',
description => [
],
keywords => [qw'
latin roman alphabet script letter unicode font glyph abc
- writing comparison character sample test language
+ code encoding spelling symbol writing comparison character
+ secret cursive fraktur blind braille morse deaf asl hand
+ barcode bar color semaphore flag
'],
- stylesheet => [qw'light dark red'],
+ stylesheet => [qw( light dark red mono )],
+ data => ['writing-latn.inc.pl'],
});
:>
-
Latin alphabet
+
-Also see other alphabets
-and common chars.
+Latin alphabet
-
+
Variant encodings of the common ASCII (latin, roman,
+or 'mercan) letters AâZ.
+Also see related alphabets
+and font comparison.
<:
-use Shiar_Sheet::FormatChar;
-my $glyphs = Shiar_Sheet::FormatChar->new;
-unless (exists $get{v}) {
- $glyphs->{unicode}--;
- $glyphs->{digraph}--;
+my $table = Data('writing-latn');
+{
+ say '
';
+ say '\n";
}
-my @t = (qw{
- .>Latin a b c d e f g h i j k l m n o p q r s t u v w x y z
- .>Braille â â â â â â â â â â â
â â â â â â â â â â ¥ â § â º â â ½ â µ
- .>Morse â§â ââ§â§â§ ââ§â⧠ââ§â§ ⧠â§â§â⧠ââ⧠â§â§â§â§ â§â§ â§âââ ââ§â â§ââ§â§ ââ
- â⧠âââ â§ââ⧠âââ§â â§â⧠â§â§â§ â â§â§â â§â§â§â â§ââ ââ§â§â ââ§ââ âââ§â§
-});
-print $glyphs->table(exists $get{uc} ? [map {s/\s.//; uc} @t] : \@t);
+my %VOWELCOLS = (map { ($_ => 1) } 0, 4, 8, 14, 20, 24);
+say '
';
+say '';
+printtr('order');
+say '';
+printtr('default');
+say "
";
+
+sub printtr {
+ for my $id (@_) {
+ my $info = $table->{$id};
+
+ if (ref $info eq 'ARRAY') {
+ printtr(@{$info});
+ next;
+ }
-print "
\n";
+ printf '', $id;
+ my $th = 'th';
+ $th .= sprintf ' title="%s"', $_ for $info->{title} || ();
+ say "<$th>", $info->{name} // ucfirst $id;
+
+ my $colspan = 1;
+ my $col = 0;
+ for (@{ $info->{list} }) {
+ $col++;
+ if ($_ eq '>') {
+ $colspan++;
+ next;
+ }
+ my @class;
+ push @class ,'l0' if $VOWELCOLS{$col - $colspan};
+ push @class, $_ ? 'ex' : 'u-invalid' if s/^-//;
+
+ print "\t 26) {
+ # special character for sample generation
+ print ' hidden'; # sample only
+ }
+ else {
+ print ' title=', chr($col + ord('A') - $colspan);
+ }
+ if ($colspan > 1) {
+ print " colspan=$colspan";
+ $colspan = 1;
+ }
+ printf ' class="%s"', "@class" if @class;
+ print '>';
+ say;
+ }
+ }
+}
+
+:>
+
+
|