tweaks: reshuffle the flag conversion into their order in the help text

This should make it slightly easier for translators when they compare
their PO file to nano's main help text.

Also, drop a die() -- a forgotten toggle name is not worth dying over.
master
Benno Schulenberg 2021-11-17 11:07:11 +01:00
parent c772e1cb6b
commit 1235a5a365
1 changed files with 6 additions and 7 deletions

View File

@ -1515,14 +1515,18 @@ void shortcut_init(void)
const char *epithet_of_flag(int flag)
{
switch (flag) {
case NO_HELP:
case ZERO:
/* TRANSLATORS: The next thirteen strings are toggle descriptions;
* they are best kept shorter than 40 characters, but may be longer. */
return N_("Hidden interface");
case NO_HELP:
return N_("Help mode");
case CONSTANT_SHOW:
return N_("Constant cursor position display");
case SOFTWRAP:
return N_("Soft wrapping of overlong lines");
case LINE_NUMBERS:
return N_("Line numbering");
case WHITESPACE_DISPLAY:
return N_("Whitespace display");
case NO_SYNTAX:
@ -1539,13 +1543,8 @@ const char *epithet_of_flag(int flag)
return N_("Conversion of typed tabs to spaces");
case USE_MOUSE:
return N_("Mouse support");
case LINE_NUMBERS:
return N_("Line numbering");
case ZERO:
return N_("Hidden interface");
default:
die("Bad toggle -- please report a bug\n");
return "";
return "Ehm...";
}
}
#endif /* !NANO_TINY */