X-Git-Url: http://git.shiar.nl/sheet.git/blobdiff_plain/544153ced65dfca53ea9195c548db7bc0fa71d71..29b407ddf91b653e6e8380f73e221628a392376f:/keyboard.plp diff --git a/keyboard.plp b/keyboard.plp index 588aedc..ac9df32 100644 --- a/keyboard.plp +++ b/keyboard.plp @@ -1,28 +1,13 @@ <(common.inc.plp)><: - our $VERSION = 'v1.0'; - use Shiar_Sheet::KeySigns qw(%sign); - -:> - +Html({ + title => 'keyboard cheat sheet', + version => '1.0', + stylesheet => [qw'light dark circus mono red terse'], + keys => 1, +}); - - -keyboard cheat sheet -<:= stylesheet(qw'light dark circus mono red terse') :> - -<: - our $showkeys = exists $get{keys} && $get{keys} ne '0'; - print "\n".'' - unless $showkeys; - print "\n".'' - if $showkeys and $get{keys} eq 'ghost'; :> - - - -

keyboard cheat sheet

normal mode (default)

@@ -38,8 +23,9 @@ <: our %sign; -use Shiar_Sheet::Keyboard; +use Shiar_Sheet::Keyboard 2; my $usint = [ + [ 'a' .. 'z'], [qw(Á B ¢ Ð É F G H Í J Œ Ø µ Ñ Ó Ö Ä ® § Þ Ú V Å X Ü Æ)], [qw(á b © ð é f g h í j œ ø µ ñ ó ö ä ® ß þ ú v å x ü æ)], [qw(Å ı Ç ð ´ ̉ ˝ ̣ ˆ ½  Þ ¾ ˜ Ø ∏ Œ ‰ / ˇ ¨ ◊ „ ˛ ¼ ¸)], @@ -47,12 +33,17 @@ my $usint = [ ]; my $keys = Shiar_Sheet::Keyboard->new({ - '' => { + def => { + '' => { + map { $_ => [''] } @{ $usint->[0] } + }, + }, + key => { map { my $i = ord($_) - ord('a'); - $_ => ["$usint->[0]->[$i]
$usint->[1]->[$i]"] + $_ => ["$usint->[1]->[$i]
$usint->[2]->[$i]"] } 'a'..'z' - } + }, }); $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows}, [0]); @@ -89,9 +80,6 @@ $keys->print_rows($get{rows}, [0]);