From: Mischa POSLAWSKY Date: Fri, 15 Mar 2024 22:47:22 +0000 (+0100) Subject: keyboard/altgr/weur: dweurak reimplementation for dvorak map X-Git-Tag: v1.19~33 X-Git-Url: http://git.shiar.net/sheet.git/commitdiff_plain/015b61ff202c1aadc5123850059aa14be0120637?hp=9161aea80d5aa138281ec4fbcc6f0434739d7866 keyboard/altgr/weur: dweurak reimplementation for dvorak map Replace random results from qwerty positioning by a complete reorder where accents can consistently repeat the aoeui vowels, with consonants (including ß) still at base letters, and remaining dead keys clustered neatly at the top right. Seriously wondering if this was the original layout as it all fits so much better. --- diff --git a/keyboard/altgr/weur.eng.inc.pl b/keyboard/altgr/weur.eng.inc.pl index 6ef09eb..c3b3516 100644 --- a/keyboard/altgr/weur.eng.inc.pl +++ b/keyboard/altgr/weur.eng.inc.pl @@ -1,6 +1,7 @@ use utf8; use strict; use warnings; +no warnings 'qw'; use Shiar_Sheet::KeyboardChars 'kbmodes'; my %rows = ( @@ -154,6 +155,23 @@ my %rows = ( }, ); +our %get; +my $dweur = $get{map} && $get{map} eq 'dvorak'; +if ($dweur) { + my $dq = q{ + 'z ,l .d pj yk fq gt r, l' + dv hb s8 tw 8. + ;s qp jr ky xm bx m; wf vh zg + }; + my %dq = split //, $dq =~ s/\s//gr; # dvorak => qwerty key + + my %uc = (qw{ ' " , < . > ; : - _ 8 * }, map {lc, uc} 'a'..'z'); + $dq{ $uc{$_} } = $uc{ $dq{$_} } for keys %dq; # same shifted + + @{ $rows{''} }{keys %dq} = map { $rows{''}{$_} } values %dq; + $rows{S} = delete $rows{'*'}; +} + +{ %{ kbmodes(\%rows) }, mode => { @@ -161,7 +179,7 @@ my %rows = ( '*' => 'greek mode ⌥*', }, version => '1.0', # upstream v2.0 2021/04/12 - title => 'Western European', + title => $dweur ? 'dWEURak' : 'Western European', category => 'latin/thirdparty/xorg', intro => join("\n", 'Layout (available for major OSes)',