Moved the toggle Meta keystrokes to the first column. Updated documentation and help code for Meta keys rather than 'alt keys'

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@194 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
master
Chris Allegretta 2000-09-02 07:20:39 +00:00
parent 4c780be883
commit e49f123cc0
4 changed files with 93 additions and 79 deletions

View File

@ -3,7 +3,15 @@ CVS Code
- New shortcuts to toggle certain options that are normally only
flags via Alt/Meta. See Alt-C,E,I,K,M,P,X,Z. New struct called
toggles in nano.h, toggle_init(), toggle_init_one() in global.c
called from shortcut_init(), and do_toggle in nano.c.
called from shortcut_init(), and do_toggle in nano.c. Also
moved the signal code into a separate function in nano.c called
signal_init().
- Changed from Alt-key symbol (@) which is completely nonstandard
to the *nix "Meta" symbol (M-). Changed help_init to show
the M-key usage and the help text to explain keys whcih generate
Meta. Moved the toggle Meta keystrokes to the first column
instead of the third as they are the primary keystrokes for the
functions.
- Changed last_search and last_replace vars to statically
allocated (hence nulled) and moved to search.c (Matt Kraai).
- nano.c:

10
nano.c
View File

@ -165,8 +165,10 @@ void init_help_msg(void)
"The bottom two lines show the most commonly used shortcuts "
"in the editor.\n\n "
"The notation for shortcuts is as follows: Control-key "
"sequences are notated with a caret (^) symbol. Alt-key "
"sequences are notated with an at (@) symbol. The following "
"sequences are notated with a caret (^) symbol and are entered "
"with the Control (Ctrl) hey. Escape-key sequences are notated "
"with the Meta (M) symbol and can be entered using either Esc, "
"Alt or Meta depending on your keyboard setup. The following "
"keystrokes are available in the main editor window. "
"Optional keys are shown in parentheses:\n\n");
#endif
@ -1576,7 +1578,7 @@ void help_init(void)
sofar += snprintf(&buf[sofar], BUFSIZ - sofar, " ");
if (main_list[i].altval > 0)
sofar += snprintf(&buf[sofar], BUFSIZ - sofar, "(@%c) ",
sofar += snprintf(&buf[sofar], BUFSIZ - sofar, "(M-%c) ",
main_list[i].altval - 32);
else
sofar += snprintf(&buf[sofar], BUFSIZ - sofar, " ");
@ -1593,7 +1595,7 @@ void help_init(void)
/* And the toggles... */
for (i = 0; i < TOGGLE_LEN - 1; i++) {
sofar = snprintf(buf, BUFSIZ,
" (@%c) ", toggles[i].val - 32 );
"M-%c ", toggles[i].val - 32 );
if (toggles[i].desc != NULL)
snprintf(&buf[sofar], BUFSIZ - sofar, "%s enable/disable",

View File

@ -114,9 +114,11 @@ bottom and shows important messages. The bottom two lines show the most \
commonly used shortcuts in the editor.\n\
\n\
The notation for shortcuts is as follows: Control-key sequences are notated \
with a caret (^) symbol. Alt-key sequences are notated with an at (@) \
symbol. The following keystrokes are available in the main editor window. \
Optional keys are shown in parentheses:\n\
with a caret (^) symbol and are entered with the Control (Ctrl) hey. \
Escape-key sequences are notated with the Meta (M) symbol and can be entered \
using either Esc, Alt or Meta depending on your keyboard setup. The \
following keystrokes are available in the main editor window. Optional keys \
are shown in parentheses:\n\
\n", 94},
{"free_node(): free'd a node, YAY!\n", 95},
{"free_node(): free'd last node.\n", 96},

View File

@ -6,7 +6,7 @@
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"POT-Creation-Date: 2000-09-01 14:07-0400\n"
"POT-Creation-Date: 2000-09-02 03:21-0400\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -55,7 +55,7 @@ msgstr ""
msgid "File to insert [from ./] "
msgstr ""
#: files.c:273 files.c:297 files.c:487 nano.c:1144
#: files.c:273 files.c:297 files.c:487 nano.c:1146
msgid "Cancelled"
msgstr ""
@ -411,286 +411,288 @@ msgid ""
"commonly used shortcuts in the editor.\n"
"\n"
" The notation for shortcuts is as follows: Control-key sequences are notated "
"with a caret (^) symbol. Alt-key sequences are notated with an at (@) "
"symbol. The following keystrokes are available in the main editor window. "
"Optional keys are shown in parentheses:\n"
"with a caret (^) symbol and are entered with the Control (Ctrl) hey. "
"Escape-key sequences are notated with the Meta (M) symbol and can be entered "
"using either Esc, Alt or Meta depending on your keyboard setup. The "
"following keystrokes are available in the main editor window. Optional keys "
"are shown in parentheses:\n"
"\n"
msgstr ""
#: nano.c:258
#: nano.c:260
msgid "free_node(): free'd a node, YAY!\n"
msgstr ""
#: nano.c:263
#: nano.c:265
msgid "free_node(): free'd last node.\n"
msgstr ""
#: nano.c:315
#: nano.c:317
msgid ""
"Usage: nano [GNU long option] [option] +LINE <file>\n"
"\n"
msgstr ""
#: nano.c:316
#: nano.c:318
msgid "Option\t\tLong option\t\tMeaning\n"
msgstr ""
#: nano.c:318
#: nano.c:320
msgid " -T \t\t--tabsize=[num]\t\tSet width of a tab to num\n"
msgstr ""
#: nano.c:321
#: nano.c:323
msgid " -R\t\t--regexp\t\tUse regular expressions for search\n"
msgstr ""
#: nano.c:325
#: nano.c:327
msgid " -V \t\t--version\t\tPrint version information and exit\n"
msgstr ""
#: nano.c:327
#: nano.c:329
msgid " -c \t\t--const\t\t\tConstantly show cursor position\n"
msgstr ""
#: nano.c:329
#: nano.c:331
msgid " -h \t\t--help\t\t\tShow this message\n"
msgstr ""
#: nano.c:332
#: nano.c:334
msgid " -k \t\t--cut\t\t\tLet ^K cut from cursor to end of line\n"
msgstr ""
#: nano.c:335
#: nano.c:337
msgid " -i \t\t--autoindent\t\tAutomatically indent new lines\n"
msgstr ""
#: nano.c:337
#: nano.c:339
msgid " -l \t\t--nofollow\t\tDon't follow symbolic links, overwrite.\n"
msgstr ""
#: nano.c:340
#: nano.c:342
msgid " -m \t\t--mouse\t\t\tEnable mouse\n"
msgstr ""
#: nano.c:345
#: nano.c:347
msgid ""
" -r [#cols] \t--fill=[#cols]\t\tSet fill cols to (wrap lines at) #cols\n"
msgstr ""
#: nano.c:347
#: nano.c:349
msgid " -p\t \t--pico\t\t\tMake bottom 2 lines more Pico-like\n"
msgstr ""
#: nano.c:349
#: nano.c:351
msgid " -s [prog] \t--speller=[prog]\tEnable alternate speller\n"
msgstr ""
#: nano.c:351
#: nano.c:353
msgid " -t \t\t--tempfile\t\tAuto save on exit, don't prompt\n"
msgstr ""
#: nano.c:353
#: nano.c:355
msgid " -v \t\t--view\t\t\tView (read only) mode\n"
msgstr ""
#: nano.c:355
#: nano.c:357
msgid " -w \t\t--nowrap\t\tDon't wrap long lines\n"
msgstr ""
#: nano.c:357
#: nano.c:359
msgid " -x \t\t--nohelp\t\tDon't show help window\n"
msgstr ""
#: nano.c:359
#: nano.c:361
msgid " -z \t\t--suspend\t\tEnable suspend\n"
msgstr ""
#: nano.c:361
#: nano.c:363
msgid " +LINE\t\t\t\t\tStart at line number LINE\n"
msgstr ""
#: nano.c:363
#: nano.c:365
msgid ""
"Usage: nano [option] +LINE <file>\n"
"\n"
msgstr ""
#: nano.c:364
#: nano.c:366
msgid "Option\t\tMeaning\n"
msgstr ""
#: nano.c:365
#: nano.c:367
msgid " -T [num]\tSet width of a tab to num\n"
msgstr ""
#: nano.c:366
#: nano.c:368
msgid " -R\t\tUse regular expressions for search\n"
msgstr ""
#: nano.c:367
#: nano.c:369
msgid " -V \t\tPrint version information and exit\n"
msgstr ""
#: nano.c:368
#: nano.c:370
msgid " -c \t\tConstantly show cursor position\n"
msgstr ""
#: nano.c:369
#: nano.c:371
msgid " -h \t\tShow this message\n"
msgstr ""
#: nano.c:371
#: nano.c:373
msgid " -k \t\tLet ^K cut from cursor to end of line\n"
msgstr ""
#: nano.c:373
#: nano.c:375
msgid " -i \t\tAutomatically indent new lines\n"
msgstr ""
#: nano.c:375
#: nano.c:377
msgid " -l \t\tDon't follow symbolic links, overwrite.\n"
msgstr ""
#: nano.c:378
#: nano.c:380
msgid " -m \t\tEnable mouse\n"
msgstr ""
#: nano.c:382
#: nano.c:384
msgid " -r [#cols] \tSet fill cols to (wrap lines at) #cols\n"
msgstr ""
#: nano.c:383
#: nano.c:385
msgid " -s [prog] \tEnable alternate speller\n"
msgstr ""
#: nano.c:384
#: nano.c:386
msgid " -p \t\tMake bottom 2 lines more Pico-like\n"
msgstr ""
#: nano.c:385
#: nano.c:387
msgid " -t \t\tAuto save on exit, don't prompt\n"
msgstr ""
#: nano.c:386
#: nano.c:388
msgid " -v \t\tView (read only) mode\n"
msgstr ""
#: nano.c:387
#: nano.c:389
msgid " -w \t\tDon't wrap long lines\n"
msgstr ""
#: nano.c:388
#: nano.c:390
msgid " -x \t\tDon't show help window\n"
msgstr ""
#: nano.c:389
#: nano.c:391
msgid " -z \t\tEnable suspend\n"
msgstr ""
#: nano.c:390
#: nano.c:392
msgid " +LINE\t\tStart at line number LINE\n"
msgstr ""
#: nano.c:397
#: nano.c:399
#, c-format
msgid " nano version %s by Chris Allegretta (compiled %s, %s)\n"
msgstr ""
#: nano.c:399
#: nano.c:401
msgid " Email: nano@asty.org\tWeb: http://www.asty.org/nano\n"
msgstr ""
#: nano.c:434
#: nano.c:436
msgid "Mark Set"
msgstr ""
#: nano.c:439
#: nano.c:441
msgid "Mark UNset"
msgstr ""
#: nano.c:879
#: nano.c:881
#, c-format
msgid "check_wrap called with inptr->data=\"%s\"\n"
msgstr ""
#: nano.c:930
#: nano.c:932
#, c-format
msgid "current->data now = \"%s\"\n"
msgstr ""
#: nano.c:983
#: nano.c:985
#, c-format
msgid "After, data = \"%s\"\n"
msgstr ""
#: nano.c:1053
#: nano.c:1055
msgid "Error deleting tempfile, ack!"
msgstr ""
#: nano.c:1071
#: nano.c:1073
#, c-format
msgid "Could not create a temporary filename: %s"
msgstr ""
#: nano.c:1094
#: nano.c:1096
#, c-format
msgid "Could not invoke spell program \"%s\""
msgstr ""
#. Why 32512? I dont know!
#: nano.c:1100
#: nano.c:1102
msgid "Could not invoke \"ispell\""
msgstr ""
#: nano.c:1113
#: nano.c:1115
msgid "Finished checking spelling"
msgstr ""
#: nano.c:1131
#: nano.c:1133
msgid "Save modified buffer (ANSWERING \"No\" WILL DESTROY CHANGES) ? "
msgstr ""
#: nano.c:1272
#: nano.c:1274
msgid "Cannot resize top win"
msgstr ""
#: nano.c:1274
#: nano.c:1276
msgid "Cannot move top win"
msgstr ""
#: nano.c:1276
#: nano.c:1278
msgid "Cannot resize edit win"
msgstr ""
#: nano.c:1278
#: nano.c:1280
msgid "Cannot move edit win"
msgstr ""
#: nano.c:1280
#: nano.c:1282
msgid "Cannot resize bottom win"
msgstr ""
#: nano.c:1282
#: nano.c:1284
msgid "Cannot move bottom win"
msgstr ""
#: nano.c:1819
#: nano.c:1821
msgid "Main: set up windows\n"
msgstr ""
#: nano.c:1834
#: nano.c:1836
msgid "Main: bottom win\n"
msgstr ""
#: nano.c:1840
#: nano.c:1842
msgid "Main: open file\n"
msgstr ""
#: nano.c:1908
#: nano.c:1910
#, c-format
msgid "I got Alt-[-%c! (%d)\n"
msgstr ""
#: nano.c:1934
#: nano.c:1936
#, c-format
msgid "I got Alt-%c! (%d)\n"
msgstr ""