NANO_DOWN_KEY in the search history shortcut entries. (DLR)
- Add NANO_UNJUSTIFY_FKEY (the same as NANO_UNCUT_FKEY) to the
shortcut list, and tweak the unjustify routine to use it.
- (DLR)
+ Also add NANO_FIRSTLINE_FKEY and NANO_LASTLINE_FKEY, and tweak
+ the statusbar input routines to handle them and NANO_HELP_FKEY
+ properly. (DLR)
- Add more intuitive Meta-key aliases for moving to the
beginning and ending lines of a paragraph at the search
prompt: Meta-P and Meta-N. (DLR)
/* Translators: try to keep this string under 10 characters long */
sc_init_one(&whereis_list, NANO_FIRSTLINE_KEY, _("First Line"),
- IFHELP(nano_firstline_msg, NANO_NO_KEY), NANO_NO_KEY,
+ IFHELP(nano_firstline_msg, NANO_NO_KEY), NANO_FIRSTLINE_FKEY,
NANO_NO_KEY, VIEW, do_first_line);
/* Translators: try to keep this string under 10 characters long */
sc_init_one(&whereis_list, NANO_LASTLINE_KEY, _("Last Line"),
- IFHELP(nano_lastline_msg, NANO_NO_KEY), NANO_NO_KEY,
+ IFHELP(nano_lastline_msg, NANO_NO_KEY), NANO_LASTLINE_FKEY,
NANO_NO_KEY, VIEW, do_last_line);
/* Translators: try to keep this string under 10 characters long */
#define NANO_SPELL_KEY NANO_CONTROL_T
#define NANO_SPELL_FKEY KEY_F(12)
#define NANO_FIRSTLINE_KEY NANO_PREVPAGE_KEY
+#define NANO_FIRSTLINE_FKEY NANO_PREVPAGE_FKEY
#define NANO_LASTLINE_KEY NANO_NEXTPAGE_KEY
+#define NANO_LASTLINE_FKEY NANO_NEXTPAGE_FKEY
#define NANO_CANCEL_KEY NANO_CONTROL_C
#define NANO_REFRESH_KEY NANO_CONTROL_L
#define NANO_JUSTIFY_KEY NANO_CONTROL_J
fprintf(stderr, "Aha! \'%c\' (%d)\n", kbinput, kbinput);
#endif
+ if (kbinput == t->func_key)
+ kbinput = t->val;
+
if (kbinput == t->val && is_cntrl_char(kbinput)) {
#ifndef DISABLE_HELP
/* Have to do this here, it would be too late to do it
in statusq() */
- if (kbinput == NANO_HELP_KEY || kbinput == NANO_HELP_FKEY) {
+ if (kbinput == NANO_HELP_KEY) {
+ kbinput = NANO_HELP_KEY;
do_help();
break;
}
switch (ret) {
case NANO_FIRSTLINE_KEY:
+ case NANO_FIRSTLINE_FKEY:
do_first_line();
resetstatuspos = 1;
break;
case NANO_LASTLINE_KEY:
+ case NANO_LASTLINE_FKEY:
do_last_line();
resetstatuspos = 1;
break;