Skip to content

Commit

Permalink
Change \k< and \k> to \kL and \kR in lesskey.
Browse files Browse the repository at this point in the history
  • Loading branch information
gwsw committed Aug 19, 2021
1 parent 0202daa commit 8221628
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 10 deletions.
21 changes: 13 additions & 8 deletions lesskey.nro.VER
Original file line number Diff line number Diff line change
Expand Up @@ -68,28 +68,33 @@ A backslash followed by certain characters specifies input
characters as follows:
.RS 5m
.TS
l l l.
\eb BACKSPACE (0x08)
\ee ESCAPE (0x1B)
\en NEWLINE (0x0A)
\er RETURN (0x0D)
\et TAB (0x09)
.TE
.sp
\ek followed by a single character represents the char(s) produced when one of these keys is pressed:
.TS
l l.
\eb BACKSPACE (that is, 0x08)
\ee ESCAPE
\en NEWLINE
\er RETURN
\et TAB
\ekb BACKSPACE (that is, the char(s) produced when the BACKSPACE key is pressed)
\ekb BACKSPACE (the BACKSPACE key)
\ekB ctrl-BACKSPACE
\ekd DOWN ARROW
\ekD PAGE DOWN
\eke END
\ekh HOME
\eki INSERT
\ekl LEFT ARROW
\ekL ctrl-LEFT ARROW
\ekr RIGHT ARROW
\ekR ctrl-RIGHT ARROW
\ekt BACKTAB
\eku UP ARROW
\ekU PAGE UP
\ekx DELETE
\ekX ctrl-DELETE
\ek> ctrl-RIGHT ARROW
\ek< ctrl-LEFT ARROW
\ek1 F1
.TE

Expand Down
4 changes: 2 additions & 2 deletions lesskey_parse.c
Original file line number Diff line number Diff line change
Expand Up @@ -224,15 +224,15 @@ tstr(pp, xlate)
case 'h': ch = SK_HOME; break;
case 'i': ch = SK_INSERT; break;
case 'l': ch = SK_LEFT_ARROW; break;
case 'L': ch = SK_CTL_LEFT_ARROW; break;
case 'r': ch = SK_RIGHT_ARROW; break;
case 'R': ch = SK_CTL_RIGHT_ARROW; break;
case 't': ch = SK_BACKTAB; break;
case 'u': ch = SK_UP_ARROW; break;
case 'U': ch = SK_PAGE_UP; break;
case 'x': ch = SK_DELETE; break;
case 'X': ch = SK_CTL_DELETE; break;
case '1': ch = SK_F1; break;
case '<': ch = SK_CTL_LEFT_ARROW; break;
case '>': ch = SK_CTL_RIGHT_ARROW; break;
default: { char buf[2]; buf[0] = *p; buf[1] = '\0';
parse_error("illegal escape sequence \\k", buf);
*pp = p+1;
Expand Down

0 comments on commit 8221628

Please sign in to comment.