From 368b9f0f191ea7186e4dc1d5522a137721861c3d Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Sun, 12 Jun 2011 18:10:12 +0200 Subject: [PATCH 01/16] unicode: change preliminary characters to unicode 6.0 specs Incorrect characters were based on earlier emoji proposal. --- unicode-table.inc.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/unicode-table.inc.pl b/unicode-table.inc.pl index d6302ef..75a21d6 100644 --- a/unicode-table.inc.pl +++ b/unicode-table.inc.pl @@ -26,10 +26,10 @@ symbols => { signs1 => [qw{. ☮ ☯ ☻ ♪ ♲ ♿ }], signs2 => [qw{. ⚠ ☡ ☠}], communic => [ # note, mail, fax, phone, alt phone - qw{. ✂ ✉ ℻ ☎ ☏ }, # scissors, envelope, fax sign, black phone, white phone - qw{. 🔞 🔾 🔰 📞 🕀 }, # paperclip, postal horn, fax machine, receiver, cell + qw{. ✂ ✉ ℻ ☎ 📱 }, # scissors, envelope, fax sign, black phone, mobile + qw{. 📎 📯 📠 ☏ 📞 }, # paperclip, postal horn, fax machine, white phone, receiver ], - trinity => [qw{. ✊ ✋ ✌ . 🖹 🐜 👼 }], # rock, paper, scissors; terran, protoss, zerg + trinity => [qw{. ✊ ✋ ✌ . 🚹 🐜 👽 }], # rock, paper, scissors; terran, protoss, zerg solar => [qw{. ☉ ☿ ♀ ♁ ♂ ♃ ♄ ♅ ♆ ♇}], # sun, mercury-neptune, pluto zodiac => [ qw{. ♈ ♉ ♊ ♋ ♌ ♍ ♎ ♏ ♐ ♑ ♒ ♓ }, # western signs -- 2.30.0 From 9dd8c658b3eba9db9586ce17ea4c8437878ddd42 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Sat, 18 Jun 2011 17:28:00 +0200 Subject: [PATCH 02/16] unicode: add corresponding elements to 4 card faces Other 4-way distinctions using Tarot associations according to Wikipedia. --- unicode-table.inc.pl | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/unicode-table.inc.pl b/unicode-table.inc.pl index 75a21d6..189f58f 100644 --- a/unicode-table.inc.pl +++ b/unicode-table.inc.pl @@ -21,7 +21,15 @@ punctuation => { symbols => { binary => [qw{. ⚋ ⚊ . ⚐ ⚑ . ☺ ☹ . ✓ ✗ . ✔ ✘ . ◄ ► }], # opposites currency => [qw{. ¤ ¢ ₥ € £ ₨ $ ¥ . ฿ ₫ ₭ ₦ ₱ ₮ ₩ ₪}], - cards => [qw{. ♠ ♡ ♢ ♣ . ♤ ♥ ♦ ♧}], + cards => [ + qw{. ♢ ♡ ♠ ♣ . ♦ ♥ ♤ ♧ }, # diamonds, hearts, clubs, spades +# qw{. 🔔 ❀ -⛨ 🌰 }, # bells, roses, shields, acorns +# qw{. ⚚ ⚘ ⚔ ⚒ }, # merchant, clergy, nobility, peasant +# qw{. ❂ 🏆 ⚔ -🔧 }, # coins, cups, swords, clubs + qw{. ▽̶ ▽ △ △̶ }, # earth, water, fire, air + qw{. ☷ ☵ ☲ ☰ }, # earth, water, fire, heaven [cq ☴ wind] + qw{. 土 水 火 金 }, # earth, water, fire, metal + ], chess => [qw{. ♙ ♘ ♗ ♖ ♕ ♔ . ♟ ♞ ♝ ♜ ♛ ♚ }], signs1 => [qw{. ☮ ☯ ☻ ♪ ♲ ♿ }], signs2 => [qw{. ⚠ ☡ ☠}], -- 2.30.0 From cd1e050ccb93de242063df29c3a7cff72e46ce96 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 4 Jul 2011 16:31:04 +0200 Subject: [PATCH 03/16] unicode: replace generic Rs by indian rupee sign Introduced in Unicode 6.0. --- unicode-table.inc.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/unicode-table.inc.pl b/unicode-table.inc.pl index 189f58f..0887b17 100644 --- a/unicode-table.inc.pl +++ b/unicode-table.inc.pl @@ -20,7 +20,7 @@ punctuation => { symbols => { binary => [qw{. ⚋ ⚊ . ⚐ ⚑ . ☺ ☹ . ✓ ✗ . ✔ ✘ . ◄ ► }], # opposites - currency => [qw{. ¤ ¢ ₥ € £ ₨ $ ¥ . ฿ ₫ ₭ ₦ ₱ ₮ ₩ ₪}], + currency => [qw{. ¤ ¢ ₥ € £ ₹ $ ¥ . ฿ ₫ ₭ ₦ ₱ ₮ ₩ ₪}], cards => [ qw{. ♢ ♡ ♠ ♣ . ♦ ♥ ♤ ♧ }, # diamonds, hearts, clubs, spades # qw{. 🔔 ❀ -⛨ 🌰 }, # bells, roses, shields, acorns -- 2.30.0 From 3fe6c0047c4c1fb1fa8698d9cf0fc8823dc1a710 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 4 Jul 2011 16:36:58 +0200 Subject: [PATCH 04/16] unicode: hide chinese element characters by default Introduced in commit v1.4-50-g9dd8c658b3eb (2011-06-18) [unicode: add corresponding elements to 4 card faces]; Maybe interesting to Avatar fans, but not really generic symbols. --- unicode.plp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/unicode.plp b/unicode.plp index 7a70b27..69d6979 100644 --- a/unicode.plp +++ b/unicode.plp @@ -56,7 +56,7 @@ my @config = qw( spacing Symbols symbols/currency - cards + cards=-3?cards ?chess signs1 communic=0?communic -- 2.30.0 From 61b9cf825da723f6ffac7dae46404291603b1cdd Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 26 Mar 2012 16:38:13 +0200 Subject: [PATCH 05/16] screen: keyboard page for screen(1) commands Data already prepared in commit v1.2-19-g1441526bea (2009-04-22) [screen: draft default control commands]. --- screen.plp | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 screen.plp diff --git a/screen.plp b/screen.plp new file mode 100644 index 0000000..a99dc98 --- /dev/null +++ b/screen.plp @@ -0,0 +1,63 @@ +<(common.inc.plp)><: + +Html({ + title => 'screen cheat sheet', + version => 'v1.0', + description => [ + "Interactive cheat sheet for the Screen terminal manager,", + "describing the function of each key.", + ], + keywords => [qw' + screen sheet cheat reference overview commands keyboard + terminal window manager + '], + charset => $sign{charset}, + stylesheet => [qw'light dark circus mono red terse'], + keys => 1, +}); + +:> +

Screen cheat sheet

+ +

normal mode (default)

+ +
    + +<: +use Shiar_Sheet::Keyboard 2; +my $info = do 'screen.inc.pl' or die $! // $@; +my $keys = Shiar_Sheet::Keyboard->new($info); +$keys->map($get{map}) or undef $get{map}; +$keys->print_rows($get{rows}); +:> +
+ +
+ +
+
+<: + $keys->print_legend('legend-types', [map { "g$_" } 0 .. 8]); +:> +
+ +
+<: + $keys->print_legend('legend-options', [qw'arg']); +:> + +
    +
  • keyboard map is + <:= $get{map} ? 'set to ' : '' :><:= $keys->{map} :> +
  • ascii mode is + <:= defined $sign{-ascii} && 'forced ' :><:= + $sign{-ascii} ? 'on' : 'off' :> +
  • keys are + <:= $showkeys ? 'always shown' : 'hidden if unassigned' :><:= + !defined $showkeys && ' by default' :> +
  • default style is + <:= defined $get{style} && 'set to ' :><:= $style :> +
+
+
+ -- 2.30.0 From 959984aabc5adb85b5b85d08ff7b247442075399 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 25 Apr 2011 01:39:40 +0200 Subject: [PATCH 06/16] index: link to sc page --- index.plp | 1 + 1 file changed, 1 insertion(+) diff --git a/index.plp b/index.plp index a81aadd..1aaf0f6 100644 --- a/index.plp +++ b/index.plp @@ -53,6 +53,7 @@ but you're free to use, print, alter, and redistribute under the AGPL license.
  • browser support
  • country codes
  • terminal colours +
  • starcraft units
  • emoticons -- 2.30.0 From 5e459bbed48de06b1896f0ea685707a9ed66125a Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 26 Mar 2012 16:15:52 +0200 Subject: [PATCH 07/16] keyboard: resupport key texts after definition flags --- Shiar_Sheet/Keyboard.pm | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/Shiar_Sheet/Keyboard.pm b/Shiar_Sheet/Keyboard.pm index 936b811..c5ab016 100644 --- a/Shiar_Sheet/Keyboard.pm +++ b/Shiar_Sheet/Keyboard.pm @@ -84,18 +84,15 @@ sub print_key { my $self = shift; my ($mode, $key, $flags) = @_; - my $txt = $self->{key}->{$mode.$key}; - my ($desc, $mnem) = defined $txt ? @$txt : (); - if (not defined $flags) { - $flags = $key eq '^0' ? 'ni' : 'no'; + $flags = [$key eq '^0' ? 'ni' : 'no']; } elsif (not ref $flags) { # alias - $desc = $self->{sign}->{alias} . $flags; - $flags = $self->keyunalias($flags) . ' alias'; + $flags = [$self->keyunalias($flags) . ' alias', $self->{sign}->{alias} . $flags]; } - else { - $flags = $flags->[0]; + my ($flags, $desc, $mnem) = @{$flags}; + if (my $txt = $self->{key}->{$mode.$key}) { + ($desc, $mnem) = @{$txt}; } # $key = $keytrans{$key} if defined $keytrans{$key}; -- 2.30.0 From 7ed94883ec44ad8b4c7e19e9c37546beb69a3b4c Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 4 Jul 2011 15:48:38 +0200 Subject: [PATCH 08/16] style: generic rule in addition to gecko-specific column-width --- base.css | 1 + 1 file changed, 1 insertion(+) diff --git a/base.css b/base.css index d223cb3..fcf1e55 100644 --- a/base.css +++ b/base.css @@ -263,6 +263,7 @@ table.dimap { .diinfo { -moz-column-width: 24em; + column-width: 24em; } .diinfo > div { overflow: hidden; -- 2.30.0 From 951704ee0b51dc9f7b550d449fc6e9b121ce79a9 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Tue, 29 Mar 2011 21:21:56 +0200 Subject: [PATCH 09/16] style/circus: browser column hover --- circus.css | 2 ++ 1 file changed, 2 insertions(+) diff --git a/circus.css b/circus.css index 9cf1bbc..19d5336 100644 --- a/circus.css +++ b/circus.css @@ -21,6 +21,8 @@ .ex { color: #D00} .legend .ex:hover { background: #000} +#browser tr:hover > td:first-of-type { background: #FFF } + .p:hover::after {color: #F00} .Co {background: #DBB} /* private */ -- 2.30.0 From 334b91188c1c1f51bac85114cda18f5359a22af9 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 17 Oct 2011 16:54:42 +0200 Subject: [PATCH 10/16] unicode: add nintendo/generic console buttons --- unicode-table.inc.pl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/unicode-table.inc.pl b/unicode-table.inc.pl index 0887b17..d440d6b 100644 --- a/unicode-table.inc.pl +++ b/unicode-table.inc.pl @@ -55,7 +55,8 @@ keys => { command => [qw{. ↵ ⎋ ⎉ ⎊ }], # enter, esc, pause, break player => [qw{. ► ⏩ ⏭ ◼ ⚫ . ◄ ⏪ ⏮ ⏏ -❚❚ }], # play, fast, skip, stop, record android => [qw{. ⌂ ◰ ↩ 🔍 }], # home, menu, back, search - ps => [qw{. △ ○ ☓ □ }], # triangle, circle, cross, square + ps => [qw{. ☓ □ △ ○ }], # triangle, circle, cross, square + gamepad => [qw{. Ⓐ Ⓑ ◭ ◮ }], # A, B, L1, R1 }, math => { -- 2.30.0 From 187eda5dee6925d727287300c48472a86333aab9 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 4 Jul 2011 16:55:46 +0200 Subject: [PATCH 11/16] unicode: zodiac row visibility --- unicode.plp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/unicode.plp b/unicode.plp index 69d6979..92f9a01 100644 --- a/unicode.plp +++ b/unicode.plp @@ -64,7 +64,7 @@ my @config = qw( signs2 Signs solar - zodiac=0?zodiac + zodiac=0-1=3?zodiac Key_commands keys/spacing editing -- 2.30.0 From 5fadf3bba74628ae85920b5c2d71f804e3256601 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Sun, 24 Apr 2011 17:29:23 +0200 Subject: [PATCH 12/16] font: include math/logic by default --- font.plp | 1 + 1 file changed, 1 insertion(+) diff --git a/font.plp b/font.plp index 1e1732b..95630b2 100644 --- a/font.plp +++ b/font.plp @@ -54,6 +54,7 @@ my @config = qw( punctuation/common punctuation/marks latin/sample symbols/signs1 + math/logic ); $_ and m{/*+(.+)} and @config = split /[ ]/, $1 for $ENV{PATH_INFO}, $get{q}; @config = qw(ipa/cons ipa/vowels) if 0; -- 2.30.0 From 6d38d53c6cacbb5dabe6dc663c500d8ef8bb62d0 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 26 Mar 2012 17:30:05 +0200 Subject: [PATCH 13/16] keys: replace omni-present escape keys Instead of hardcoding the esc key in html, implement it as a standard row. --- Shiar_Sheet/Keyboard.pm | 2 +- less.inc.pl | 6 ++++++ less.plp | 23 -------------------- mplayer.inc.pl | 1 + mplayer.plp | 7 ------ mutt.inc.pl | 4 ++++ mutt.plp | 7 ------ nethack.plp | 9 ++------ readline.plp | 6 ------ vi.eng.inc.pl | 25 +++++++++++----------- vi.inc.pl | 47 ++++++++++++++++++++++++++++++----------- vimperator.plp | 9 ++------ 12 files changed, 64 insertions(+), 82 deletions(-) diff --git a/Shiar_Sheet/Keyboard.pm b/Shiar_Sheet/Keyboard.pm index c5ab016..2cbaffe 100644 --- a/Shiar_Sheet/Keyboard.pm +++ b/Shiar_Sheet/Keyboard.pm @@ -128,7 +128,7 @@ sub print_rows { my $keyrow = $row < 0 ? [["\e"]] : $keyrows{$self->{map}}->[$row]; printf qq{
    • \n}, $row+1; - for my $basemode ($row < 0 ? '' : @modes) { + for my $basemode (@modes) { my @moderows = split /\s+/, defined $moderows{$basemode} ? $moderows{$basemode} : $moderows{-DEFAULT}; diff --git a/less.inc.pl b/less.inc.pl index dcd6512..0fdedf6 100644 --- a/less.inc.pl +++ b/less.inc.pl @@ -2,6 +2,8 @@ use utf8; { # less v418 '' => { + "\e"=> ['mo mode^[', "alt$sign{_}/meta"], + 'b' => ['pm more'], '^b'=> 'b', 'd' => ['pm more'], @@ -65,6 +67,7 @@ use utf8; }, '^[' => { # esc + "\e"=> ['mo mode', 'noop'], 'n' => ['co'], 'N' => ['co'], 'u' => ['ci'], @@ -76,11 +79,13 @@ use utf8; }, #'^x' => { +# "\e"=> ['mo mode', 'noop'], # '^x' => "'", # '^v' => ':e', #}, ':' => { + "\e"=> ['mo mode', 'noop'], 'd' => ['mo'], 'e' => ['mo'], 'f' => '=', @@ -92,6 +97,7 @@ use utf8; }, '-' => { + "\e"=> ['mo mode', 'noop'], 'a' => ['co'], 'b' => ['mo arg'], 'B' => ['mo'], diff --git a/less.plp b/less.plp index 52ca471..b363203 100644 --- a/less.plp +++ b/less.plp @@ -23,29 +23,6 @@ Html({
        -
        • -
        • -
            -
          • Esc alt<:=$sign{_}:>/meta -
          -
        • -
            -
          • Esc noop -
          -
        • -
            -
          • Esc noop -
          -
        • -
            -
          • Esc noop -
          -
        • -
            -
          • Esc noop -
          -
        - <: use Shiar_Sheet::Keyboard 2; my $info = do 'less.eng.inc.pl' or die $@; diff --git a/mplayer.inc.pl b/mplayer.inc.pl index f0874e0..e07b78c 100644 --- a/mplayer.inc.pl +++ b/mplayer.inc.pl @@ -2,6 +2,7 @@ use utf8; { '' => { + "\e"=> 'q', '[' => ['mo'], ']' => ['mo'], '{' => ['mo'], diff --git a/mplayer.plp b/mplayer.plp index ef31e6b..689ee84 100644 --- a/mplayer.plp +++ b/mplayer.plp @@ -22,13 +22,6 @@ Html({
          -
        • -
            -
          • Esc q - -
          -
        • - <: use Shiar_Sheet::Keyboard 2; my $info = do 'mplayer.eng.inc.pl' or die $@; diff --git a/mutt.inc.pl b/mutt.inc.pl index 21ca05b..90185c9 100644 --- a/mutt.inc.pl +++ b/mutt.inc.pl @@ -1,6 +1,8 @@ use utf8; my %common = ( + "\e"=> ['me mode', '+'], + 'H' => ['pm'], # top-page 'j' => ['pm'], # next-entry, next-undeleted 'k' => ['pm'], # previous-entry, previous-undeleted @@ -151,6 +153,7 @@ my %common = ( }, # compose w => { + "\e"=> ['me mode', '+'], 'D' => ['co'], 'd' => 'wD', 'N' => ['co'], @@ -164,6 +167,7 @@ w => { }, # flag '/~' => { + "\e"=> ['me mode', '+'], A => [undef], b => ['X arg'], B => ['arg'], diff --git a/mutt.plp b/mutt.plp index f3909fe..3ce3d02 100644 --- a/mutt.plp +++ b/mutt.plp @@ -22,13 +22,6 @@ Html({
            -
          • -
              -
            • Esc + - -
            -
          • - <: use Shiar_Sheet::Keyboard 2; my $info = do 'mutt.eng.inc.pl' or die $@; diff --git a/nethack.plp b/nethack.plp index 3115e28..7e46c37 100644 --- a/nethack.plp +++ b/nethack.plp @@ -22,18 +22,13 @@ Html({
              -
            • -
                -
              • Esc - -
              -
            • - <: use Shiar_Sheet::Keyboard 2; my $info = do 'nethack.eng.inc.pl' or die $@; $info->{def} = do 'nethack.inc.pl'; my $keys = Shiar_Sheet::Keyboard->new($info); +$_->{"\e"} = ['me mode'] for values %{ $info->{def} }; + # static reset button, even though it's not (officially) in the game $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows} || '4321-421', [3,2,1,0]); :> diff --git a/readline.plp b/readline.plp index a7be846..6d8c499 100644 --- a/readline.plp +++ b/readline.plp @@ -22,12 +22,6 @@ Html({
                -
              • -
                  -
                • Esc + -
                -
              • - <: use Shiar_Sheet::Keyboard 2; my $info = do 'readline.eng.inc.pl' or die $@; diff --git a/vi.eng.inc.pl b/vi.eng.inc.pl index e4f99e6..a4c1d7e 100644 --- a/vi.eng.inc.pl +++ b/vi.eng.inc.pl @@ -127,7 +127,7 @@ key => { 'g8' => ["char hex val$sign{_}ue$sign{_}s"], 'g0' => ["virtual bol"], 'g-' => ["earlier undo"], -'g^['=> ["esc"], +"g\e"=> ["normal mode"], 'g]' => ["go to tselect"], 'g^]'=> ["go to tjump"], 'g;' => ["to prev change pos"], @@ -172,7 +172,7 @@ key => { 'gw' => ["for$sign{_}mat still"], 'gx' => ["Netrw$sign{_}BrowseX"], -'Z^['=> ["esc"], +"Z\e"=> ["normal mode"], 'ZQ' => [" :q! (force)"], 'ZZ' => [" :wq (write)"], @@ -181,7 +181,7 @@ key => { 'z-' => ["line at bottom bol", "don't (-) see any further"], 'z=' => ["sug$sign{_}gest spell$sign{_}ing"], 'z.' => ["line at center bol"], -'z^['=> ["esc"], +"z\e"=> ["normal mode"], 'za' => ["toggle fold"], 'zA' => ["toggle fold rec$sign{_}urs$sign{_}ive$sign{_}ly"], @@ -228,7 +228,7 @@ key => { '[/' => ["start of C com$sign{_}m$sign{_}ent"], '[{' => ["previous open {"], '[[' => ["section back$sign{_}ward$sign{_}s"], -'[^['=> ["esc"], +"[\e"=> ["normal mode"], '[]' => [qq'section back$sign{_}ward$sign{_}s'], '[c' => ["start of change backw$sign{_}ards"], @@ -250,7 +250,7 @@ key => { '])' => ["next open )"], ']/' => ["end of C com$sign{_}m$sign{_}ent"], '][' => [qq'section forw$sign{_}ard'], -']^['=> ["esc"], +"]\e"=> ["normal mode"], ']]' => ["section forw$sign{_}ard"], ']}' => ["next open }"], @@ -274,7 +274,7 @@ key => { '^w+' => ["height incr$sign{_}ease"], '^w-' => ["height decr$sign{_}ease"], '^w=' => ["same height"], -'^w^['=> ["esc"], +"^w\e"=> ["normal mode"], '^w]' => ["split, to tag"], '^w}' => ["pre$sign{_}view tag"], '^w|' => ["set width"], @@ -310,7 +310,7 @@ key => { '^wx' => ["ex$sign{_}chan$sign{_}ge"], '^wz' => ["close pre$sign{_}view"], -'^wg^['=> ["esc"], +"^wg\e"=> ["normal mode"], '^wg]' => ["split, :ts$sign{_}elect"], '^wg}' => [":ptj$sign{_}ump to tag"], '^wg^]'=> ["split, :tj$sign{_}ump"], @@ -323,7 +323,7 @@ key => { 'v=' => ["re$sign{_}ind$sign{_}ent"], 'v>' => ["ind$sign{_}ent"], 'v~' => ["toggle case"], -'v^['=> ["esc"], +"v\e"=> ["normal mode"], 'v^]'=> ["jump to tag"], 'va' => ["ex$sign{_}tend area"], @@ -355,7 +355,7 @@ key => { 'vy' => ["yank area"], 'vY' => ["yank lines"], -'vg^['=> ["esc"], +"vg\e"=> ["visual mode"], 'vg?' => ["rot13 encode"], 'vgJ' => ["join literal$sign{_}ly"], 'vgq' => ["for$sign{_}mat"], @@ -364,7 +364,7 @@ key => { "va'" => ["quoted string"], 'va<' => ["<> block"], 'va[' => ["[] block"], -'va^['=> ["esc"], +"va\e"=> ["visual mode"], 'vab' => ["() block"], 'vaB' => ["{} Block"], @@ -388,7 +388,7 @@ key => { 'i^@' => ["last insert"], 'i^^' => ["toggle :lmap usag$sign{_}e"], -'i^[' => ["esc"], +"i\e" => ["normal mode"], 'i^]' => ["abbrev$sign{_}iate"], 'i^_' => ["toggle lang$sign{_}uage"], @@ -417,12 +417,13 @@ key => { 'i^y' => ["ins char above"], 'i^z' => [":sus$sign{_}pend in im"], +"i^g\e"=> ["insert mode"], 'i^gk' => ["$sign{up} start col$sign{_}umn"], 'i^gj' => ["$sign{down} start col$sign{_}umn"], 'i^gu' => ["break undo seq$sign{_}uence"], # other i^g keys (even esc) are not recognized -'i^x^[' => ["esc"], +"i^x\e" => ["normal mode"], 'i^x^]' => ["tag comp$sign{_}l$sign{_}et$sign{_}e"], 'i^x^d' => ["def$sign{_}ine compl$sign{_}et$sign{_}e"], 'i^x^e' => ["window up"], diff --git a/vi.inc.pl b/vi.inc.pl index 02465d8..d0c259f 100644 --- a/vi.inc.pl +++ b/vi.inc.pl @@ -2,7 +2,6 @@ use utf8; { '' => { - "\e"=> ["mo mode"], '~' => ["co undo"], '!' => ["co argm undo modec"], '@' => ["co arg undo"], @@ -122,6 +121,8 @@ use utf8; g => { lead => "g", + "\e"=> ["mo mode"], + '~' => ["co argm ext vim6"], '@' => ["co ext vim7 new"], '#' => ["pm ext vim6"], @@ -184,7 +185,8 @@ g => { Z => { lead => "Z", - '^['=> ["mo mode"], + "\e"=> ["mo mode"], + '^['=> "\e", 'Q' => ["co ext vim6"], 'Z' => ["co"], @@ -193,12 +195,14 @@ Z => { z => { lead => "z", + "\e"=> ["mo mode"], + '^' => ["po"], '+' => ["po"], '-' => ["po"], '=' => ["co ext vim7 new"], '.' => ["po"], - '^['=> ["mo mode"], + '^['=> "\e", 'a' => ["co ext vim6 folding"], 'A' => ["co ext vim6 folding"], @@ -243,6 +247,8 @@ z => { '[' => { lead => "[", + "\e"=> ["mo mode"], + "`" => ["pm ext vim6"], '#' => ["pm"], '(' => ["pm"], @@ -251,7 +257,7 @@ z => { "'" => "[` ^", # ext vim6 '{' => ["pm"], '[' => ["pm"], - '^['=> ["mo mode"], + '^['=> "\e", ']' => ["pm"], 'c' => ["pm"], @@ -273,6 +279,8 @@ z => { ']' => { lead => "]", + "\e"=> ["mo mode"], + "`" => ["pm ext vim6"], '#' => ["pm"], ')' => ["pm"], @@ -280,7 +288,7 @@ z => { "'" => "]` ^", # ext vim6 '/' => ["pm"], '[' => ["pm"], - '^['=> ["mo mode"], + '^['=> "\e", ']' => ["pm"], '}' => ["pm"], @@ -303,6 +311,8 @@ z => { '^w' => { lead => $ascii ? "'w" : "ŵ", + "\e"=> ["mo mode"], + '<' => ["po"], '>' => ["po"], '^' => ["co"], @@ -310,7 +320,7 @@ z => { '+' => ["po"], '-' => ["po"], '=' => ["po"], - '^['=> ["mo mode"], + '^['=> "\e", ']' => ["po"], '}' => ["po"], '|' => ["po"], @@ -351,7 +361,8 @@ z => { '^wg' => { lead => $ascii ? "'wg" : "ŵg", - '^['=> ["mo mode"], + "\e"=> ["mo mode"], + '^['=> "\e", ']' => ["po"], '}' => ["po"], '^]'=> ["po"], @@ -360,13 +371,15 @@ z => { }, # mode ^w g v => { + "\e"=> ["mo mode"], + '!' => ["co"], ':' => ["mo modec"], '<' => ["co"], '=' => ['co undo'], '>' => ['co'], '~' => ["co ext vim6"], - '^['=> ["mo mode"], + '^['=> "\e", '^]'=> ["po"], '^\\'=>'^\\', @@ -415,7 +428,9 @@ v => { vg => { lead => "g", - '^['=> ["mv modev"], + "\e"=> ["mv modev"], + + '^['=> "\e", '?' => ["co ext vim6"], 'J' => ['co ext vim6'], 'q' => ["co ext vim6"], @@ -424,6 +439,8 @@ vg => { }, # mode v g va => { + "\e"=> ["mv modev"], + '(' => 'vab', ')' => 'vab', '`' => "va'", @@ -433,7 +450,7 @@ va => { '>' => 'va<', '[' => ['pm ext vim6'], '{' => 'vaB', - '^['=> ['mv modev'], + '^['=> "\e", ']' => 'va[', '}' => 'vaB', @@ -473,9 +490,11 @@ va => { #}, # mode c i => { + "\e" => ["mo mode"], + '^@' => ["co"], '^^' => ["co ext vim6"], - '^[' => ["mo mode"], + '^['=> "\e", '^]' => ["co ext vim6"], '^_' => ["co ext vim6"], '^\\'=>'^\\', @@ -511,6 +530,8 @@ i => { 'i^g' => { lead => $ascii ? "'g" : "ĝ", + "\e"=> ['mi modei'], + 'k' => ['pm'], 'j' => ['pm'], 'u' => ['co'], @@ -520,7 +541,9 @@ i => { 'i^x' => { lead => $ascii ? "'x" : "x̂", - '^[' => ["mo mode"], # yes, it really leaves insert mode + "\e" => ["mo mode"], # yes, it really leaves insert mode + + '^['=> "\e", '^]' => ['co'], '^d' => ['co'], '^e' => ["po"], diff --git a/vimperator.plp b/vimperator.plp index b54417d..74846f5 100644 --- a/vimperator.plp +++ b/vimperator.plp @@ -23,17 +23,12 @@ Html({
                  -
                • -
                    -
                  • Esc normal mode - -
                  -
                • - <: use Shiar_Sheet::Keyboard 2; my $info = do 'vimperator.eng.inc.pl' or die $@; $info->{def} = do 'vimperator.inc.pl'; +$_->{"\e"} = ['mv mode', "normal mode"] for values %{ $info->{def} }; +delete $info->{def}->{''}->{"\e"}; my $keys = Shiar_Sheet::Keyboard->new($info); $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows}); -- 2.30.0 From 490213a1df9d02e676c2a815f9b617af742cf628 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 26 Mar 2012 17:03:01 +0200 Subject: [PATCH 14/16] style: enlarge escape key regardless of omni-presence --- base.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base.css b/base.css index fcf1e55..3d8f52b 100644 --- a/base.css +++ b/base.css @@ -147,7 +147,7 @@ ul.keys li b { line-height: 2.5ex; /* inherits otherwise */ padding-left: 2px; } -ul.keys.omni li { /* omni-present esc */ +.row0 ul.keys li { /* omni-present esc */ width: 8.5em; } -- 2.30.0 From 504fe3dc4ec761922a00398fe5811f08fafbde41 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 26 Mar 2012 17:44:30 +0200 Subject: [PATCH 15/16] keys: common #rows container Output entire keyboard in Shiar_Sheet::Keyboard::print_rows() as contained exceptions are gone since commit v1.4-61-g6d38d53c6c (2012-03-26) [keys: replace omni-present escape keys]. --- Shiar_Sheet/Keyboard.pm | 4 ++++ less.plp | 3 --- mplayer.plp | 3 --- mutt.plp | 3 --- nethack.plp | 3 --- readline.plp | 3 --- screen.plp | 3 --- vi.plp | 3 --- vimperator.plp | 3 --- 9 files changed, 4 insertions(+), 24 deletions(-) diff --git a/Shiar_Sheet/Keyboard.pm b/Shiar_Sheet/Keyboard.pm index 2cbaffe..246900d 100644 --- a/Shiar_Sheet/Keyboard.pm +++ b/Shiar_Sheet/Keyboard.pm @@ -124,6 +124,8 @@ sub print_rows { my $defrows = shift || [2, 1, 0]; my @modes = sort keys %{ $self->{def} }; + print '
                    '."\n\n"; + for (my $row = -1; $row <= $#{ $keyrows{$self->{map}} }; $row++) { my $keyrow = $row < 0 ? [["\e"]] : $keyrows{$self->{map}}->[$row]; @@ -164,6 +166,8 @@ sub print_rows { } # basemode print qq{\t
                  \n}; } # row + + print "
                \n"; } sub print_legend { diff --git a/less.plp b/less.plp index b363203..1b42723 100644 --- a/less.plp +++ b/less.plp @@ -21,8 +21,6 @@ Html({

                normal pager (default)

                -
                  - <: use Shiar_Sheet::Keyboard 2; my $info = do 'less.eng.inc.pl' or die $@; @@ -31,7 +29,6 @@ my $keys = Shiar_Sheet::Keyboard->new($info); $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows}, [1,0]); :> -

                diff --git a/mplayer.plp b/mplayer.plp index 689ee84..200b355 100644 --- a/mplayer.plp +++ b/mplayer.plp @@ -20,8 +20,6 @@ Html({

                index (default)

                -
                  - <: use Shiar_Sheet::Keyboard 2; my $info = do 'mplayer.eng.inc.pl' or die $@; @@ -30,7 +28,6 @@ my $keys = Shiar_Sheet::Keyboard->new($info); $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows}, [1,0]); :> -

                diff --git a/mutt.plp b/mutt.plp index 3ce3d02..4095965 100644 --- a/mutt.plp +++ b/mutt.plp @@ -20,8 +20,6 @@ Html({

                index (default)

                -
                  - <: use Shiar_Sheet::Keyboard 2; my $info = do 'mutt.eng.inc.pl' or die $@; @@ -30,7 +28,6 @@ my $keys = Shiar_Sheet::Keyboard->new($info); $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows}); :> -

                diff --git a/nethack.plp b/nethack.plp index 7e46c37..b00fb9c 100644 --- a/nethack.plp +++ b/nethack.plp @@ -20,8 +20,6 @@ Html({

                normal gameplay

                -
                  - <: use Shiar_Sheet::Keyboard 2; my $info = do 'nethack.eng.inc.pl' or die $@; @@ -32,7 +30,6 @@ $_->{"\e"} = ['me mode'] for values %{ $info->{def} }; $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows} || '4321-421', [3,2,1,0]); :> -

                diff --git a/readline.plp b/readline.plp index 6d8c499..c0eb58a 100644 --- a/readline.plp +++ b/readline.plp @@ -20,8 +20,6 @@ Html({

                default emacs mode

                -
                  - <: use Shiar_Sheet::Keyboard 2; my $info = do 'readline.eng.inc.pl' or die $@; @@ -30,7 +28,6 @@ my $keys = Shiar_Sheet::Keyboard->new($info); $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows} || '^x=213', [4,3,2]); :> -

                diff --git a/screen.plp b/screen.plp index a99dc98..f4ceecb 100644 --- a/screen.plp +++ b/screen.plp @@ -21,8 +21,6 @@ Html({

                normal mode (default)

                -
                  - <: use Shiar_Sheet::Keyboard 2; my $info = do 'screen.inc.pl' or die $! // $@; @@ -30,7 +28,6 @@ my $keys = Shiar_Sheet::Keyboard->new($info); $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows}); :> -

                diff --git a/vi.plp b/vi.plp index dc82a16..e3cd1e8 100644 --- a/vi.plp +++ b/vi.plp @@ -20,8 +20,6 @@ Html({

                normal mode (default)

                -
                  - <: use Shiar_Sheet::Keyboard 2; my $info = do 'vi.eng.inc.pl' or die $@; @@ -30,7 +28,6 @@ my $keys = Shiar_Sheet::Keyboard->new($info); $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows}); :> -

                diff --git a/vimperator.plp b/vimperator.plp index 74846f5..d939c9a 100644 --- a/vimperator.plp +++ b/vimperator.plp @@ -21,8 +21,6 @@ Html({

                normal mode (default)

                -
                  - <: use Shiar_Sheet::Keyboard 2; my $info = do 'vimperator.eng.inc.pl' or die $@; @@ -33,7 +31,6 @@ my $keys = Shiar_Sheet::Keyboard->new($info); $keys->map($get{map}) or undef $get{map}; $keys->print_rows($get{rows}); :> -

                -- 2.30.0 From e04254be9c83d0db501eb8592517fc7e30ba15ad Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 26 Mar 2012 16:38:17 +0200 Subject: [PATCH 16/16] screen: update definitions, initial groups --- Shiar_Sheet/Keyboard.pm | 4 +- screen.inc.pl | 133 +++++++++++++++++++++++----------------- 2 files changed, 80 insertions(+), 57 deletions(-) diff --git a/Shiar_Sheet/Keyboard.pm b/Shiar_Sheet/Keyboard.pm index 246900d..8f436a6 100644 --- a/Shiar_Sheet/Keyboard.pm +++ b/Shiar_Sheet/Keyboard.pm @@ -88,7 +88,9 @@ sub print_key { $flags = [$key eq '^0' ? 'ni' : 'no']; } elsif (not ref $flags) { # alias - $flags = [$self->keyunalias($flags) . ' alias', $self->{sign}->{alias} . $flags]; + my $desc = $self->{sign}->{alias}; + $desc .= $flags eq "\e" ? 'esc' : $flags; + $flags = [$self->keyunalias($flags) . ' alias', $desc]; } my ($flags, $desc, $mnem) = @{$flags}; if (my $txt = $self->{key}->{$mode.$key}) { diff --git a/screen.inc.pl b/screen.inc.pl index c887191..5f2b99e 100644 --- a/screen.inc.pl +++ b/screen.inc.pl @@ -2,84 +2,105 @@ use utf8; # screen version 4.00.03jw4 +{ + +def => { '' => { desc => 'index', - 'a' => ["literal a"], - 'A' => ["title"], # title - '^a'=> ["command key"], - 'b' => ["break"], # break - 'B' => ["pow_break"], # pow_break + 'a' => ['g6', "literal a"], + 'A' => ['g8 args', "title"], # title + '^a'=> ['', "command key"], + 'b' => ['g6', "send break"], # break + 'B' => ['g6', "reopen break"], # pow_break '^b'=> 'b', - 'c' => ["new"], # screen - 'C' => ["clear"], # clear + 'c' => ['g8', "new"], # screen + 'C' => ['g1', "clear"], # clear '^c'=> 'c', - 'd' => ["detach"], # detach - 'D' => ["detach"], # pow_detach + 'd' => ['g8', "detach"], # detach + 'D' => ['g8', "detach logout"], # pow_detach '^d'=> 'd', - 'f' => ["flow", # flow - 'F' => ["fit"], + 'f' => ['g3', "flow"], # flow + 'F' => ['g3', "fit"], '^f'=> 'f', - '^g'=> ["vbell"], # vbell - 'h' => ["hardcopy"], # hardcopy - 'H' => ["log"], # log + '^g'=> ['g3', "vbell"], # vbell + 'h' => ['g5', "hardcopy"], # hardcopy + 'H' => ['g4', "log"], # log '^h'=> '^p', - 'i' => ["prop$sign{_}erties"], # info - 'I' => ["login on"], #XXX - '^i'=> ["focus"], # focus - 'k' => ["kill"], # kill + 'i' => ['g0', "prop$sign{_}erties"], # info + 'I' => ['g4', "login on"], #XXX + '^i'=> ['g1', "focus"], # focus + 'k' => ['g4', "kill"], # kill 'K' => 'k', - 'l' => ["redraw"], # redisplay - 'L' => ["login"], # login + 'l' => ['g1', "redraw"], # redisplay + 'L' => ['g4', "login"], # login '^l'=> 'l', - 'm' => ["last msg"], # lastmsg - 'M' => ["monitor"], # monitor + 'm' => ['g0', "last msg"], # lastmsg + 'M' => ['g4', "moni$sign{_}tor"], # monitor '^m'=> 'm', - 'n' => ["next"], # next - 'N' => ["number"], # number + 'n' => ['g2', "next"], # next + 'N' => ['g0', "number"], # number '^n'=> 'n', - 'O' => ["login off"], #XXX - '^o'=> ["other"], # other - 'p' => ["previous"], # prev + 'O' => ['g4', "login off"], #XXX + '^o'=> ['g2', "other"], # other + 'p' => ['g2', "previous"], # prev '^p'=> 'p', - 'q' => ["xon"], # xon - 'Q' => ["only"], # only + 'q' => ['g3', "xon"], # xon + 'Q' => ['g1', "only"], # only '^q'=> 'q', - 'r' => ["wrap"], # wrap + 'r' => ['g3', "wrap"], # wrap '^r'=> 'r', - 's' => ['xoff'], # xoff + 's' => ['g3', 'xoff'], # xoff '^s'=> 's', - 't' => ["time"], # time + 't' => ['g0', "time"], # time '^t'=> 't', - 'v' => ["version"], - '^v'=> ["digraph"], # digraph - 'w' => ["windows"], # windows - 'W' => ["width"], # width + 'v' => ['g0', "version"], + '^v'=> ['g6 arg arg', "digraph"], # digraph + 'w' => ['g0', "windows"], # windows + 'W' => ['g3', "width"], # width '^w'=> 'w', - 'x' => ["lock screen"], # lockscreen - 'X' => ["remove"], # remove + 'x' => ['g8', "lock screen"], # lockscreen + 'X' => ['g1', "remove"], # remove '^x'=> 'x', - 'z' => ["suspend"], # suspend - 'Z' => ["reset"], + 'z' => ['g8', "suspend"], # suspend + 'Z' => ['g8', "reset"], '^z'=> 'z', - "'" => ["select"], # select - '"' => ["windowlist -b"], # windowlist -b - ':' => ["colon"], # colon - '[' => ["copy"], # copy - '^]'=> ["paste ."], # paste . + "'" => ['g2 arg', "select"], # select + '"' => ['g2', "window$sign{_}list -b"], # windowlist -b + ':' => ['g3', "colon"], # colon + "\e"=> ['g5', "copy"], # copy + '[' => '^[', + '^['=> "\e", + '^]'=> ['g6', "paste ."], # paste . ']' => '^]', - '|' => ["split vert"], # split -v - '{' => ["history"], # history - '}' => ["history"], # history - '=' => ["remove buf"], # removebuf + '|' => ['g1', "split vert"], # split -v + '{' => ['g6', "history"], # history + '}' => ['g6', "history"], # history + '=' => ['g5', "remove buf"], # removebuf '^?'=> '^h', - '*' => ["displays"], # displays - '.' => ["dumptermcap"], # dumptermcap - ',' => ["license"], # license - '-' => ["select -"], # select - - '_' => ["silence"], # silence - '>' => ["writebuf"], # writebuf - '<' => ["readbuf"], # readbuf + '*' => ['g0', "displays"], # displays + '.' => ['g8', "dump$sign{_}termcap"], # dumptermcap + ',' => ['g0', "license"], # license + '-' => ['g2', "select -"], # select - + '_' => ['g4', "silence"], # silence + '>' => ['g5', "writebuf"], # writebuf + '<' => ['g5', "readbuf"], # readbuf '^@'=> 'n', }, +}, + +flag => { + g0 => ["info"], + g1 => ["display"], + g2 => ["select"], + g3 => ["config"], + g4 => ["window"], + g5 => ["buffer"], + g6 => ["contents"], + g8 => ["screen"], + + arg => ["key$sign{arg}", "Commands with a dot need a char argument afterwards."], +}, + +} -- 2.30.0