mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-18 17:29:28 +03:00
* user.c (check_format_view): Match "unform" instead of
"unformated" because some users may spell this word correctly.
This commit is contained in:
parent
27f3c8c8ed
commit
71620c6a9e
@ -1,3 +1,8 @@
|
|||||||
|
2001-07-19 Pavel Roskin <proski@gnu.org>
|
||||||
|
|
||||||
|
* user.c (check_format_view): Match "unform" instead of
|
||||||
|
"unformated" because some users may spell this word correctly.
|
||||||
|
|
||||||
2001-07-17 Pavel Roskin <proski@gnu.org>
|
2001-07-17 Pavel Roskin <proski@gnu.org>
|
||||||
|
|
||||||
* util.c (get_current_wd): Remove. It's obsoleted by
|
* util.c (get_current_wd): Remove. It's obsoleted by
|
||||||
|
20
src/user.c
20
src/user.c
@ -66,9 +66,9 @@ static char *menu = NULL;
|
|||||||
%s "Selected files"; the tagged files if any, otherwise the current file
|
%s "Selected files"; the tagged files if any, otherwise the current file
|
||||||
%t Tagged files
|
%t Tagged files
|
||||||
%u Tagged files (and they are untagged on return from expand_format)
|
%u Tagged files (and they are untagged on return from expand_format)
|
||||||
%view Runs the commands and pipes standard output to the view command
|
%view Runs the commands and pipes standard output to the view command.
|
||||||
if %view is directly followed by '{', a list of keywords
|
If %view is immediately followed by '{', recognize keywords
|
||||||
ascii, hex, nroff, unformated and
|
ascii, hex, nroff and unform
|
||||||
|
|
||||||
If the format letter is in uppercase, it refers to the other panel.
|
If the format letter is in uppercase, it refers to the other panel.
|
||||||
|
|
||||||
@ -85,22 +85,22 @@ static char *menu = NULL;
|
|||||||
int check_format_view (const char *p)
|
int check_format_view (const char *p)
|
||||||
{
|
{
|
||||||
const char *q = p;
|
const char *q = p;
|
||||||
if (!strncmp (p, "view", 4)){
|
if (!strncmp (p, "view", 4)) {
|
||||||
q += 4;
|
q += 4;
|
||||||
if (*q == '{'){
|
if (*q == '{'){
|
||||||
for (q++;*q && *q != '}';q++){
|
for (q++;*q && *q != '}';q++) {
|
||||||
if (!strncmp (q, "ascii", 5)){
|
if (!strncmp (q, "ascii", 5)) {
|
||||||
default_hex_mode = 0;
|
default_hex_mode = 0;
|
||||||
q += 4;
|
q += 4;
|
||||||
} else if (!strncmp (q, "hex", 3)){
|
} else if (!strncmp (q, "hex", 3)) {
|
||||||
default_hex_mode = 1;
|
default_hex_mode = 1;
|
||||||
q += 2;
|
q += 2;
|
||||||
} else if (!strncmp (q, "nroff", 5)){
|
} else if (!strncmp (q, "nroff", 5)) {
|
||||||
default_nroff_flag = 1;
|
default_nroff_flag = 1;
|
||||||
q += 4;
|
q += 4;
|
||||||
} else if (!strncmp (q, "unformated", 10)){
|
} else if (!strncmp (q, "unform", 6)) {
|
||||||
default_nroff_flag = 0;
|
default_nroff_flag = 0;
|
||||||
q += 9;
|
q += 5;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (*q == '}')
|
if (*q == '}')
|
||||||
|
Loading…
Reference in New Issue
Block a user