]> Sergey Matveev's repositories - nnn.git/commitdiff
Case-insensitive Ctrl-key handling, man page update
authorArun Prakash Jana <engineerarun@gmail.com>
Wed, 11 Mar 2020 03:44:59 +0000 (09:14 +0530)
committerArun Prakash Jana <engineerarun@gmail.com>
Wed, 11 Mar 2020 03:44:59 +0000 (09:14 +0530)
nnn.1
src/nnn.h

diff --git a/nnn.1 b/nnn.1
index 28e069df545619d456bc37afd9ece89caf7f76c1..db8d722450d9760c71863a7f889fc7c03bb8f1c7 100644 (file)
--- a/nnn.1
+++ b/nnn.1
@@ -380,11 +380,11 @@ separated by \fI;\fR:
     export NNN_MCLICK='p'
 
     NOTES:
-    1. You can use the '^\fIkey\fR' syntax to assign it to a \fICtrl+key\fR combo, e.g.:
+    1. To specify a \fICtrl+key\fR combo:
 
     export NNN_MCLICK='^A'
 
-    2. Otherwise, only the first character is taken into account.
+    2. Otherwise, only the first character is considered.
 .Ed
 .Pp
 \fBnnn:\fR this is a special variable set to the hovered entry before executing
index 3763883605a52337cab4de12bbad2551dc8b8505..a832939a007686ef1ae313271380f9584517a775 100644 (file)
--- a/src/nnn.h
+++ b/src/nnn.h
@@ -32,7 +32,7 @@
 
 #include <curses.h>
 
-#define CONTROL(c) ((c) ^ 0x40)
+#define CONTROL(c) ((c) & 0x1f)
 
 /* Supported actions */
 enum action {