mirror of
https://github.com/jarun/nnn.git
synced 2024-11-24 11:51:27 +00:00
Toggle help and file details screens with same key
This commit is contained in:
parent
a569d383bc
commit
f2a5002fa9
|
@ -149,7 +149,7 @@ Start nnn (default: current directory):
|
|||
| `/`, `&` | Filter dir contents |
|
||||
| `c` | Show change dir prompt |
|
||||
| `d` | Toggle detail view |
|
||||
| `D` | Show details of selected file |
|
||||
| `D` | Toggle current file details screen |
|
||||
| `.` | Toggle hide .dot files |
|
||||
| `s` | Toggle sort by file size |
|
||||
| `S` | Toggle disk usage analyzer mode |
|
||||
|
@ -160,7 +160,7 @@ Start nnn (default: current directory):
|
|||
| `p` | Open entry in `PAGER` (fallback less) |
|
||||
| `^K` | Invoke file name copier |
|
||||
| `^L` | Force a redraw |
|
||||
| `?` | Show help |
|
||||
| `?` | Toggle help screen |
|
||||
| `q` | Quit |
|
||||
|
||||
### Filters
|
||||
|
|
4
nnn.1
4
nnn.1
|
@ -49,7 +49,7 @@ Change into the given directory
|
|||
.It Ic d
|
||||
Toggle detail view
|
||||
.It Ic D
|
||||
Show details of selected file
|
||||
Toggle current file details screen
|
||||
.It Ic \&.
|
||||
Toggle hide .dot files
|
||||
.It Ic s
|
||||
|
@ -71,7 +71,7 @@ Invoke file name copier
|
|||
.It Ic ^L
|
||||
Force a redraw
|
||||
.It Ic \&?
|
||||
Show help
|
||||
Toggle help screen
|
||||
.It Ic q
|
||||
Quit
|
||||
.El
|
||||
|
|
20
nnn.c
20
nnn.c
|
@ -877,11 +877,9 @@ show_stats(char* fpath, char* fname, struct stat *sb)
|
|||
}
|
||||
|
||||
/* Show exit keys */
|
||||
printw("\n\n << (q/Esc)");
|
||||
|
||||
for (*buf = getch(); *buf != 'q' && *buf != 27; *buf = getch())
|
||||
if (*buf == 'q' || *buf == 27)
|
||||
return;
|
||||
printw("\n\n << (D)");
|
||||
while ((*buf = getch()) != 'D');
|
||||
return;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -906,7 +904,7 @@ show_help(void)
|
|||
/, & Filter dir contents\n\
|
||||
c Show change dir prompt\n\
|
||||
d Toggle detail view\n\
|
||||
D Show details of selected file\n\
|
||||
D Toggle current file details screen\n\
|
||||
. Toggle hide .dot files\n\
|
||||
s Toggle sort by file size\n\
|
||||
S Toggle disk usage analyzer mode\n\
|
||||
|
@ -917,15 +915,13 @@ show_help(void)
|
|||
p Open entry in PAGER (fallback less)\n\
|
||||
^K Invoke file name copier\n\
|
||||
^L Force a redraw\n\
|
||||
? Show help\n\
|
||||
? Toggle help screen\n\
|
||||
q Quit\n");
|
||||
|
||||
/* Show exit keys */
|
||||
printw("\n\n << (q/Esc)");
|
||||
|
||||
for (c = getch(); c != 'q' && c != 27; c = getch())
|
||||
if (c == 'q' || c == 27)
|
||||
return;
|
||||
printw("\n\n << (?)");
|
||||
while ((c = getch()) != '?');
|
||||
return;
|
||||
}
|
||||
|
||||
static int
|
||||
|
|
Loading…
Reference in a new issue