X-Git-Url: http://git.shiar.nl/sheet.git/blobdiff_plain/fca88ab2c458a7ae367bfede7d2ddce2e0458f97..25c42c7d1649e85339b165f205e620b8eadf6e7b:/Shiar_Sheet/Keyboard.pm diff --git a/Shiar_Sheet/Keyboard.pm b/Shiar_Sheet/Keyboard.pm index 6908ce9..bf25477 100644 --- a/Shiar_Sheet/Keyboard.pm +++ b/Shiar_Sheet/Keyboard.pm @@ -6,7 +6,7 @@ use warnings; no warnings 'uninitialized'; # save some useless checks for more legible code use Carp; -our $VERSION = '2.08'; +our $VERSION = '2.09'; my @casedesc = (undef, qw/shift ctrl meta/, 'shift meta'); my @rowdesc = qw(numeric top home bottom); @@ -167,8 +167,8 @@ print_row: for my $submode (@moderows ? @moderows : '') { my $mode = $basemode . $submode; - my @caserows = $mode =~ s/(\d+)(?:-(\d+))?$// - ? (map {$_ - 1} split //, $row == 0 && $2 || $1) # user override + my @caserows = $mode =~ s/(\d+)(?:-(\d*))?$// + ? (map {$_ - 1} split //, $row == 0 ? $2 // $1 : $1) # user override : @$defrows; # default my $modekeys = $self->{def}{$mode}; @@ -206,44 +206,12 @@ sub print_legend { my ($class, $flags) = @_; say qq{\t\t