keyboard: custom rows overrides in moderows attribute
authorMischa POSLAWSKY <perl@shiar.org>
Fri, 15 Dec 2023 22:49:10 +0000 (23:49 +0100)
committerMischa POSLAWSKY <perl@shiar.org>
Tue, 19 Dec 2023 23:54:11 +0000 (00:54 +0100)
keyboard.plp
nethack.eng.inc.pl
nethack.plp
readline.eng.inc.pl
readline.plp

index ea62b5a5284a9bf4c13fb126493a8b3c04c2f5e1..8bbe8f7dcdbea9eec86eeb73d142ce3c914d4c98 100644 (file)
@@ -33,7 +33,7 @@ say "<h2>", $info->{mode}->{''}, " (default)</h2>"
 use Shiar_Sheet::Keyboard 2.08;
 my $keys = Shiar_Sheet::Keyboard->new($info);
 $keys->map($get{map}) or undef $get{map};
-$keys->print_rows($get{rows}, $info->{rows});
+$keys->print_rows($get{rows} || $info->{moderows}, $info->{rows});
 
 {
        say "<hr/>\n";
index ba24b9eee2e9d79f3b14df6fb1a580c2722f00a8..19aa7a3110579eebc69232af87efef3e8e6dc28c 100644 (file)
@@ -10,6 +10,7 @@ description => [
 intro => "Command bindings for version 3.6.1 of the vanilla NetHack game.",
 keywords => [qw' nethack rogue game controls '],
 rows => [3, 2, 1, 0],
+moderows => '4321-421',
 
 key => {
        'b' =>   "step left down\nnumpad 1",
index 474fa107d613b4539c65d12a4dc29d1054c89e55..81d9ee3f6f16f15261cd4dadb16ce51fed82834f 100644 (file)
@@ -1,4 +1,3 @@
 <:
 $Request = 'nethack';
-$get{rows} ||= '4321-421';
 Include 'keyboard.plp';
index 643c5de651ca9027fd054d0c25943a27bc992dcd..5e5b0cd18f32b98086ed5d55f0ba35bfd3afd68b 100644 (file)
@@ -9,6 +9,7 @@ description => [
 ],
 keywords => [qw( readline gnu bash emacs editing curses )],
 rows => [4, 3, 2],
+moderows => '^x=213',
 
 key => {
        '+<' => "history start",
index 0bb69d68fa6b9a038f80a23ae5f1335dcc865c63..62dd7fc6cc38ce80a9122c7d5738000526ae7379 100644 (file)
@@ -1,4 +1,3 @@
 <:
 $Request = 'readline';
-$get{rows} ||= '^x=213';
 Include 'keyboard.plp';